This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Thou shalt not printf longs with %d.
[perl5.git] / hints / solaris_2.sh
index 8c280e3..a2a4087 100644 (file)
@@ -343,10 +343,14 @@ $define|true|[yY]*)
        lflibs="`getconf LFS_LIBS 2>/dev/null|sed -e 's@^-l@@' -e 's@ -l@ @g`"
        case "$lfcflags$lfldflags$lflibs" in
        '');;
-       *) uselonglong="$define"
-           echo "(Large files in Solaris require also long longs, using long longs...)"
-          ccflags="$ccflags -DUSE_LONG_LONG $lfcflags"
-          ldflags="$ldflags $ldldflags"
+       *) use64bits="$define"
+           echo "(Large files in Solaris require also using long longs...)"
+          case "$ccflags" in
+          *-DUSE_64_BITS*) ;;
+          *) ccflags="$ccflags -DUSE_64_BITS" ;;
+          esac
+          ccflags="$ccflags $lfcflags"
+          ldflags="$ldflags $lfldflags"
           libswanted="$libswanted $lflibs"
           ;;
        esac
@@ -372,8 +376,8 @@ EOM
                ;;
            esac
            case "$ccflags" in
-           *-DUSE_LONG_LONG*) ;;
-           *) ccflags="$ccflags -DUSE_LONG_LONG" ;;
+           *-DUSE_64_BITS*) ;;
+           *) ccflags="$ccflags -DUSE_64_BITS" ;;
            esac
            # When a 64-bit cc becomes available $archname64
            # may need setting so that $archname gets it attached.