diff options
author | Dmitriy Ivanov <dimitry@google.com> | 2014-05-19 15:06:58 -0700 |
---|---|---|
committer | Dmitriy Ivanov <dimitry@google.com> | 2014-05-20 12:02:24 -0700 |
commit | b648a8a57ee42533a5bf127225a252f73ca2cbbc (patch) | |
tree | 09fdf06c6e8d5e6985107f4e8fdb2055c5bb6a6f /libc/include/dlfcn.h | |
parent | 0b9a72ce1124f17d514b93c0d26dea76ce8069f0 (diff) | |
download | bionic-b648a8a57ee42533a5bf127225a252f73ca2cbbc.zip bionic-b648a8a57ee42533a5bf127225a252f73ca2cbbc.tar.gz bionic-b648a8a57ee42533a5bf127225a252f73ca2cbbc.tar.bz2 |
Add RTLD_NOLOAD support and some related changes.
* Aligned RTLD_ values with glibc for lp64
* dlopen supports RTLD_NOLOAD flag
* soinfo_unload calls find_library(.., RTLD_NOLOAD)
instead of naive find_loaded_library_by_name()
* dlopen changed to add child to caller soinfo instead
of somain.
Bug: https://code.google.com/p/android/issues/detail?id=64069
Change-Id: I1a65f2c34f3e0edc6d2c41a2e408b58195feb640
Diffstat (limited to 'libc/include/dlfcn.h')
-rw-r--r-- | libc/include/dlfcn.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/libc/include/dlfcn.h b/libc/include/dlfcn.h index 7daa8f7..8dde08c 100644 --- a/libc/include/dlfcn.h +++ b/libc/include/dlfcn.h @@ -50,15 +50,29 @@ extern void* dlsym(void* handle, const char* symbol); extern int dladdr(const void* addr, Dl_info *info); enum { +#if defined(__LP64__) + RTLD_NOW = 2, +#else RTLD_NOW = 0, +#endif RTLD_LAZY = 1, RTLD_LOCAL = 0, +#if defined(__LP64__) + RTLD_GLOBAL = 0x00100, +#else RTLD_GLOBAL = 2, +#endif + RTLD_NOLOAD = 4, }; +#if defined (__LP64__) +#define RTLD_DEFAULT ((void*) 0) +#define RTLD_NEXT ((void*) -1L) +#else #define RTLD_DEFAULT ((void*) 0xffffffff) #define RTLD_NEXT ((void*) 0xfffffffe) +#endif __END_DECLS |