GNU bug report logs - #54788
libtool -export-symbols-regex broken on Solaris against GNU ld

Previous Next

Package: libtool;

Reported by: Frederic Berat <fberat <at> redhat.com>

Date: Fri, 8 Apr 2022 12:56:02 UTC

Severity: normal

To reply to this bug, email your comments to 54788 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-libtool <at> gnu.org:
bug#54788; Package libtool. (Fri, 08 Apr 2022 12:56:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Frederic Berat <fberat <at> redhat.com>:
New bug report received and forwarded. Copy sent to bug-libtool <at> gnu.org. (Fri, 08 Apr 2022 12:56:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Frederic Berat <fberat <at> redhat.com>
To: bug-libtool <at> gnu.org
Subject: libtool -export-symbols-regex broken on Solaris against GNU ld
Date: Fri, 8 Apr 2022 09:29:24 +0200
[Message part 1 (text/plain, inline)]
Hello,

The following problem has been found by the GCC team:

As mentioned in https://gcc.gnu.org/PR102426 , libtool
-export-symbols-regex implementation on *-solaris* blindly assumes that Sun
ld is used and uses -Wl,-M option:

      if test "$GCC" = yes; then
        wlarc='${wl}'
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h
${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
        _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" >
$lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo
"local: *; };" >> $lib.exp~
          $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h
${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
      else

in libtool.m4.

But when GCC is configured to use GNU ld, that is wrong, for the
if test "$with_gnu_ld" = yes case it needs to use (if
supports_anon_versioning)
-Wl,-version-script like e.g. on Linux.

Frédéric Bérat

Red Hat -  Platform Tools
https://www.redhat.com
[Message part 2 (text/html, inline)]

This bug report was last modified 2 years and 265 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.