From 9ac3b5047e6bbea03437d020fab9a728e123445b Mon Sep 17 00:00:00 2001 From: Siddhesh Poyarekar Date: Thu, 4 Apr 2013 19:43:56 +0530 Subject: Fix static build when configured with --disable-hidden-plt Fixes BZ #15337. Static builds fail with the following warning: /home/tools/glibc/glibc/nptl/../nptl/sysdeps/unix/sysv/linux/x86_64/cancellation.S:80: undefined reference to `__GI___pthread_unwind' When the source is configured with --disable-hidden-plt. This is because the preprocessor conditional in cancellation.S only checks if the build is for SHARED, whereas hidden_def is defined appropriately only for a SHARED build that will have symbol versioning *and* hidden defs are enabled. The last case is false here. --- nptl/sysdeps/unix/sysv/linux/x86_64/cancellation.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'nptl/sysdeps') diff --git a/nptl/sysdeps/unix/sysv/linux/x86_64/cancellation.S b/nptl/sysdeps/unix/sysv/linux/x86_64/cancellation.S index b2845723fc..2cc84c189b 100644 --- a/nptl/sysdeps/unix/sysv/linux/x86_64/cancellation.S +++ b/nptl/sysdeps/unix/sysv/linux/x86_64/cancellation.S @@ -22,7 +22,7 @@ #include "lowlevellock.h" #ifdef IS_IN_libpthread -# ifdef SHARED +# if defined SHARED && defined DO_VERSIONING && !defined NO_HIDDEN # define __pthread_unwind __GI___pthread_unwind # endif #else -- cgit 1.4.1