X-Git-Url: https://perl5.git.perl.org/perl5.git/blobdiff_plain/997d70a2a2f4a08920e782382c29bd614a7784ca..61f114aad960d46fcfb765ab137f0db8a54bb144:/Configure diff --git a/Configure b/Configure index 7df66f1..5842e8a 100755 --- a/Configure +++ b/Configure @@ -20,7 +20,7 @@ # $Id: Head.U,v 3.0.1.9 1997/02/28 15:02:09 ram Exp $ # -# Generated on Tue Feb 29 05:06:33 EET 2000 [metaconfig 3.0 PL70] +# Generated on Fri Mar 3 16:54:03 EET 2000 [metaconfig 3.0 PL70] # (with additional metaconfig patches by perlbug@perl.com) cat >/tmp/c1$$ <&4 $cat >try.c <&4 @@ -4423,7 +4423,6 @@ EOM use64bitint="$define" ;; esac -# Backward compatibility (use64bits is deprecated). case "$use64bits" in "$define"|true|[yY]*) cat <&4 @@ -4433,7 +4432,6 @@ EOM use64bitint="$define" ;; esac -# Thinko compatibilities. case "$use64bitints" in "$define"|true|[yY]*) cat <&4 @@ -4443,6 +4441,24 @@ EOM use64bitint="$define" ;; esac +case "$use64bitsint" in +"$define"|true|[yY]*) + cat <&4 + +*** There is no Configure -Duse64bitsint, using -Duse64bitint instead. +EOM + use64bitint="$define" + ;; +esac +case "$uselonglongs" in +"$define"|true|[yY]*) + cat <&4 + +*** There is no Configure -Duselonglongs, using -Duse64bitint instead. +EOM + use64bitint="$define" + ;; +esac case "$use64bitsall" in "$define"|true|[yY]*) cat <&4 @@ -4490,18 +4506,6 @@ esac set use64bitint eval $setvar -case "$use64bitint" in -"$define") case "$longsize" in - 8) dflt='y' ;; - *) dflt='n' ;; - esac - ;; -*) case "$use64bitall" in - "$define"|true|[yY]*) dflt='y' ;; - *) dflt='n' ;; - esac - ;; -esac cat <&4 -You requested the use of long doubles but you do not seem to have -the mathematic functions for long doubles. I'm disabling the use -of long doubles. +*** You requested the use of long doubles but you do not seem to have +*** the mathematic functions for long doubles. I'm disabling the use +*** of long doubles. + EOM uselongdouble=$undef ;; @@ -7280,6 +7286,10 @@ else installvendorbin="$vendorbinexp" fi +: see if qgcvt exists +set qgcvt d_qgcvt +eval $inlibc + : check for length of double echo " " case "$doublesize" in @@ -7356,118 +7366,6 @@ EOCP esac $rm -f try.* try -: Check how to convert floats to strings. -if test "X$d_Gconvert" = X; then - echo " " - echo "Checking for an efficient way to convert floats to strings." - $cat >try.c < - -#define I_STDLIB $i_stdlib -#ifdef I_STDLIB -#include -#endif - -int -checkit(expect, got) -char *expect; -char *got; -{ - if (strcmp(expect, got)) { - printf("%s oddity: Expected %s, got %s\n", - myname, expect, got); - exit(1); - } -} - -int main() -{ - char buf[64]; - buf[63] = '\0'; - - /* This must be 1st test on (which?) platform */ - /* Alan Burlison */ - Gconvert((DOUBLETYPE)0.1, 8, 0, buf); - checkit("0.1", buf); - - Gconvert((DOUBLETYPE)1.0, 8, 0, buf); - checkit("1", buf); - - Gconvert((DOUBLETYPE)0.0, 8, 0, buf); - checkit("0", buf); - - Gconvert((DOUBLETYPE)-1.0, 8, 0, buf); - checkit("-1", buf); - - /* Some Linux gcvt's give 1.e+5 here. */ - Gconvert((DOUBLETYPE)100000.0, 8, 0, buf); - checkit("100000", buf); - - /* Some Linux gcvt's give -1.e+5 here. */ - Gconvert((DOUBLETYPE)-100000.0, 8, 0, buf); - checkit("-100000", buf); - - exit(0); -} -EOP - case "$d_Gconvert" in - gconvert*) xxx_list='gconvert gcvt sprintf' ;; - gcvt*) xxx_list='gcvt gconvert sprintf' ;; - sprintf*) xxx_list='sprintf gconvert gcvt' ;; - *) xxx_list='gconvert gcvt sprintf' ;; - esac - - case "$d_longdbl$uselongdouble" in - definedefine) xxx_list="`echo $xxx_list|sed 's/gcvt/qgcvt gcvt/'`" ;; - esac - - for xxx_convert in $xxx_list; do - echo "Trying $xxx_convert..." - $rm -f try try$_o - set try -DTRY_$xxx_convert - if eval $compile; then - echo "$xxx_convert() found." >&4 - if ./try; then - echo "I'll use $xxx_convert to convert floats into a string." >&4 - break; - else - echo "...But $xxx_convert didn't work as I expected." - fi - else - echo "$xxx_convert NOT found." >&4 - fi - done - - case "$xxx_convert" in - gconvert) d_Gconvert='gconvert((x),(n),(t),(b))' ;; - gcvt) d_Gconvert='gcvt((x),(n),(b))' ;; - qgcvt) d_Gconvert='qgcvt((x),(n),(b))' ;; - *) d_Gconvert='sprintf((b),"%.*g",(n),(x))' ;; - esac -fi - echo " " if $test X"$d_longdbl" = X"$define"; then @@ -7579,6 +7477,159 @@ case "$sPRIfldbl" in ;; esac +: Check how to convert floats to strings. +if test "X$d_Gconvert" = X; then + echo " " + echo "Checking for an efficient way to convert floats to strings." + echo " " > try.c + case "$uselongdouble" in + "$define") echo "#define USE_LONG_DOUBLE" >>try.c ;; + esac + case "$d_longdbl" in + "$define") echo "#define HAS_LONG_DOUBLE" >>try.c ;; + esac + case "$d_PRIgldbl" in + "$define") echo "#define HAS_PRIgldbl" >>try.c ;; + esac + $cat >>try.c < + +#define I_STDLIB $i_stdlib +#ifdef I_STDLIB +#include +#endif + +int +checkit(expect, got) +char *expect; +char *got; +{ + if (strcmp(expect, got)) { + printf("%s oddity: Expected %s, got %s\n", + myname, expect, got); + exit(1); + } +} + +int main() +{ + char buf[64]; + buf[63] = '\0'; + + /* This must be 1st test on (which?) platform */ + /* Alan Burlison */ + Gconvert((DOUBLETYPE)0.1, 8, 0, buf); + checkit("0.1", buf); + + Gconvert((DOUBLETYPE)1.0, 8, 0, buf); + checkit("1", buf); + + Gconvert((DOUBLETYPE)1.1, 8, 0, buf); + checkit("1.1", buf); + + Gconvert((DOUBLETYPE)1.01, 8, 0, buf); + checkit("1.01", buf); + + Gconvert((DOUBLETYPE)1.001, 8, 0, buf); + checkit("1.001", buf); + + Gconvert((DOUBLETYPE)1.0001, 8, 0, buf); + checkit("1.0001", buf); + + Gconvert((DOUBLETYPE)1.00001, 8, 0, buf); + checkit("1.00001", buf); + + Gconvert((DOUBLETYPE)1.000001, 8, 0, buf); + checkit("1.000001", buf); + + Gconvert((DOUBLETYPE)0.0, 8, 0, buf); + checkit("0", buf); + + Gconvert((DOUBLETYPE)-1.0, 8, 0, buf); + checkit("-1", buf); + + /* Some Linux gcvt's give 1.e+5 here. */ + Gconvert((DOUBLETYPE)100000.0, 8, 0, buf); + checkit("100000", buf); + + /* Some Linux gcvt's give -1.e+5 here. */ + Gconvert((DOUBLETYPE)-100000.0, 8, 0, buf); + checkit("-100000", buf); + + exit(0); +} +EOP + case "$d_Gconvert" in + gconvert*) xxx_list='gconvert gcvt sprintf' ;; + gcvt*) xxx_list='gcvt gconvert sprintf' ;; + sprintf*) xxx_list='sprintf gconvert gcvt' ;; + *) xxx_list='gconvert gcvt sprintf' ;; + esac + + case "$d_longdbl$uselongdouble$d_qgcvt" in + "$define$define$define") xxx_list="`echo $xxx_list|sed 's/gcvt/qgcvt gcvt/'`" ;; + esac + + for xxx_convert in $xxx_list; do + echo "Trying $xxx_convert..." + $rm -f try try$_o + set try -DTRY_$xxx_convert + if eval $compile; then + echo "$xxx_convert() found." >&4 + if ./try; then + echo "I'll use $xxx_convert to convert floats into a string." >&4 + break; + else + echo "...But $xxx_convert didn't work as I expected." + fi + else + echo "$xxx_convert NOT found." >&4 + fi + done + + case "$xxx_convert" in + gconvert) d_Gconvert='gconvert((x),(n),(t),(b))' ;; + gcvt) d_Gconvert='gcvt((x),(n),(b))' ;; + qgcvt) d_Gconvert='qgcvt((x),(n),(b))' ;; + *) case "$uselongdouble$d_longdbl$d_PRIgldbl" in + "$define$define$define") + d_Gconvert="sprintf((b),\"%.*$sPRIgldbl\",(n),(x))" ;; + *) d_Gconvert='sprintf((b),"%.*g",(n),(x))' ;; + esac + ;; + esac +fi + : Initialize h_fcntl h_fcntl=false @@ -13590,7 +13641,7 @@ EOM done : In case none of those worked, prompt the user. case "$socksizetype" in - '') rp='What is the type for the last argument to accept()?' + '') rp='What is the type for socket address structure sizes?' dflt='int' . ./myread socksizetype=$ans @@ -13888,6 +13939,10 @@ eval $setvar set iconv.h i_iconv eval $inhdr +: see if this is a ieeefp.h system +set ieeefp.h i_ieeefp +eval $inhdr + : see if locale.h is available set locale.h i_locale eval $inhdr @@ -14323,6 +14378,10 @@ $rm -f varargs* set stddef.h i_stddef eval $inhdr +: see if this is a sunmath.h system +set sunmath.h i_sunmath +eval $inhdr + : see if sys/access.h is available set sys/access.h i_sysaccess eval $inhdr @@ -14997,6 +15056,7 @@ d_pwexpire='$d_pwexpire' d_pwgecos='$d_pwgecos' d_pwpasswd='$d_pwpasswd' d_pwquota='$d_pwquota' +d_qgcvt='$d_qgcvt' d_quad='$d_quad' d_readdir='$d_readdir' d_readlink='$d_readlink' @@ -15172,6 +15232,7 @@ i_float='$i_float' i_gdbm='$i_gdbm' i_grp='$i_grp' i_iconv='$i_iconv' +i_ieeefp='$i_ieeefp' i_inttypes='$i_inttypes' i_limits='$i_limits' i_locale='$i_locale' @@ -15197,6 +15258,7 @@ i_stdarg='$i_stdarg' i_stddef='$i_stddef' i_stdlib='$i_stdlib' i_string='$i_string' +i_sunmath='$i_sunmath' i_sysaccess='$i_sysaccess' i_sysdir='$i_sysdir' i_sysfile='$i_sysfile'