summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndy Dougherty <doughera@lafayette.edu>2013-05-10 19:19:57 +1000
committerTony Cook <tony@develop-help.com>2013-05-10 22:15:41 +1000
commit767f54d7e2d963710cc4a76292c729207900cd3a (patch)
tree02732a9116117e4dae23cb5f4866fdc14774a2e5
parent1ddb6a49bccfef91b5cb075feea5feb1aaded968 (diff)
downloadperl-767f54d7e2d963710cc4a76292c729207900cd3a.tar.gz
[perl #66604] 64bit compilation Problem on Solaris x86_64
hints changes
-rw-r--r--hints/solaris_2.sh14
1 files changed, 12 insertions, 2 deletions
diff --git a/hints/solaris_2.sh b/hints/solaris_2.sh
index 5e6cf103df..106f87e7f8 100644
--- a/hints/solaris_2.sh
+++ b/hints/solaris_2.sh
@@ -300,7 +300,7 @@ doesn't work, you should use -B/usr/ccs/bin/ instead.
END
ccdlflags="$ccdlflags -Wl,-E"
- lddlflags="$lddlflags -Wl,-E -G"
+ lddlflags="$lddlflags -Wl,-E -shared"
fi
fi
@@ -588,7 +588,17 @@ EOM
# ccflags="$ccflags -Wa,`getconf XBS5_LP64_OFF64_CFLAGS 2>/dev/null`"
# fi
ldflags="$ldflags -m64"
- lddlflags="$lddlflags -G -m64"
+
+ # See [perl #66604]: On Solaris 11, gcc -m64 on amd64
+ # appears not to understand -G. (gcc -G has not caused
+ # problems on other platforms in the past.) gcc versions
+ # at least as old as 3.4.3 support -shared, so just
+ # use that with Solaris 11 and later, but keep
+ # the old behavior for older Solaris versions.
+ case "$osvers" in
+ 2.?|2.10) lddlflags="$lddlflags -G -m64" ;;
+ *) lddlflags="$lddlflags -shared -m64" ;;
+ esac
;;
*)
getconfccflags="`getconf XBS5_LP64_OFF64_CFLAGS 2>/dev/null`"