[git commit branch/0.9.33] ldso: include dlfcn.h for RTLD_NODELETE

Carmelo Amoroso carmelo.amoroso at st.com
Wed Dec 19 12:23:43 UTC 2012


commit: http://git.uclibc.org/uClibc/commit/?id=2f09c67232cebca62f3afa4fc296c83aa813427c
branch: http://git.uclibc.org/uClibc/commit/?id=refs/heads/0.9.33

Building with NPTL enabled and shared library support disabled we hit:
In file included from libpthread/nptl/sysdeps/generic/dl-tls.c:30:0:
./ldso/include/dl-elf.h: In function '__dl_parse_dynamic_info':
./ldso/include/dl-elf.h:173:20: error: 'RTLD_NODELETE' undeclared (first use in this function)
./ldso/include/dl-elf.h:173:20: note: each undeclared identifier is reported only once for each function it appears in
make: *** [libpthread/nptl/sysdeps/generic/dl-tls.os] Error 1

A previous commit (f26c5f6952ce9bf8edec9c1571c47addb1bcc442) touched
on a similar issue, but added the include to the incorrect location.

Reported-by: Christophe Lyon <christophe.lyon at st.com> [arm nommu]
Reported-by: Daniel Beecham <daniel at lunix.se> [static x86_64]
Signed-off-by: Mike Frysinger <vapier at gentoo.org>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso at st.com>
---
 ldso/include/dl-elf.h |    2 ++
 ldso/include/ldso.h   |    1 -
 2 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/ldso/include/dl-elf.h b/ldso/include/dl-elf.h
index 29d1a00..e1185f7 100644
--- a/ldso/include/dl-elf.h
+++ b/ldso/include/dl-elf.h
@@ -18,6 +18,8 @@ struct elf_resolve;
 struct r_scope_elem;
 
 #include <dl-defs.h>
+#include <dlfcn.h>
+
 #ifdef __LDSO_CACHE_SUPPORT__
 extern int _dl_map_cache(void);
 extern int _dl_unmap_cache(void);
diff --git a/ldso/include/ldso.h b/ldso/include/ldso.h
index 6f3b728..e250e30 100644
--- a/ldso/include/ldso.h
+++ b/ldso/include/ldso.h
@@ -42,7 +42,6 @@
 #ifndef __ARCH_HAS_NO_SHARED__
 #include <dl-syscall.h>
 #include <dl-string.h>
-#include <dlfcn.h>
 /* Now the ldso specific headers */
 #include <dl-elf.h>
 #ifdef __UCLIBC_HAS_TLS__


More information about the uClibc-cvs mailing list