X-Git-Url: https://perl5.git.perl.org/perl5.git/blobdiff_plain/2c476adc76fa529470c25a2721f54d8be0fabb12..341b7876042ff99b0d11a456f2139ba2657ef7e2:/Configure diff --git a/Configure b/Configure index d8d2bcc..869ed19 100755 --- a/Configure +++ b/Configure @@ -25,7 +25,7 @@ # $Id: Head.U 6 2006-08-25 22:21:46Z rmanfredi $ # -# Generated on Tue May 27 17:17:47 CEST 2008 [metaconfig 3.5 PL0] +# Generated on Thu Jul 10 17:14:53 CEST 2008 [metaconfig 3.5 PL0] # (with additional metaconfig patches by perlbug@perl.org) cat >c1$$ </dev/null 2>&1`; then echo "#!$xcat" >sharp $eunicefix sharp chmod +x sharp - ./sharp > today + ./sharp > today 2>/dev/null if test -s today; then sharpbang='#!' else echo "#! $xcat" > sharp $eunicefix sharp chmod +x sharp - ./sharp > today + ./sharp > today 2>/dev/null if test -s today; then sharpbang='#! ' else @@ -1939,7 +1942,7 @@ rm -f .echotmp echo " " if test -f "$rsrc/MANIFEST"; then echo "First let's make sure your kit is complete. Checking..." >&4 - awk '$1 !~ /PACK[A-Z]+/ {print $1}' "$rsrc/MANIFEST" |\ + awk '$1 !~ /PACK[A-Z]+/ {print $1}' "$rsrc/MANIFEST" | \ (split -l 50 2>/dev/null || split -50) rm -f missing tmppwd=`pwd` @@ -7444,9 +7447,10 @@ case "$nm_so_opt" in ;; esac -: get list of predefined functions in a handy place +: Figure out where the libc is located case "$runnm" in true) +: get list of predefined functions in a handy place echo " " case "$libc" in '') libc=unknown @@ -7673,31 +7677,31 @@ else echo " " echo "$nm didn't seem to work right. Trying $ar instead..." >&4 com='' - if $ar t $libc > libc.tmp && $contains '^fprintf$' libc.tmp >/dev/null 2>&1; then + if $ar t $libc > libc.tmp && \ + $contains '^fprintf$' libc.tmp >/dev/null 2>&1 + then for thisname in $libnames $libc; do $ar t $thisname >>libc.tmp done $sed -e "s/\\$_o\$//" < libc.tmp > libc.list echo "Ok." >&4 elif test "X$osname" = "Xos2" && $ar tv $libc > libc.tmp; then - # Repeat libc to extract forwarders to DLL entries too for thisname in $libnames $libc; do $ar tv $thisname >>libc.tmp - # Revision 50 of EMX has bug in $ar. - # it will not extract forwarders to DLL entries - # Use emximp which will extract exactly them. emximp -o tmp.imp $thisname \ 2>/dev/null && \ $sed -e 's/^\([_a-zA-Z0-9]*\) .*$/\1/p' \ < tmp.imp >>libc.tmp - $rm tmp.imp + $rm -f tmp.imp done $sed -e "s/\\$_o\$//" -e 's/^ \+//' < libc.tmp > libc.list echo "Ok." >&4 else echo "$ar didn't seem to work right." >&4 echo "Maybe this is a Cray...trying bld instead..." >&4 - if bld t $libc | $sed -e 's/.*\///' -e "s/\\$_o:.*\$//" > libc.list + if bld t $libc | \ + $sed -e 's/.*\///' -e "s/\\$_o:.*\$//" > libc.list && + $test -s libc.list then for thisname in $libnames; do bld t $libnames | \ @@ -7722,7 +7726,8 @@ define) *) if $test -f /lib/syscalls.exp; then echo " " echo "Also extracting names from /lib/syscalls.exp for good ole AIX..." >&4 - $sed -n 's/^\([^ ]*\)[ ]*syscall[0-9]*[ ]*$/\1/p' /lib/syscalls.exp >>libc.list + $sed -n 's/^\([^ ]*\)[ ]*syscall[0-9]*[ ]*$/\1/p' \ + /lib/syscalls.exp >>libc.list fi ;; esac @@ -17457,7 +17462,6 @@ int main(int argc, char **argv) { EOP set try -d_sprintf_returns_strlen="$undef" if eval $compile; then xxx="`$run ./try`" case "$?" in @@ -17472,6 +17476,9 @@ EOM d_sprintf_returns_strlen="$undef" ;; esac +else + echo "(I can't seem to compile the test program--assuming it doesn't)" >&4 + d_sprintf_returns_strlen="$undef" fi $rm_try @@ -18101,6 +18108,10 @@ if test "X$d_time" = X -o X"$timetype" = X; then eval $setvar fi +: see if timegm exists +set timegm d_timegm +eval $inlibc + : see if this is a sys/times.h system set sys/times.h i_systimes eval $inhdr @@ -19931,9 +19942,6 @@ case "$pager" in esac ;; *) dflt="$pager" - : Instruct ./getfile to trust the hinted or previous pager value, - : even if it does not begin with a slash. For example, on os2, - : pager might be cmd /c more. See comments in UU/getfile. fn="f/($pager)" ;; esac @@ -20002,6 +20010,90 @@ else fi $rm -f foo* bar* +: see if this is a values.h system +set values.h i_values +eval $inhdr + +: Check the max offset that gmtime accepts +echo "Checking max offsets that gmtime () accepts" + +case $i_values in + define) yyy="#include " ;; + *) yyy="" ;; + esac + +$cat >try.c < +#include +#include +$yyy + +int i; +struct tm *tmp; +time_t pt; + +void gm_check (time_t t) +{ + tmp = gmtime (&t); + if (tmp == NULL || tmp->tm_year < -1900) + tmp = NULL; + else + pt = t; + } /* gm_check */ + +int check_max () +{ + tmp = NULL; + pt = 0; +#ifdef MAXLONG + gm_check (MAXLONG); +#endif + if (tmp == NULL || tmp->tm_year < 0) { + for (i = 63; i >= 0; i--) { + time_t x = pt | ((time_t)1 << i); + if (x < 0) continue; + gm_check (x); + } + } + printf ("sGMTIME_max=%ld\n", pt); + return (0); + } + +int check_min () +{ + tmp = NULL; + pt = 0; +#ifdef MINLONG + gm_check (MINLONG); +#endif + if (tmp == NULL) { + for (i = 36; i >= 0; i--) { + time_t x = pt - ((time_t)1 << i); + if (x > 0) continue; + gm_check (x); + } + } + printf ("sGMTIME_min=%ld\n", pt); + return (0); + } + +int main (int argc, char *argv[]) +{ + fprintf (stderr, "Sizeof time_t = %ld\n", sizeof (time_t)); + check_max (); + check_min (); + return (0); + } /* main */ +EOCP +set try +if eval $compile; then + yyy=`$run ./try` + eval $yyy +else + echo "Cannot determine sGMTIME_max and sGMTIME_min." >&4 + fi +$rm_try + : check for type of arguments to select. case "$selecttype" in '') case "$d_select" in @@ -20582,8 +20674,7 @@ $rm_try : see what type of char stdio uses. echo " " -echo '#include ' > stdio.c -$cppstdin $cppminus < stdio.c > stdioh +echo '#include ' | $cppstdin $cppminus > stdioh if $contains 'unsigned.*char.*_ptr;' stdioh >/dev/null 2>&1 ; then echo "Your stdio uses unsigned chars." >&4 stdchar="unsigned char" @@ -20591,7 +20682,7 @@ else echo "Your stdio uses signed chars." >&4 stdchar="char" fi -$rm -f stdio.* stdioh +$rm -f stdioh : see what type uids are declared as in the kernel echo " " @@ -21265,10 +21356,6 @@ eval $inhdr set utime.h i_utime eval $inhdr -: see if this is a values.h system -set values.h i_values -eval $inhdr - : see if this is a vfork system case "$d_vfork" in "$define") @@ -22235,6 +22322,7 @@ d_tcsetpgrp='$d_tcsetpgrp' d_telldir='$d_telldir' d_telldirproto='$d_telldirproto' d_time='$d_time' +d_timegm='$d_timegm' d_times='$d_times' d_tm_tm_gmtoff='$d_tm_tm_gmtoff' d_tm_tm_zone='$d_tm_tm_zone' @@ -22622,6 +22710,8 @@ rm_try='$rm_try' rmail='$rmail' run='$run' runnm='$runnm' +sGMTIME_max='$sGMTIME_max' +sGMTIME_min='$sGMTIME_min' sPRIEUldbl='$sPRIEUldbl' sPRIFUldbl='$sPRIFUldbl' sPRIGUldbl='$sPRIGUldbl'