# $Id: Head.U,v 3.0.1.9 1997/02/28 15:02:09 ram Exp $
#
-# Generated on Mon Jan 19 17:27:25 MET 2004 [metaconfig 3.0 PL70]
+# Generated on Mon Jan 31 12:56:14 CET 2005 [metaconfig 3.0 PL70]
# (with additional metaconfig patches by perlbug@perl.org)
cat >c1$$ <<EOF
paths="$paths /usr/5bin /etc /usr/gnu/bin /usr/new /usr/new/bin /usr/nbin"
paths="$paths /opt/gnu/bin /opt/new /opt/new/bin /opt/nbin"
paths="$paths /sys5.3/bin /sys5.3/usr/bin /bsd4.3/bin /bsd4.3/usr/ucb"
-paths="$paths /bsd4.3/usr/bin /usr/bsd /bsd43/bin /usr/ccs/bin"
+paths="$paths /bsd4.3/usr/bin /usr/bsd /bsd43/bin /opt/ansic/bin /usr/ccs/bin"
paths="$paths /etc /usr/lib /usr/ucblib /lib /usr/ccs/lib"
paths="$paths /sbin /usr/sbin /usr/libexec"
paths="$paths /system/gnu_library/bin"
d_strerror_r=''
strerror_r_proto=''
d_strftime=''
+d_strlcat=''
+d_strlcpy=''
d_strtod=''
d_strtol=''
d_strtold=''
mallocobj=''
mallocsrc=''
malloctype=''
+usemallocwrap=''
usemymalloc=''
installman1dir=''
man1dir=''
runnm=''
usenm=''
useperlio=''
+userelocatableinc=''
usesocks=''
d_oldpthreads=''
use5005threads=''
versiononly=''
defvoidused=''
voidflags=''
-pm_apiversion=''
-xs_apiversion=''
yacc=''
yaccflags=''
CONFIG=''
up='[:upper:]'
low='[:lower:]'
;;
-*) # There is a discontinuity in EBCDIC between 'I' and 'J'
- # (0xc9 and 0xd1), therefore that is a nice testing point.
- if test "X$up" = X -o "X$low" = X; then
- case "`echo IJ | $tr '[I-J]' '[i-j]' 2>/dev/null`" in
- ij) up='[A-Z]'
- low='[a-z]'
+*) # There is a discontinuity in EBCDIC between 'R' and 'S'
+ # (0xd9 and 0xe2), therefore that is a nice testing point.
+ if test "X$up" = X -o "X$low" = X; then
+ case "`echo RS | $tr '[R-S]' '[r-s]' 2>/dev/null`" in
+ rs) up='[A-Z]'
+ low='[a-z]'
;;
esac
- fi
+ fi
if test "X$up" = X -o "X$low" = X; then
- case "`echo IJ | $tr I-J i-j 2>/dev/null`" in
- ij) up='A-Z'
+ case "`echo RS | $tr R-S r-s 2>/dev/null`" in
+ rs) up='A-Z'
low='a-z'
;;
esac
- fi
+ fi
if test "X$up" = X -o "X$low" = X; then
- case "`echo IJ | od -x 2>/dev/null`" in
- *C9D1*|*c9d1*)
+ case "`echo RS | od -x 2>/dev/null`" in
+ *D9E2*|*d9e2*)
echo "Hey, this might be EBCDIC." >&4
if test "X$up" = X -o "X$low" = X; then
- case "`echo IJ | $tr '[A-IJ-RS-Z]' '[a-ij-rs-z]' 2>/dev/null`" in
- ij) up='[A-IJ-RS-Z]'
- low='[a-ij-rs-z]'
+ case "`echo RS | $tr '[A-IJ-RS-Z]' '[a-ij-rs-z]' 2>/dev/null`" in
+ rs) up='[A-IJ-RS-Z]'
+ low='[a-ij-rs-z]'
;;
esac
fi
if test "X$up" = X -o "X$low" = X; then
- case "`echo IJ | $tr A-IJ-RS-Z a-ij-rs-z 2>/dev/null`" in
- ij) up='A-IJ-RS-Z'
- low='a-ij-rs-z'
+ case "`echo RS | $tr A-IJ-RS-Z a-ij-rs-z 2>/dev/null`" in
+ rs) up='A-IJ-RS-Z'
+ low='a-ij-rs-z'
;;
esac
fi
esac
fi
esac
-case "`echo IJ | $tr \"$up\" \"$low\" 2>/dev/null`" in
-ij)
+case "`echo RS | $tr \"$up\" \"$low\" 2>/dev/null`" in
+rs)
echo "Using $up and $low to convert case." >&4
;;
*)
aix) osname=aix
tmp=`( (oslevel) 2>/dev/null || echo "not found") 2>&1`
case "$tmp" in
- 'not found') osvers="$4"."$3" ;;
+ # oslevel can fail with:
+ # oslevel: Unable to acquire lock.
+ *not\ found) osvers="$4"."$3" ;;
'<3240'|'<>3240') osvers=3.2.0 ;;
'=3240'|'>3240'|'<3250'|'<>3250') osvers=3.2.4 ;;
'=3250'|'>3250') osvers=3.2.5 ;;
domainos) osname=apollo
osvers="$3"
;;
- dgux) osname=dgux
+ dgux) osname=dgux
osvers="$3"
;;
dynixptx*) osname=dynixptx
;;
freebsd) osname=freebsd
osvers="$3" ;;
- genix) osname=genix ;;
- hp*) osname=hpux
+ genix) osname=genix ;;
+ gnu) osname=gnu
+ osvers="$3" ;;
+ hp*) osname=hpux
osvers=`echo "$3" | $sed 's,.*\.\([0-9]*\.[0-9]*\),\1,'`
;;
- irix*) osname=irix
+ irix*) osname=irix
case "$3" in
4*) osvers=4 ;;
5*) osvers=5 ;;
*) osvers="$3" ;;
esac
;;
- linux) osname=linux
+ linux) osname=linux
case "$3" in
*) osvers="$3" ;;
esac
;;
- MiNT) osname=mint
+ MiNT) osname=mint
;;
netbsd*) osname=netbsd
osvers="$3"
2*) if test -d /etc/conf/kconfig.d &&
$contains _POSIX_VERSION $usrinc/sys/unistd.h >/dev/null 2>&1
then
+ # Interactive Systems (ISC) POSIX mode.
dflt="$dflt -posix"
fi
;;
if $cc -O2 -fno-strict-aliasing -o gcctest gcctest.c; then
echo "Yes, it does." 2>&1
case "$ccflags" in
- *strict-aliasing*)
+ *strict-aliasing*)
echo "Leaving current flags $ccflags alone." 2>&1
;;
*) dflt="$dflt -fno-strict-aliasing" ;;
fi
;;
esac
+ # For gcc, adding -pipe speeds up compilations for some, but apparently
+ # some assemblers can't read from stdin. (It also slows down compilations
+ # in other cases, but those are apparently rarer these days.) AD 5/2004.
+ case "$gccversion" in
+ ?*) echo " "
+ echo "Checking if your compiler accepts -pipe" 2>&1
+ echo 'int main(void) { return 0; }' > gcctest.c
+ if $cc -O2 -pipe -o gcctest gcctest.c; then
+ echo "Yes, it does." 2>&1
+ case "$ccflags" in
+ *-pipe*)
+ echo "Leaving current flags $ccflags alone." 2>&1
+ ;;
+ *) dflt="$dflt -pipe" ;;
+ esac
+ else
+ echo "Nope, it doesn't, but that's ok." 2>&1
+ fi
+ ;;
+ esac
;;
esac
if $test -d $thisincl; then
if $test x$thisincl != x$usrinc; then
case "$dflt" in
- *" -I$thisincl "*);;
- *) dflt="$dflt -I$thisincl ";;
+ *" -I$thisincl "*);;
+ *) dflt="$dflt -I$thisincl ";;
esac
fi
fi
for thislibdir in $libpth; do
case " $loclibpth " in
*" $thislibdir "*)
- case "$dflt " in
+ case "$dflt " in
*"-L$thislibdir "*) ;;
*) dflt="$dflt -L$thislibdir" ;;
esac
: Look for a hint-file generated 'call-back-unit'. If the
: user has specified that a 64-bit perl is to be built,
: we may need to set or change some other defaults.
- if $test -f use64bitint.cbu; then
+if $test -f use64bitint.cbu; then
echo "Your platform has some specific hints regarding 64-bit integers, using them..."
- . ./use64bitint.cbu
- fi
+ . ./use64bitint.cbu
+fi
case "$use64bitint" in
"$define"|true|[yY]*)
case "$longsize" in
: Look for a hint-file generated 'call-back-unit'. If the
: user has specified that a maximally 64-bit perl is to be built,
: we may need to set or change some other defaults.
- if $test -f use64bitall.cbu; then
+if $test -f use64bitall.cbu; then
echo "Your platform has some specific hints regarding 64-bit builds, using them..."
- . ./use64bitall.cbu
- fi
+ . ./use64bitall.cbu
+fi
case "$use64bitall" in
"$define"|true|[yY]*)
case "$longsize" in
cat >&4 <<EOF
*** You have chosen to use 64-bit integers,
-*** but none cannot be found.
+*** but none can be found.
*** Please rerun Configure without -Duse64bitint and/or -Dusemorebits.
*** Cannot continue, aborting.
esac
+: determine whether to use malloc wrapping
+echo " "
+case "$usemallocwrap" in
+[yY]*|true|$define) dflt='y' ;;
+[nN]*|false|$undef) dflt='n' ;;
+*) case "$usedevel" in
+ [yY]*|true|$define) dflt='y' ;;
+ *) dflt='n' ;;
+ esac
+ ;;
+esac
+rp="Do you wish to wrap malloc calls to protect against potential overflows?"
+. ./myread
+usemallocwrap="$ans"
+case "$ans" in
+y*|true)
+ usemallocwrap="$define" ;;
+*)
+ usemallocwrap="$undef" ;;
+esac
+
: determine which malloc to compile in
echo " "
case "$usemymalloc" in
: for archive libraries. Thank you, Linux.
case "$nm_so_opt" in
'') case "$myuname" in
- *linux*)
+ *linux*|gnu*)
if $nm --help | $grep 'dynamic' > /dev/null 2>&1; then
nm_so_opt='--dynamic'
fi
'') dflt="$dflt +vnocompatwarnings" ;;
esac
;;
- linux|irix*) dflt='-shared' ;;
+ linux|irix*|gnu*) dflt='-shared' ;;
next) dflt='none' ;;
solaris) dflt='-G' ;;
sunos) dflt='-assert nodefinitions' ;;
EOM
case "$ccdlflags" in
'') case "$osname" in
- hpux) dflt='-Wl,-E' ;;
- linux) dflt='-rdynamic' ;;
- next) dflt='none' ;;
- sunos) dflt='none' ;;
- *) dflt='none' ;;
+ linux|hpux|gnu*) dflt='-Wl,-E' ;;
+ next|sunos) dflt='none' ;;
+ *) dflt='none' ;;
esac ;;
' ') dflt='none' ;;
*) dflt="$ccdlflags" ;;
dflt=libperl.5.$so
# XXX How handle the --version stuff for MAB?
;;
- linux*) # ld won't link with a bare -lperl otherwise.
+ linux*|gnu*) # ld won't link with a bare -lperl otherwise.
dflt=libperl.$so
;;
cygwin*) # ld links against an importlib
solaris)
xxx="-R $shrpdir"
;;
- freebsd|netbsd|openbsd)
+ freebsd|netbsd|openbsd|interix)
xxx="-Wl,-R$shrpdir"
;;
- bsdos|linux|irix*|dec_osf)
+ bsdos|linux|irix*|dec_osf|gnu*)
xxx="-Wl,-rpath,$shrpdir"
;;
next)
;;
esac
+# probably will refer to
+# $archlib $privlib $sitearch $sitelib $vendorarch $vendorlib
+need_relocation=0
+userelocatableinc=undef
+
case "$vendorprefix" in
'') d_vendorbin="$undef"
vendorbin=''
eval $inlibc
: Look for GNU-cc style attribute checking
+case "$d_attribut" in
+'')
echo " "
echo "Checking whether your compiler can handle __attribute__ ..." >&4
$cat >attrib.c <<'EOCP'
echo "Your C compiler doesn't seem to understand __attribute__ at all."
val="$undef"
fi
+;;
+*) val="$d_attribut" ;;
+esac
set d_attribut
eval $setvar
$rm -f attrib*
i32 = ($xxx) g;
/* x86 processors will probably give 0x8000 0000, which is a
- sign change. We don't want that. We want to mimic SPARC
+ sign change. We don't want that. We want to mimic SPARC
behavior here, which is to preserve the sign and give
back 0x7fff ffff.
*/
set strftime d_strftime
eval $inlibc
+: see if strlcat exists
+set strlcat d_strlcat
+eval $inlibc
+
+: see if strlcpy exists
+set strlcpy d_strlcpy
+eval $inlibc
+
: see if strtod exists
set strtod d_strtod
eval $inlibc
set pid_t pidtype int stdio.h sys/types.h
eval $typedef_ask
-: Find earliest binary compatible site_perl subdirectory perl can use.
-xs_apiversion=$version # The current site_perl version.
-: Find earliest pure perl site_perl subdirectory perl can use.
-: The versioned directories started at 5.005.
-pm_apiversion='5.005'
-
: see if ar generates random libraries by itself
echo " "
echo "Checking how to generate random libraries on your machine..." >&4
d_strerror='$d_strerror'
d_strerror_r='$d_strerror_r'
d_strftime='$d_strftime'
+d_strlcat='$d_strlcat'
+d_strlcpy='$d_strlcpy'
d_strtod='$d_strtod'
d_strtol='$d_strtol'
d_strtold='$d_strtold'
phostname='$phostname'
pidtype='$pidtype'
plibpth='$plibpth'
-pm_apiversion='$pm_apiversion'
pmake='$pmake'
pr='$pr'
prefix='$prefix'
useithreads='$useithreads'
uselargefiles='$uselargefiles'
uselongdouble='$uselongdouble'
+usemallocwrap='$usemallocwrap'
usemorebits='$usemorebits'
usemultiplicity='$usemultiplicity'
usemymalloc='$usemymalloc'
useperlio='$useperlio'
useposix='$useposix'
usereentrant='$usereentrant'
+userelocatableinc='$userelocatableinc'
usesfio='$usesfio'
useshrplib='$useshrplib'
usesocks='$usesocks'
vi='$vi'
voidflags='$voidflags'
xlibpth='$xlibpth'
-xs_apiversion='$xs_apiversion'
yacc='$yacc'
yaccflags='$yaccflags'
zcat='$zcat'