This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Android hints: set targetsh to /system/bin/sh
[perl5.git] / hints / hpux.sh
index 313511e..e610e17 100644 (file)
@@ -439,7 +439,7 @@ case "$ccisgcc" in
                        B3910B*A.06.15)
                        # > cc --version
                        # cc: HP C/aC++ B3910B A.06.15 [May 16 2007]
-                       # Has optimizing problems with +O2 for blead (5.15.9),
+                       # Has optimizing problems with +O2 for blead (5.17.4),
                        # see https://rt.perl.org:443/rt3/Ticket/Display.html?id=103668.
                        #
                        # +O2 +Onolimit +Onoprocelim  +Ostore_ordering \
@@ -533,6 +533,27 @@ EOF
     fi
 EOCBU
 
+cat >config.arch <<'EOCBU'
+# This script UU/config.arch will get 'called-back' by Configure after
+# all other configurations are done just before config.h is generated
+case "$archname:$optimize" in
+  PA*:*-g*[-+]O*|PA*:*[-+]O*-g*)
+    case "$ccflags" in
+      *DD64*) ;;
+      *) case "$ccversion" in
+         # Only on PA-RISC. B3910B (aCC) is not faulty
+         # B.11.* and A.10.* are
+         [AB].1*)
+             # cc: error 1414: Can't handle preprocessed file foo.i if -g and -O specified.
+             echo "HP-UX C-ANSI-C on PA-RISC does not accept both -g and -O on preprocessed files" >&4
+             echo "when compiling in 32bit mode. The optimizer will be disabled." >&4
+             optimize=`echo "$optimize" | sed -e 's/[-+]O[0-9]*//' -e 's/+Onolimit//' -e 's/^ *//'`
+             ;;
+         esac
+      esac
+  esac
+EOCBU
+
 cat >UU/uselargefiles.cbu <<'EOCBU'
 # This script UU/uselargefiles.cbu will get 'called-back' by Configure
 # after it has prompted the user for whether to use large files.