Bill Allombert on Thu, 20 May 2004 21:57:59 +0200 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
Re: Splitting get-kernel from get-archos |
On Thu, May 20, 2004 at 04:58:37PM +0200, Bill Allombert wrote: > Hello PARI developers, > > The attached patch fix that. Unfortunately, for obvious reason, in > interactive mode, the order of question is changed. The attached patch was slighly bogus. This one is better. > Once this issue is handled, I plan to commit the x86_64 support. Well, but there is still an issue unresolved: We need to known the sizeof(long) before setting -fPIC on amd64, at least according to our current rules about -fPIC). Cheers, Bill
Index: Configure =================================================================== RCS file: /home/cvs/pari/Configure,v retrieving revision 1.131 diff -u -r1.131 Configure --- Configure 30 Jan 2004 14:43:01 -0000 1.131 +++ Configure 20 May 2004 15:00:45 -0000 @@ -51,15 +51,16 @@ if test -z "$zcat" -a -n "$gzip"; then zcat="$gzip -dc"; fi ####################### CONFIGURE - ARCHITECTURE ############################ -. ./get_archos # arch, osname, asmarch, pretty +. ./get_archos # arch, osname ####################### CONFIGURE - COMPILATION ############################# . ./get_cc # $_cc_list (includes 'optimization'), extraflag +. ./get_double_format # doubleformat, sizeof_long +. ./get_kernel # asmarch, pretty . ./get_as # AS, ASFLAGS, KERNELCPPFLAGS, gnuas . ./get_ld # $_ld_list . ./get_dlld # $_dlld_list, fix libpari_base . ./get_perl # $_perl_list ####################### CONFIGURE - LIBC #################################### -. ./get_double_format # doubleformat, sizeof_long, update pretty . ./get_libc # $_has_list, update LIBS ####################### CONFIGURE - LIBRARIES ############################### # Looking for libraries: gmp, X11, gnuplot, readline Index: config/get_archos =================================================================== RCS file: /home/cvs/pari/config/get_archos,v retrieving revision 1.14 diff -u -r1.14 get_archos --- config/get_archos 15 Oct 2003 12:34:30 -0000 1.14 +++ config/get_archos 19 May 2004 22:01:06 -0000 @@ -34,85 +34,3 @@ osname=$ans fi -# -# A pretty name for the architecture -# The asm file used (if any) -# -case "$arch" in - sparc) asmarch=sparcv8_micro; pretty=Sparc ;; - sparcv7) asmarch=$arch; pretty=SparcV7 ;; - sparcv8_micro) asmarch=$arch; pretty=MicroSparc ;; - sparcv8_super) asmarch=$arch; pretty=SuperSparc ;; - sparcv9) asmarch=sparcv8_micro; pretty=UltraSparc ;; - i?86) asmarch=ix86 ; pretty=$arch ;; - ia64) asmarch=ia64 ; pretty=Itanium ;; - hppa) asmarch=none ; pretty='HP Precision' - case "$osname-`uname -r`" in - hpux-?.10.*) asmarch=$arch ;; - esac ;; - alpha) asmarch=$arch; pretty=Alpha ;; - ppc) asmarch=$arch; pretty='Power PC' ;; - arm*) asmarch=none; pretty=$arch ;; - mips) asmarch=none; pretty=MIPS ;; - sh3) asmarch=none; pretty=SH-3 ;; - sh5) asmarch=none; pretty=SH-5 ;; - vax) asmarch=none; pretty=VAX ;; - fx2800) asmarch=none; pretty='Alliant FX/2800' ;; - s390) asmarch=none; pretty='S/390' ;; - none) asmarch=none; pretty=unknown ;; - *) asmarch=none; pretty=$arch - echo " Warning ! architecture $arch not tested";; -esac - -# -# Modifications for pretty name and asm file -# -pretty="$pretty running $osname" - -tmp_kern=auto-none -if test -n "$kernel"; then - tmp_kern=$kernel -else - if test "$fastread" != yes; then - cat << EOM -========================================================================== -An optimized Pari kernel is available for these architectures -("none" means that we will use the portable C version of GP/PARI) -("-gmp" means we will use the GMP library (that needs to be installed)) -EOM - rep='none sparcv7 sparcv8_super sparcv8_micro ix86 alpha hppa ppc - none-gmp sparcv7-gmp sparcv8_super-gmp sparcv8_micro-gmp ix86-gmp alpha-gmp hppa-gmp ppc-gmp' - . ./display - echo $n ..."Which of these apply, if any ? $c" - dflt=$asmarch; . ./myread; - tmp_kern=$ans - cat << EOM -========================================================================== -EOM - fi -fi -tmp_kern=`./kernel-name $tmp_kern $asmarch none` -kernlvl0=`echo "$tmp_kern" | sed -e 's/\(.*\)-.*/\1/'` -kernlvl1=`echo "$tmp_kern" | sed -e 's/.*-\(.*\)/\1/'` - -case "$kernlvl0" in - none) prettyk="portable C";; - sparcv7) prettyk=SparcV7;; - sparcv8_super) prettyk=SuperSparc;; - sparcv8_micro) prettyk=MicroSparc;; - ix86) prettyk=ix86;; - ia64) prettyk=ia64;; - hppa) prettyk=HPPA;; - alpha) prettyk=Alpha;; - ppc) prettyk=PPC;; - *) prettyk="$kernlvl0";; -esac - -case "$kernlvl1" in - gmp) prettyk="$prettyk/GMP";; - none) ;; - *) prettyk="$prettyk/$kernlvl1";; -esac - -pretty="$pretty ($prettyk kernel)" -echo "Building for architecture: $pretty" Index: config/get_double_format =================================================================== RCS file: /home/cvs/pari/config/get_double_format,v retrieving revision 1.3 diff -u -r1.3 get_double_format --- config/get_double_format 4 Feb 2003 20:50:07 -0000 1.3 +++ config/get_double_format 20 May 2004 15:22:11 -0000 @@ -11,8 +11,8 @@ echo "***************************************************************" echo "Your 'double' type does not follow the IEEE754 format. Aborting" echo "PLEASE REPORT! (dbltor/rtodbl need to be fixed)"; exit 1;; - -) sizeof_long=8; pretty="$pretty 64-bit version";; - *) sizeof_long=4; pretty="$pretty 32-bit version";; + -) sizeof_long=8;; + *) sizeof_long=4;; esac echo "Given the previous choices, sizeof(long) is $sizeof_long chars." --- /dev/null Wed Jul 2 16:24:28 2003 +++ config/get_kernel Thu May 20 17:26:46 2004 @@ -0,0 +1,95 @@ +# Testing Architectures. Try uname to provide a default, then ask user. +# +case "$arch" in + sparc) asmarch=sparcv8_micro; pretty=Sparc ;; + sparcv7) asmarch=$arch; pretty=SparcV7 ;; + sparcv8_micro) asmarch=$arch; pretty=MicroSparc ;; + sparcv8_super) asmarch=$arch; pretty=SuperSparc ;; + sparcv9) case "$sizeof_long" in + 4) asmarch=sparcv8_micro;; + 8) asmarch=none;; + esac; pretty=UltraSparc ;; + i?86) asmarch=ix86 ; pretty=$arch ;; + x86_64) case "$sizeof_long" in + 4) asmarch=ix86;; + 8) asmarch=none;; + esac; pretty=$arch ;; + ia64) asmarch=ia64 ; pretty=Itanium ;; + hppa) asmarch=none ; pretty='HP Precision' + case "$osname-`uname -r`" in + hpux-?.10.*) asmarch=$arch ;; + esac ;; + alpha) asmarch=$arch; pretty=Alpha ;; + ppc) case "$sizeof_long" in + 4) asmarch=$arch;; + 8) asmarch=none;; + esac; pretty='Power PC' ;; + arm*) asmarch=none; pretty=$arch ;; + mips) asmarch=none; pretty=MIPS ;; + sh3) asmarch=none; pretty=SH-3 ;; + sh5) asmarch=none; pretty=SH-5 ;; + vax) asmarch=none; pretty=VAX ;; + fx2800) asmarch=none; pretty='Alliant FX/2800' ;; + s390) asmarch=none; pretty='S/390' ;; + none) asmarch=none; pretty=unknown ;; + *) asmarch=none; pretty=$arch + echo " Warning ! architecture $arch not tested";; +esac + +# +# Modifications for pretty name and asm file +# +pretty="$pretty running $osname" + +tmp_kern=auto-none +if test -n "$kernel"; then + tmp_kern=$kernel +else + if test "$fastread" != yes; then + cat << EOM +An optimized Pari kernel is available for these architectures +("none" means that we will use the portable C version of GP/PARI) +("-gmp" means we will use the GMP library (that needs to be installed)) +EOM + rep='none sparcv7 sparcv8_super sparcv8_micro ix86 alpha hppa ppc + none-gmp sparcv7-gmp sparcv8_super-gmp sparcv8_micro-gmp ix86-gmp alpha-gmp hppa-gmp ppc-gmp' + . ./display + echo $n ..."Which of these apply, if any ? $c" + dflt=$asmarch; . ./myread; + tmp_kern=$ans + cat << EOM +========================================================================== +EOM + fi +fi +tmp_kern=`./kernel-name $tmp_kern $asmarch none` +kernlvl0=`echo "$tmp_kern" | sed -e 's/\(.*\)-.*/\1/'` +kernlvl1=`echo "$tmp_kern" | sed -e 's/.*-\(.*\)/\1/'` + +case "$kernlvl0" in + none) prettyk="portable C";; + sparcv7) prettyk=SparcV7;; + sparcv8_super) prettyk=SuperSparc;; + sparcv8_micro) prettyk=MicroSparc;; + ix86) prettyk=ix86;; + ia64) prettyk=ia64;; + hppa) prettyk=HPPA;; + alpha) prettyk=Alpha;; + ppc) prettyk=PPC;; + *) prettyk="$kernlvl0";; +esac + +case "$kernlvl1" in + gmp) prettyk="$prettyk/GMP";; + none) ;; + *) prettyk="$prettyk/$kernlvl1";; +esac + +case "$sizeof_long" in + 4) pretty="$pretty ($prettyk kernel) 32-bit version";; + 8) pretty="$pretty ($prettyk kernel) 64-bit version";; +esac; +echo "Building for architecture: $pretty" +cat << EOM +========================================================================== +EOM