From: Jarkko Hietaniemi Date: Thu, 24 Feb 2000 18:40:25 +0000 (+0000) Subject: Tidy up the 64-bit (and socklen_t) type probing. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=c5f05a911e8d8ba7e1354bba36ffbd709c382a86;p=p5sagit%2Fp5-mst-13.2.git Tidy up the 64-bit (and socklen_t) type probing. p4raw-id: //depot/cfgperl@5243 --- diff --git a/Configure b/Configure index 23e41eb..b801ab8 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 Thu Feb 24 17:45:39 EET 2000 [metaconfig 3.0 PL70] +# Generated on Thu Feb 24 20:37:06 EET 2000 [metaconfig 3.0 PL70] # (with additional metaconfig patches by perlbug@perl.com) cat >/tmp/c1$$ <&4 +echo "Checking to see if you have long double..." >&4 echo 'int main() { long double x = 7.0; }' > try.c set try if eval $compile; then val="$define" - echo " " >&4 echo "You have long double." else val="$undef" - echo " " >&4 echo "You do not have long double." fi $rm try.* @@ -8816,32 +8814,9 @@ set fpathconf d_fpathconf eval $inlibc -: check for off64_t -echo " " -echo "Checking to see if your system supports off64_t..." >&4 -$cat >try.c < -#include -int main() { off64_t x = 7; } -EOCP -set try -if eval $compile; then - val="$define" - echo "Yes, it does." -else - val="$undef" - echo "No, it doesn't." - case "$lseeksize" in - 8) echo "(Your off_t is 64 bits, so you could use that.)" ;; - esac -fi -$rm -f try.* try -set d_off64_t -eval $setvar - : check for fpos64_t echo " " -echo "Checking to see if your system supports fpos64_t..." >&4 +echo "Checking to see if you have fpos64_t..." >&4 $cat >try.c < int main() { fpos64_t x = 7; } @@ -8849,10 +8824,10 @@ EOCP set try if eval $compile; then val="$define" - echo "Yes, it does." + echo "You have fpos64_t." else val="$undef" - echo "No, it doesn't." + echo "You do not have fpos64_t." case "$fpossize" in 8) echo "(Your fpos_t is 64 bits, so you could use that.)" ;; esac @@ -9300,7 +9275,7 @@ eval $setvar : check for int64_t echo " " -$echo $n "Checking to see if your system supports int64_t...$c" >&4 +echo "Checking to see if you have int64_t..." >&4 $cat >try.c < #$i_inttypes I_INTTYPES @@ -9312,11 +9287,9 @@ EOCP set try if eval $compile; then val="$define" - echo " " >&4 echo "You have int64_t." else val="$undef" - echo " " >&4 echo "You do not have int64_t." fi $rm -f try try.* @@ -9425,16 +9398,14 @@ eval $inlibc : check for long long echo " " -$echo $n "Checking to see if your system supports long long..." $c >&4 +echo "Checking to see if you have long long..." >&4 echo 'int main() { long long x = 7; return 0; }' > try.c set try if eval $compile; then val="$define" - echo " " >&4 echo "You have have long long." else val="$undef" - echo " " >&4 echo "You do not have long long." fi $rm try.* @@ -9929,6 +9900,30 @@ esac $rm -f try.* try + +: check for off64_t +echo " " +echo "Checking to see if you have off64_t..." >&4 +$cat >try.c < +#include +int main() { off64_t x = 7; } +EOCP +set try +if eval $compile; then + val="$define" + echo "You have off64_t." +else + val="$undef" + echo "You do not have off64_t." + case "$lseeksize" in + 8) echo "(Your off_t is 64 bits, so you could use that.)" ;; + esac +fi +$rm -f try.* try +set d_off64_t +eval $setvar + : see if POSIX threads are available set pthread.h i_pthread eval $inhdr @@ -10949,9 +10944,14 @@ set d_sigsetjmp eval $setvar $rm -f try.c try +: see what type is used for size_t +rp="What is the type used for the length parameter for string functions?" +set size_t sizetype 'unsigned int' stdio.h sys/types.h +eval $typedef_ask + : check for socklen_t echo " " -$echo $n "Checking to see if your system supports socklen_t...$c" >&4 +echo "Checking to see if you have socklen_t..." >&4 $cat >try.c < #$d_socket HAS_SOCKET @@ -10963,12 +10963,13 @@ EOCP set try if eval $compile; then val="$define" - echo " " >&4 echo "You have socklen_t." else val="$undef" - echo " " >&4 echo "You do not have socklen_t." + case "$sizetype" in + size_t) echo "(You do have size_t, that might work.)" ;; + esac fi $rm -f try try.* set d_socklen_t @@ -12745,11 +12746,6 @@ EOSH chmod +x protochk $eunicefix protochk -: see what type is used for size_t -rp="What is the type used for the length parameter for string functions?" -set size_t sizetype 'unsigned int' stdio.h sys/types.h -eval $typedef_ask - : check for type of arguments to gethostbyaddr. if test "X$netdb_host_type" = X -o "X$netdb_hlen_type" = X; then case "$d_gethbyaddr" in diff --git a/config_h.SH b/config_h.SH index 4d679f2..cd14526 100644 --- a/config_h.SH +++ b/config_h.SH @@ -1356,6 +1356,11 @@ sed <config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un- */ #$d_fd_set HAS_FD_SET /**/ +/* HAS_FPOS64_T: + * This symbol will be defined if the C compiler supports fpos64_t. + */ +#$d_fpos64_t HAS_FPOS64_T /**/ + /* HAS_STRUCT_FS_DATA: * This symbol, if defined, indicates that the struct fs_data * to do statfs() is supported. @@ -1720,6 +1725,11 @@ sed <config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un- */ #$d_msg HAS_MSG /**/ +/* HAS_OFF64_T: + * This symbol will be defined if the C compiler supports off64_t. + */ +#$d_off64_t HAS_OFF64_T /**/ + /* HAS_OPEN3: * This manifest constant lets the C program know that the three * argument form of open(2) is available. @@ -2443,15 +2453,6 @@ sed <config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un- */ #$installusrbinperl INSTALL_USR_BIN_PERL /**/ -/* HAS_OFF64_T: - * This symbol will be defined if the C compiler supports off64_t. - */ -/* HAS_FPOS64_T: - * This symbol will be defined if the C compiler supports fpos64_t. - */ -#$d_off64_t HAS_OFF64_T /**/ -#$d_fpos64_t HAS_FPOS64_T /**/ - /* PERL_PRIfldbl: * This symbol, if defined, contains the string used by stdio to * format long doubles (format 'f') for output.