This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PATCH: Don't define __strpbrk_sse42 in static library


Hi,

[hjl@gnu-6 glibc]$ nm  /usr/lib/libc.a 2>&1  | grep __strpbrk
00000c00 T __strpbrk_c2
00000c40 T __strpbrk_c3
00000630 T __strpbrk_cg
00000670 T __strpbrk_g
         U __strpbrk_ia32
00000000 T __strpbrk_sse42
[hjl@gnu-6 glibc]$ nm  /usr/lib64/libc.a 2>&1  | grep __strpbrk
0000000000000340 T __strpbrk_c2
0000000000000390 T __strpbrk_c3
                 U __strpbrk_sse2
0000000000000000 T __strpbrk_sse42
[hjl@gnu-6 glibc]$ 

We don't need __strpbrk_sse42 in libc.a.  This patch fixes it.

H.J.
---
2010-03-24  H.J. Lu  <hongjiu.lu@intel.com>

	* sysdeps/x86_64/multiarch/strpbrk-c.c: Define only if SHARED
	is defined.

diff --git a/sysdeps/x86_64/multiarch/strpbrk-c.c b/sysdeps/x86_64/multiarch/strpbrk-c.c
index c58dcb5..0237309 100644
--- a/sysdeps/x86_64/multiarch/strpbrk-c.c
+++ b/sysdeps/x86_64/multiarch/strpbrk-c.c
@@ -1,4 +1,8 @@
+/* Don't define multiple versions for strpbrk in static library since we
+   need strpbrk before the initialization happened.  */
+#ifdef SHARED
 #define USE_AS_STRPBRK
 #define STRCSPN_SSE2 __strpbrk_sse2
 #define STRCSPN_SSE42 __strpbrk_sse42
 #include "strcspn-c.c"
+#endif


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]