This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: Add hppa*64* support to libtool in binutils
- From: John David Anglin <dave at hiauly1 dot hia dot nrc dot ca>
- To: law at redhat dot com
- Cc: ross dot alexander at uk dot neceur dot com, aoliva at redhat dot com, binutils at sources dot redhat dot com, binutils-owner at sources dot redhat dot com, gcc-patches at gcc dot gnu dot org, libtool at sources dot redhat dot com, sje at cup dot hp dot com, config-patches at gnu dot org
- Date: Tue, 13 Aug 2002 16:04:42 -0400
- Subject: Re: Add hppa*64* support to libtool in binutils
- Organization: National Research Council of Canada
- References: <200208131739.g7DHdbH09309@porcupine.slc.redhat.com>
- Reply-to: dave dot anglin at nrc dot ca
Jeff Law wrote:
> In message <200208131637.g7DGbYKR027710@hiauly1.hia.nrc.ca>, "John David Anglin
>
> >That would certainly seem convenient. Also, libtool runs configure
> >in its testsuite. When I build it for hppa64, the testsuite unfortunately
> >ignores the options used configuring it and as a result configures
> >for hppa2.0w even though it is using 64bit tools :-(
> Hmm, I hadn't thought of this case. It probably makes sense though.
>
> ie, if I've done something like
>
> CC=<some PA64 compiler>
> configure
>
> Then, shouldn't that build a 64bit toolchain? We have (in effect) explicitly
> asked for 64bit tools by the setting of CC. It should probably also return
> hppa64-whatever as the "guessed" system.
I believe that the attached patch will do the trick. Tested with a
couple of configurations of libtool in hppa2.0w-hp-hpux11.00 and
hppa64-hp-hpux11.00 modes.
Dave
2002-08-13 John David Anglin <dave@hiauly1.hia.nrc.ca>
* config.guess (9000/[34678]??:HP-UX:*:*): For 64-bit kernels, set
HP_ARCH to hppa64 if the code level of CC_FOR_BUILD is 2.0w or 2.0W.
--- config.guess.orig Mon Jan 7 17:09:42 2002
+++ config.guess Tue Aug 13 15:20:07 2002
@@ -603,6 +603,20 @@
rm -f $dummy.c $dummy
fi ;;
esac
+ if [ "${HP_ARCH}" = "hppa2.0w" ]; then
+ # Check if the arch should be hppa2.0w or hppa64.
+ eval $set_cc_for_build
+ sed 's/^ //' << EOF >$dummy.c
+ int main () {}
+EOF
+ (CCOPTS= $CC_FOR_BUILD $dummy.c -S) && HP_LEVEL=`awk '{if (NR==1) print $2}' $dummy.s`
+ rm -f $dummy.c $dummy.s
+ case ${HP_LEVEL} in
+ 2.0w | 2.0W)
+ HP_ARCH=hppa64
+ ;;
+ esac
+ fi
echo ${HP_ARCH}-hp-hpux${HPUX_REV}
exit 0 ;;
ia64:HP-UX:*:*)