This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: perl@16573


On Mon 13 May 2002 17:25, "H.Merijn Brand" <h.m.brand@hccnet.nl> wrote:
> > Nice:
> > 
> > - gcc 3.0 vs 64-bit hpux hints [Merijn]
> 
> I can reproduce it, and it is in investigation mode :)
> Expect something soon

Hmmm, the problem was just a little more complicated

a5:/pro/3gl/CPAN/perl-current 136 > gcc --version
3.0.4
a5:/pro/3gl/CPAN/perl-current 137 > gcc64 --version
gcc64 (GCC) 3.1 20020506 (prerelease)
Copyright (C) 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

a5:/pro/3gl/CPAN/perl-current 138 >


For the moment, patch below works for 3.0.x and 3.1, but I guess we need more
protective measures if the GNU people are realy going to change the version
reports

--- hints/hpux.sh 2002-04-14 17:04:38.000000000 +0200
+++ hints/hpux.sh 2002-05-13 18:25:48.000000000 +0200
@@ -76,12 +76,17 @@
            ccflags="$cc_cppflags"
            if [ "X$gccversion" = "X" ]; then
                # Done too late in Configure if hinted
-               gccversion=`$cc --version`
+               gccversion=`$cc --version | sed 's/.*(GCC) *//`
                fi
            case "$gccversion" in
                [012]*) # HP-UX and gcc-2.* break UINT32_MAX :-(
                        ccflags="$ccflags -DUINT32_MAX_BROKEN"
                        ;;
+               3*)     # GCC (both 32bit and 64bit) will define __STDC_EXT__
+                       # by default when using GCC 3.0 and newer versions of
+                       # the compiler.
+                       cppflags="$cc_cppflags"
+                       ;;
                esac
            case "`getconf KERNEL_BITS 2>/dev/null`" in
                *64*)
@@ -131,9 +136,9 @@
     *)      ccisgcc=''
            ccversion=`which cc | xargs what | awk '/Compiler/{print $2}'`
            case "$ccflags" in
-           "-Ae "*) ;;
-           *) ccflags="-Ae $cc_cppflags -Wl,+vnocompatwarnings" ;;
-           esac
+               "-Ae "*) ;;
+               *) ccflags="-Ae $cc_cppflags -Wl,+vnocompatwarnings" ;;
+               esac
            # Needed because cpp does only support -Aa (not -Ae)
            cpplast='-'
            cppminus='-'

-- 
H.Merijn Brand        Amsterdam Perl Mongers (http://amsterdam.pm.org/)
using perl-5.6.1, 5.7.3 & 631 on HP-UX 10.20 & 11.00, AIX 4.2, AIX 4.3,
  WinNT 4, Win2K pro & WinCE 2.11.  Smoking perl CORE: smokers@perl.org
http://archives.develooper.com/daily-build@perl.org/   perl-qa@perl.org
send smoke reports to: smokers-reports@perl.org, QA: http://qa.perl.org



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]