summaryrefslogtreecommitdiff
path: root/Configure
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2000-01-16 16:37:47 +0000
committerJarkko Hietaniemi <jhi@iki.fi>2000-01-16 16:37:47 +0000
commit628e1a40d854546bd93e9304795a0b62669c91c2 (patch)
tree7a102c2d04e15409ac916db7f582cc6268aea605 /Configure
parentff935051c0581ebaf8a1cbeb640d7c48ba85cbbc (diff)
downloadperl-628e1a40d854546bd93e9304795a0b62669c91c2.tar.gz
Continue qgcvt work; closer now but not yet there.
p4raw-id: //depot/cfgperl@4806
Diffstat (limited to 'Configure')
-rwxr-xr-xConfigure187
1 files changed, 95 insertions, 92 deletions
diff --git a/Configure b/Configure
index adc58e9ffb..29a59fb32d 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 Sat Jan 15 23:59:51 EET 2000 [metaconfig 3.0 PL70]
+# Generated on Sun Jan 16 18:22:25 EET 2000 [metaconfig 3.0 PL70]
# (with additional metaconfig patches by perlbug@perl.com)
cat >/tmp/c1$$ <<EOF
@@ -442,7 +442,6 @@ old_pthread_create_joinable=''
d_pthread_yield=''
d_sched_yield=''
sched_yield=''
-d_qgcvt=''
d_readdir=''
d_rewinddir=''
d_seekdir=''
@@ -7146,15 +7145,87 @@ case "$vendorprefix" in
;;
esac
-: see if qgcvt exists
-set qgcvt d_qgcvt
-eval $inlibc
+: check for length of double
+echo " "
+case "$doublesize" in
+'')
+ $echo $n "Checking to see how big your double precision numbers are...$c" >&4
+ $cat >try.c <<'EOCP'
+#include <stdio.h>
+int main()
+{
+ printf("%d\n", (int)sizeof(double));
+ exit(0);
+}
+EOCP
+ set try
+ if eval $compile_ok; then
+ doublesize=`./try`
+ $echo " $doublesize bytes." >&4
+ else
+ dflt='8'
+ echo "(I can't seem to compile the test program. Guessing...)"
+ rp="What is the size of a double precision number (in bytes)?"
+ . ./myread
+ doublesize="$ans"
+ fi
+ ;;
+esac
+$rm -f try.c try
+
+: check for long doubles
+echo " "
+$echo $n "Checking to see if your system supports long double..." $c >&4
+echo 'int main() { long double x = 7.0; }' > try.c
+set try
+if eval $compile; then
+ val="$define"
+ echo " Yes, it does." >&4
+else
+ val="$undef"
+ echo " No, it doesn't." >&4
+fi
+$rm try.*
+set d_longdbl
+eval $setvar
+
+: check for length of long double
+case "${d_longdbl}${longdblsize}" in
+$define)
+ echo " "
+ $echo $n "Checking to see how big your long doubles are..." $c >&4
+ $cat >try.c <<'EOCP'
+#include <stdio.h>
+int main()
+{
+ printf("%d\n", sizeof(long double));
+}
+EOCP
+ set try
+ set try
+ if eval $compile; then
+ longdblsize=`./try$exe_ext`
+ $echo " $longdblsize bytes." >&4
+ else
+ dflt='8'
+ echo " "
+ echo "(I can't seem to compile the test program. Guessing...)" >&4
+ rp="What is the size of a long double (in bytes)?"
+ . ./myread
+ longdblsize="$ans"
+ fi
+ if $test "X$doublesize" = "X$longdblsize"; then
+ echo "(That isn't any different from an ordinary double.)"
+ fi
+ ;;
+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 <<'EOP'
+ $cat >try.c <<EOP
#ifdef TRY_gconvert
#define Gconvert(x,n,t,b) gconvert((x),(n),(t),(b))
char *myname = "gconvert";
@@ -7166,14 +7237,23 @@ char *myname = "gcvt";
#ifdef TRY_qgcvt
#define Gconvert(x,n,t,b) qgcvt((x),(n),(b))
char *myname = "qgcvt";
+#define DOUBLETYPE long double
#endif
#ifdef TRY_sprintf
#define Gconvert(x,n,t,b) sprintf((b),"%.*g",(n),(x))
char *myname = "sprintf";
#endif
+#ifndef DOUBLETYPE
+#define DOUBLETYPE double
+#endif
+
#include <stdio.h>
+#ifdef I_STDLIB
+#include <stdlib.h>
+#endif
+
int
checkit(expect, got)
char *expect;
@@ -7193,24 +7273,24 @@ int main()
/* This must be 1st test on (which?) platform */
/* Alan Burlison <AlanBurlsin@unn.unisys.com> */
- Gconvert(0.1, 8, 0, buf);
+ Gconvert((DOUBLETYPE)0.1, 8, 0, buf);
checkit("0.1", buf);
- Gconvert(1.0, 8, 0, buf);
+ Gconvert((DOUBLETYPE)1.0, 8, 0, buf);
checkit("1", buf);
- Gconvert(0.0, 8, 0, buf);
+ Gconvert((DOUBLETYPE)0.0, 8, 0, buf);
checkit("0", buf);
- Gconvert(-1.0, 8, 0, buf);
+ Gconvert((DOUBLETYPE)-1.0, 8, 0, buf);
checkit("-1", buf);
/* Some Linux gcvt's give 1.e+5 here. */
- Gconvert(100000.0, 8, 0, buf);
+ Gconvert((DOUBLETYPE)100000.0, 8, 0, buf);
checkit("100000", buf);
/* Some Linux gcvt's give -1.e+5 here. */
- Gconvert(-100000.0, 8, 0, buf);
+ Gconvert((DOUBLETYPE)-100000.0, 8, 0, buf);
checkit("-100000", buf);
exit(0);
@@ -7223,8 +7303,8 @@ EOP
*) xxx_list='gconvert gcvt sprintf' ;;
esac
- case "$uselongdouble$d_qgcvt" in
- definedefine) xxx_list="`echo $xxx_list|sed s/gcvt/qgcvt/`" ;;
+ case "$d_longdbl$uselongdouble" in
+ definedefine) xxx_list="`echo $xxx_list|sed 's/gcvt/qgcvt gcvt/'`" ;;
esac
for xxx_convert in $xxx_list; do
@@ -7232,7 +7312,7 @@ EOP
$rm -f try try$_o
set try -DTRY_$xxx_convert
if eval $compile; then
- echo "$xxx_convert" found. >&4
+ echo "$xxx_convert() found." >&4
if ./try; then
echo "I'll use $xxx_convert to convert floats into a string." >&4
break;
@@ -7252,82 +7332,6 @@ EOP
esac
fi
-: check for length of double
-echo " "
-case "$doublesize" in
-'')
- $echo $n "Checking to see how big your double precision numbers are...$c" >&4
- $cat >try.c <<'EOCP'
-#include <stdio.h>
-int main()
-{
- printf("%d\n", (int)sizeof(double));
- exit(0);
-}
-EOCP
- set try
- if eval $compile_ok; then
- doublesize=`./try`
- $echo " $doublesize bytes." >&4
- else
- dflt='8'
- echo "(I can't seem to compile the test program. Guessing...)"
- rp="What is the size of a double precision number (in bytes)?"
- . ./myread
- doublesize="$ans"
- fi
- ;;
-esac
-$rm -f try.c try
-
-: check for long doubles
-echo " "
-$echo $n "Checking to see if your system supports long double..." $c >&4
-echo 'int main() { long double x = 7.0; }' > try.c
-set try
-if eval $compile; then
- val="$define"
- echo " Yes, it does." >&4
-else
- val="$undef"
- echo " No, it doesn't." >&4
-fi
-$rm try.*
-set d_longdbl
-eval $setvar
-
-: check for length of long double
-case "${d_longdbl}${longdblsize}" in
-$define)
- echo " "
- $echo $n "Checking to see how big your long doubles are..." $c >&4
- $cat >try.c <<'EOCP'
-#include <stdio.h>
-int main()
-{
- printf("%d\n", sizeof(long double));
-}
-EOCP
- set try
- set try
- if eval $compile; then
- longdblsize=`./try$exe_ext`
- $echo " $longdblsize bytes." >&4
- else
- dflt='8'
- echo " "
- echo "(I can't seem to compile the test program. Guessing...)" >&4
- rp="What is the size of a long double (in bytes)?"
- . ./myread
- longdblsize="$ans"
- fi
- if $test "X$doublesize" = "X$longdblsize"; then
- echo "(That isn't any different from an ordinary double.)"
- fi
- ;;
-esac
-$rm -f try.* try
-
echo " "
if $test X"$d_longdbl" = X"$define"; then
@@ -14561,7 +14565,6 @@ 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'