(text/x-fossil-plain)
Before Android NDK r17, there was only one ioctl() function defined.
int ioctl(int __fd, int __request, ...);
However, since Android NDK r17, another one has been added:
int ioctl(int __fd, unsigned __request, ...)
When compiling SQLite with SQLITE_ENABLE_BATCH_ATOMIC_WRITE this will produce a build error since clang does not know which ioctl() function to cast, since sqlite2_syscall_ptr is defined as:
typedef void (*sqlite3_syscall_ptr)(void);
====
[x86_64] Compile : sqliteX <= sqlite3.c
/home/mathieu/Documents/Sources/Temp/SQlite/sqlite/sqlite3/src/main/jni/sqlite/sqlite3.c:32184:43: error: address of overloaded function 'ioctl' is ambiguous
{ "ioctl", (sqlite3_syscall_ptr)ioctl, 0 },
^~~~~
/home/mathieu/Android/NDK/android-ndk-r17b/sysroot/usr/include/bits/ioctl.h:57:5: note: candidate function has different number of parameters (expected 0 but has 2)
int ioctl(int __fd, unsigned __request, ...) __overloadable __enable_if(1, "") __RENAME(ioctl);
^
/home/mathieu/Android/NDK/android-ndk-r17b/sysroot/usr/include/bits/ioctl.h:36:5: note: candidate function has different number of parameters (expected 0 but has 2)
int ioctl(int __fd, int __request, ...);
^
/home/mathieu/Documents/Sources/Temp/SQlite/sqlite/sqlite3/src/main/jni/sqlite/sqlite3.c:32184:22: error: initializer element is not a compile-time constant
{ "ioctl", (sqlite3_syscall_ptr)ioctl, 0 },
^~~~~~~~~~~~~~~~~~~~~~~~~~
2 errors generated.
make: *** [/home/mathieu/Documents/Sources/Temp/SQlite/sqlite/sqlite3/build/intermediates/ndkBuild/release/obj/local/x86_64/objs/sqliteX/sqlite3.o] Error 1
====
|