diff -u -r /home/fornwall/lib/android-ndk/platforms/android-21/arch-arm/usr/include/dlfcn.h ./usr/include/dlfcn.h
--- /home/fornwall/lib/android-ndk/platforms/android-21/arch-arm/usr/include/dlfcn.h	2016-03-03 16:54:24.000000000 -0500
+++ ./usr/include/dlfcn.h	2016-04-17 23:55:55.901040258 -0400
@@ -49,22 +49,22 @@
 extern void*        dlsym(void*  handle, const char*  symbol);
 extern int          dladdr(const void* addr, Dl_info *info);
 
-enum {
+/* Termux modification: Use #define for these instead of an enum
+   to improve compatibility with ifdef checks. */
 #if defined(__LP64__)
-  RTLD_NOW  = 2,
+# define RTLD_NOW 2
 #else
-  RTLD_NOW  = 0,
+# define RTLD_NOW 0
 #endif
-  RTLD_LAZY = 1,
+#define RTLD_LAZY 1
 
-  RTLD_LOCAL  = 0,
+# define RTLD_LOCAL 0
 #if defined(__LP64__)
-  RTLD_GLOBAL = 0x00100,
+# define RTLD_GLOBAL 0x00100
 #else
-  RTLD_GLOBAL = 2,
+# define RTLD_GLOBAL 2
 #endif
-  RTLD_NOLOAD = 4,
-};
+#define RTLD_NOLOAD 4
 
 #if defined (__LP64__)
 #define RTLD_DEFAULT  ((void*) 0)