]> granicus.if.org Git - python/commitdiff
Use -G option for linking shared libraries on Solaris (SF patch #103656).
authorNeil Schemenauer <nascheme@enme.ucalgary.ca>
Mon, 19 Feb 2001 04:47:42 +0000 (04:47 +0000)
committerNeil Schemenauer <nascheme@enme.ucalgary.ca>
Mon, 19 Feb 2001 04:47:42 +0000 (04:47 +0000)
Compile shared object files using -fPIC option when using GCC on Solaris (SF
patch #103865).  Closes bug #132783.  Move config.c generated by makesetup to
the Modules directory.

configure.in

index c9756f1fabfe27186193b947a8a1f95e17ba3792..909b914d0582f9f5af979d44fb8379194467f7dc 100644 (file)
@@ -544,7 +544,7 @@ then
        SunOS/4*) LDSHARED="ld";;
        SunOS/5*) 
                if test "$GCC" = "yes"
-               then LDSHARED='$(CC) -shared'
+               then LDSHARED='$(CC) -G'
                else LDSHARED="ld -G";
                fi ;;
        hp*|HP*) LDSHARED="ld -b";;
@@ -590,6 +590,9 @@ AC_MSG_CHECKING(CCSHARED)
 if test -z "$CCSHARED"
 then
        case $ac_sys_system/$ac_sys_release in
+       SunOS*) if test "$GCC" = yes;
+               then CCSHARED="-fPIC";
+               fi;;
        hp*|HP*) if test "$GCC" = yes;
                 then CCSHARED="-fpic";
                 else CCSHARED="+z";
@@ -1441,3 +1444,4 @@ echo "creating Makefile"
 $SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \
                        -s Modules Modules/Setup.config \
                        Modules/Setup Modules/Setup.local
+mv config.c Modules