]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
MIPS, SPARC: fix wrong vfork aliases in libpthread.so
authorAurelien Jarno <aurelien@aurel32.net>
Sat, 18 Jun 2016 17:11:23 +0000 (19:11 +0200)
committerAurelien Jarno <aurelien@aurel32.net>
Sun, 19 Jun 2016 13:49:52 +0000 (15:49 +0200)
With recent binutils versions the GNU libc fails to build on at least
MISP and SPARC, with this kind of error:

  /home/aurel32/glibc/glibc-build/nptl/libpthread.so:(*IND*+0x0): multiple definition of `vfork@GLIBC_2.0'
  /home/aurel32/glibc/glibc-build/nptl/libpthread.so::(.text+0xee50): first defined here

It appears that on these architectures pt-vfork.S includes vfork.S
(through the alpha version of pt-vfork.S) and that the __vfork aliases
are not conditionalized on IS_IN (libc) like on other architectures.
Therefore the aliases are also wrongly included in libpthread.so.

Fix this by properly conditionalizing the aliases like on other
architectures.

Changelog:
* sysdeps/unix/sysv/linux/mips/vfork.S (__vfork): Conditionalize
hidden_def, weak_alias and strong_alias on [IS_IN (libc)].
* sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S: Likewise.

(cherry picked from commit 43c2948756bb6e144c7b871e827bba37d61ad3a3)

ChangeLog
sysdeps/unix/sysv/linux/mips/vfork.S
sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S
sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S

index 2d55a22474c6656430c3a19d35892acf9f03e95b..0d3a8025cb2e8bc74e8acd1c2182f27e4eb686d3 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2016-06-18  Aurelien Jarno  <aurelien@aurel32.net>
+
+       * sysdeps/unix/sysv/linux/mips/vfork.S (__vfork): Conditionalize
+       hidden_def, weak_alias and strong_alias on [IS_IN (libc)].
+       * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S: Likewise.
+       * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S: Likewise.
+
 2016-01-22  Stefan Liebler  <stli@linux.vnet.ibm.com>
 
        * string/tst-endian.c: Include <libc-internal.h>.
index 8915bea1a2bffed5caaf2c6a8b9793639e5d4d6a..60a91310ff85eb82ac7300f675f18070e752e400 100644 (file)
@@ -106,6 +106,8 @@ L(error):
 #endif
        END(__vfork)
 
+#if IS_IN (libc)
 libc_hidden_def(__vfork)
 weak_alias (__vfork, vfork)
 strong_alias (__vfork, __libc_vfork)
+#endif
index e71ecbc776c80e6685762c13bbfb97da376f86c3..3727877fd3f6daa1e4706b649f93d6476cd882ac 100644 (file)
@@ -44,6 +44,8 @@ ENTRY(__vfork)
         nop
 END(__vfork)
 
+#if IS_IN (libc)
 libc_hidden_def (__vfork)
 weak_alias (__vfork, vfork)
 strong_alias (__vfork, __libc_vfork)
+#endif
index 6939ba35220360daa758d3d864805b3398a5bed3..7bf5165b8ecc735d4d9cc175406bc7c78913ab6d 100644 (file)
@@ -44,6 +44,8 @@ ENTRY(__vfork)
         nop
 END(__vfork)
 
+#if IS_IN (libc)
 libc_hidden_def (__vfork)
 weak_alias (__vfork, vfork)
 strong_alias (__vfork, __libc_vfork)
+#endif