fi
print_config "sync_file_range" "$sync_file_range"
+##########################################
+# ASharedMemory_create() probe
+if test "$ASharedMemory_create" != "yes" ; then
+ ASharedMemory_create="no"
+fi
+cat > $TMPC << EOF
+#include <android/sharedmem.h>
+int main(int argc, char **argv)
+{
+ return ASharedMemory_create("", 0);
+}
+EOF
+if compile_prog "" "" "ASharedMemory_create"; then
+ ASharedMemory_create="yes"
+fi
+print_config "ASharedMemory_create" "$ASharedMemory_create"
+
##########################################
# ext4 move extent probe
if test "$ext4_me" != "yes" ; then
if test "$sync_file_range" = "yes" ; then
output_sym "CONFIG_SYNC_FILE_RANGE"
fi
+if test "$ASharedMemory_create" = "yes" ; then
+ output_sym "CONFIG_ASHAREDMEMORY_CREATE"
+fi
if test "$sfaa" = "yes" ; then
output_sym "CONFIG_SFAA"
fi
#include <linux/ashmem.h>
#include <linux/shm.h>
#include <android/api-level.h>
-#if __ANDROID_API__ >= __ANDROID_API_O__
+#ifdef CONFIG_ASHAREDMEMORY_CREATE
#include <android/sharedmem.h>
#else
#define ASHMEM_DEVICE "/dev/ashmem"
return ret;
}
-#if __ANDROID_API__ >= __ANDROID_API_O__
+#ifdef CONFIG_ASHAREDMEMORY_CREATE
static inline int shmget(key_t __key, size_t __size, int __shmflg)
{
char keybuf[11];