about summary refs log tree commit diff
path: root/sysdeps/generic/dl-sysdep.h
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/generic/dl-sysdep.h')
-rw-r--r--sysdeps/generic/dl-sysdep.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/sysdeps/generic/dl-sysdep.h b/sysdeps/generic/dl-sysdep.h
index b39103cbc2..98bd5dbe84 100644
--- a/sysdeps/generic/dl-sysdep.h
+++ b/sysdeps/generic/dl-sysdep.h
@@ -25,4 +25,8 @@
    all the libc functions that ld.so uses are called without PLT and always
    get the versions linked into ld.so rather than the libc ones.  */
 
-#define RTLD_PRIVATE_ERRNO 1
+#ifdef IS_IN_rtld
+# define RTLD_PRIVATE_ERRNO 1
+#else
+# define RTLD_PRIVATE_ERRNO 0
+#endif