diff options
author | Reini Urban <rurban@x-ray.at> | 2011-11-15 16:11:02 -0600 |
---|---|---|
committer | Father Chrysostomos <sprout@cpan.org> | 2011-11-17 09:22:58 -0800 |
commit | ceaf555e5ba90cfbfecd1d510d2dc88501bf0360 (patch) | |
tree | 302810606f1c488841c7bf232880ec4789ce3afb /hints/solaris_2.sh | |
parent | cca38fda51b9e232acf5d92b06d2c4b0af253f62 (diff) | |
download | perl-ceaf555e5ba90cfbfecd1d510d2dc88501bf0360.tar.gz |
Detect SunOS CC workshop c++ compiler
Solaris 11 SunStudio 12.2. ships without cc, so CC must be used.
Detect it and set ccversion correctly
Diffstat (limited to 'hints/solaris_2.sh')
-rw-r--r-- | hints/solaris_2.sh | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/hints/solaris_2.sh b/hints/solaris_2.sh index 508cd3ebc2..b147b61eb0 100644 --- a/hints/solaris_2.sh +++ b/hints/solaris_2.sh @@ -311,11 +311,15 @@ else cat > try.c << 'EOM' #include <stdio.h> int main() { -#ifdef __SUNPRO_C +#if defined(__SUNPRO_C) printf("workshop\n"); #else +#if defined(__SUNPRO_CC) + printf("workshop CC\n"); +#else printf("\n"); #endif +#endif return(0); } EOM @@ -323,7 +327,13 @@ EOM if $tryworkshopcc >/dev/null 2>&1; then cc_name=`./try` if test "$cc_name" = "workshop"; then - ccversion="`${cc:-cc} -V 2>&1|sed -n -e '1s/^cc: //p'`" + ccversion="`${cc:-cc} -V 2>&1|sed -n -e '1s/^cc: //ip'`" + if test ! "$use64bitall_done"; then + loclibpth="/usr/lib /usr/ccs/lib `$getworkshoplibs` $loclibpth" + fi + fi + if test "$cc_name" = "workshop CC"; then + ccversion="`${cc:-CC} -V 2>&1|sed -n -e '1s/^CC: //ip'`" if test ! "$use64bitall_done"; then loclibpth="/usr/lib /usr/ccs/lib `$getworkshoplibs` $loclibpth" fi |