This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Shorten some file names
[perl5.git] / Configure
index bfbb788..532aed1 100755 (executable)
--- a/Configure
+++ b/Configure
@@ -26,7 +26,7 @@
 
 # $Id: Head.U,v 3.0.1.9 1997/02/28 15:02:09 ram Exp $
 #
-# Generated on Sat Feb 10 17:48:04 CET 2007 [metaconfig 3.0 PL70]
+# Generated on Wed Apr 18 21:01:29 CEST 2007 [metaconfig 3.0 PL70]
 # (with additional metaconfig patches by perlbug@perl.org)
 
 cat >c1$$ <<EOF
@@ -6614,7 +6614,7 @@ EOM
        voidflags="$ans"
        ;;
 esac
-$rm -f try.* .out
+$rm -f try try.* .out
 
 : check for length of pointer
 echo " "
@@ -7568,6 +7568,33 @@ $rm -f libnames libpath
 set dld.h i_dld
 eval $inhdr
 
+
+echo " "
+echo "Checking for C++..." >&4
+cat >try.c <<'EOCP'
+#include <stdio.h>
+int main(void)
+{
+#ifdef __cplusplus
+    printf("define\n");
+#else
+    printf("undef\n");
+#endif
+    return 0;
+}
+EOCP
+set try
+if eval $compile_ok && $run ./try >cplusplus$$; then
+       val=`$cat cplusplus$$`
+       echo "You are using a C++ compiler."
+else
+       val="$undef"
+       echo "You are not using a C++ compiler."
+fi
+$rm -f try try.* cplusplus$$
+set d_cplusplus
+eval $setvar
+
 : is a C symbol defined?
 csym='tlook=$1;
 case "$3" in
@@ -7583,17 +7610,20 @@ esac;
 case "$tx" in
 yes)
        tval=false;
+       case "$d_cplusplus" in
+               $define) extern_C=\"C\";;
+       esac;
        if $test "$runnm" = true; then
                if $contains $tlook $tf >/dev/null 2>&1; then
                        tval=true;
                elif $test "$mistrustnm" = compile -o "$mistrustnm" = run; then
-                       echo "void *(*(p()))$tdc { extern void *$1$tdc; return &$1; } int main() { if(p()) return(0); else return(1); }"> try.c;
+                       echo "extern $extern_C void *$1$tdc; void *(*(p()))$tdc { return &$1; } int main() { if(p()) return(0); else return(1); }"> try.c;
                        $cc -o try $optimize $ccflags $ldflags try.c >/dev/null 2>&1 $libs && tval=true;
                        $test "$mistrustnm" = run -a -x try && { $run ./try$_exe >/dev/null 2>&1 || tval=false; };
                        $rm -f try$_exe try.c core core.* try.core;
                fi;
        else
-               echo "void *(*(p()))$tdc { extern void *$1$tdc; return &$1; } int main() { if(p()) return(0); else return(1); }"> try.c;
+               echo "extern $extern_C void *$1$tdc; void *(*(p()))$tdc { return &$1; } int main() { if(p()) return(0); else return(1); }"> try.c;
                $cc -o try $optimize $ccflags $ldflags try.c $libs >/dev/null 2>&1 && tval=true;
                $rm -f try$_exe try.c;
        fi;
@@ -7634,33 +7664,6 @@ yes)
        esac;;
 esac'
 
-
-echo " "
-echo "Checking for C++..." >&4
-cat >try.c <<'EOCP'
-#include <stdio.h>
-int main(void)
-{
-#ifdef __cplusplus
-    printf("define\n");
-#else
-    printf("undef\n");
-#endif
-    return 0;
-}
-EOCP
-set try
-if eval $compile_ok && $run ./try >cplusplus$$; then
-       val=`$cat cplusplus$$`
-       echo "You are using a C++ compiler."
-else
-       val="$undef"
-       echo "You are not using a C++ compiler."
-fi
-$rm -f try try.* cplusplus$$
-set d_cplusplus
-eval $setvar
-
 : see if dlopen exists
 xxx_runnm="$runnm"
 xxx_ccflags="$ccflags"
@@ -7757,7 +7760,7 @@ EOM
                        ;;
                *)  case "$osname" in
                        darwin) dflt='none' ;;
-                       svr4*|esix*|solaris|nonstopux) dflt='-fPIC' ;;
+                       linux*|svr4*|esix*|solaris|nonstopux) dflt='-fPIC' ;;
                        *)      dflt='-fpic' ;;
                    esac ;;
            esac ;;
@@ -7836,7 +7839,7 @@ EOM
                              '') dflt="$dflt +vnocompatwarnings" ;;
                              esac
                              ;;        
-                       linux|irix*|gnu*)       dflt='-shared' ;;
+                       linux|irix*|gnu*)  dflt="-shared $optimize" ;;
                        next)  dflt='none' ;;
                        solaris) dflt='-G' ;;
                        sunos) dflt='-assert nodefinitions' ;;
@@ -9809,7 +9812,7 @@ else
 fi;
 set $varname;
 eval $setvar;
-$rm -f try.c try.o'
+$rm -f try try.c try.o'
 
 : see if we should include time.h, sys/time.h, or both
 echo " "
@@ -10787,7 +10790,7 @@ case "$castflags" in
 esac
 set d_castneg
 eval $setvar
-$rm -f try.*
+$rm -f try try.*
 
 : see if vprintf exists
 echo " "
@@ -10869,7 +10872,7 @@ else
 fi;
 set $varname;
 eval $setvar;
-$rm -f try.c try.o'
+$rm -f try try.c try.o'
 
 socketlib=''
 sockethdr=''
@@ -11321,7 +11324,7 @@ else
        . ./myread
        direntrytype="$ans"
 fi
-$rm -f try.c
+$rm -f try try.c
 
 
 : see if the directory entry stores field length
@@ -11336,7 +11339,7 @@ else
 fi
 set d_dirnamlen
 eval $setvar
-$rm -f try.c
+$rm -f try try.c
 
 : Look for DIR.dd_fd
 case "$i_dirent" in
@@ -12965,11 +12968,11 @@ if eval $compile; then
        0)  echo "Yes, it does" >&4
            d_futimes="$define"
            ;;
-       *)  echo "No, it has futimes, but it isn't working ($rc) (probably harmless)\n" >&4
+       *)  echo "No, it has futimes, but it isn't working ($rc) (probably harmless)" >&4
            ;;
     esac
 else
-    echo "No, it does not (probably harmless)\n" >&4
+    echo "No, it does not (probably harmless)" >&4
 fi
 $rm -f try.* try core core.try.*
 
@@ -14691,7 +14694,7 @@ int main()
 EOCP
        set try
        if eval $compile; then
-           if ./try; then
+           if $run ./try; then
                d_localtime_r_needs_tzset=undef;
            else
                d_localtime_r_needs_tzset=define;
@@ -15083,7 +15086,7 @@ else
 fi
 set d_volatile
 eval $setvar
-$rm -f try.*
+$rm -f try try.*
 
 
 echo " "
@@ -15973,7 +15976,7 @@ exit(0);
 EOCP
                set try
                if eval $compile_ok; then
-                       if ./try 2>/dev/null; then
+                       if $run ./try 2>/dev/null; then
                                echo "Yes, it can."
                                val="$define"
                        else
@@ -16049,7 +16052,7 @@ exit(0);
 EOCP
                set try
                if eval $compile_ok; then
-                       if ./try 2>/dev/null; then
+                       if $run ./try 2>/dev/null; then
                                echo "Yes, it can."
                                val="$define"
                        else
@@ -17407,7 +17410,7 @@ else
 fi
 set d_strctcpy
 eval $setvar
-$rm -f try.*
+$rm -f try try.*
 
 : see if strerror and/or sys_errlist[] exist
 echo " "
@@ -17657,6 +17660,9 @@ EOM
                   d_strtoul="$undef"
                   ;;
                esac
+       else
+               echo "(I can't seem to compile the test program--assuming it doesn't)"
+               d_strtoul="$undef"
        fi
        ;;
 esac
@@ -17711,6 +17717,9 @@ EOM
                   d_strtoull="$undef"
                   ;;
                esac
+       else
+               echo "(I can't seem to compile the test program--assuming it doesn't)"
+               d_strtoull="$undef"
        fi
        ;;
 esac
@@ -17763,6 +17772,9 @@ EOM
                   d_strtouq="$undef"
                   ;;
                esac
+       else
+               echo "(I can't seem to compile the test program--assuming it doesn't)"
+               d_strtouq="$undef"
        fi
        ;;
 esac
@@ -18009,7 +18021,7 @@ int main()
 EOCP
                xxx_prompt=y
                set try
-               if eval $compile && ./try > /dev/null; then
+               if eval $compile && $run ./try > /dev/null; then
                        dflt=`$run ./try`
                        case "$dflt" in
                        [1-4][1-4][1-4][1-4]|12345678|87654321)
@@ -18440,7 +18452,7 @@ EOCP
                        ;;
                esac
        fi
-       $rm -f try.*
+       $rm -f try try.*
        ;;
 esac
 
@@ -18483,7 +18495,7 @@ EOCP
                echo "Help:  I can't seem to compile the db test program." >&4
                echo "Something's wrong, but I'll assume you use $db_hashtype." >&4
        fi
-       $rm -f try.*
+       $rm -f try try.*
        echo "Your version of Berkeley DB uses $db_hashtype for hash."
        ;;
 *)     db_hashtype=u_int32_t
@@ -18528,7 +18540,7 @@ EOCP
                echo "Help:  I can't seem to compile the db test program." >&4
                echo "Something's wrong, but I'll assume you use $db_prefixtype." >&4
        fi
-       $rm -f try.*
+       $rm -f try try.*
        echo "Your version of Berkeley DB uses $db_prefixtype for prefix."
        ;;
 *)     db_prefixtype='size_t'