Use -Bsymbolic for linking all shared objects.
authorMichel Dänzer <michel@tungstengraphics.com>
Tue, 4 Dec 2007 09:46:45 +0000 (10:46 +0100)
committerMichel Dänzer <michel@tungstengraphics.com>
Tue, 4 Dec 2007 17:31:29 +0000 (18:31 +0100)
Fixes https://bugs.freedesktop.org/show_bug.cgi?id=10132 .

Also remove comment about SONAME, as SONAME only applies to shared libraries.

bin/mklib

index 2bfd1b9e04968a25a91c78677fc724d11b623a58..7d271de11805763984cebaf9e5ccc68232059364 100755 (executable)
--- a/bin/mklib
+++ b/bin/mklib
@@ -208,8 +208,13 @@ case $ARCH in
        if [ $NOPREFIX = 1 ] ; then
            # No "lib" or ".so" part
            echo "mklib: Making" $ARCH "shared library: " ${LIBNAME}
-           #OPTS="-shared -Wl,-soname,${LIBNAME}"  # soname???
-           OPTS="-shared"
+           case $ARCH in 'Linux' | 'GNU' | GNU/*)
+               OPTS="-Xlinker -Bsymbolic -shared"
+           ;;
+           *)
+               OPTS="-shared"
+           ;;
+           esac
 
            # Check if objects are 32-bit and we're running in 64-bit
            # environment.  If so, pass -m32 flag to linker.