summaryrefslogtreecommitdiff
path: root/Configure
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>1999-07-25 10:12:07 +0000
committerJarkko Hietaniemi <jhi@iki.fi>1999-07-25 10:12:07 +0000
commitdd4e71fdc0d3da1d09384ab498212866e7d17b94 (patch)
tree4032fb678c222f4794b17f681b6b97981ee271aa /Configure
parentd6baa26853688ee48d9dcc6e69f5688f433cefe8 (diff)
downloadperl-dd4e71fdc0d3da1d09384ab498212866e7d17b94.tar.gz
Circumcode a strange shell(?) bug in AIX found
while trying to do -Duse64bits (which I couldn't do in the end because the CPU isn't 64-bit in that box, but at least now the probing doesn't crash.) p4raw-id: //depot/cfgperl@3731
Diffstat (limited to 'Configure')
-rwxr-xr-xConfigure399
1 files changed, 187 insertions, 212 deletions
diff --git a/Configure b/Configure
index 04f7db3393..a7e7d62ea1 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 Fri Jul 23 13:08:17 EET DST 1999 [metaconfig 3.0 PL70]
+# Generated on Sun Jul 25 13:04:13 EET DST 1999 [metaconfig 3.0 PL70]
# (with additional metaconfig patches by perlbug@perl.com)
cat >/tmp/c1$$ <<EOF
@@ -670,6 +670,9 @@ i_stdarg=''
i_varargs=''
i_varhdr=''
i_vfork=''
+installprefix=''
+installprefixexp=''
+installstyle=''
installusrbinperl=''
intsize=''
longsize=''
@@ -787,6 +790,8 @@ sitearchexp=''
installsitelib=''
sitelib=''
sitelibexp=''
+siteprefix=''
+siteprefixexp=''
sizetype=''
so=''
sharpbang=''
@@ -2625,7 +2630,7 @@ esac
case "$use64bits" in
"$define"|true|[yY]*)
: Look for a hint-file generated 'call-back-unit'. If the
-: user has specified that a threading perl is to be built,
+: 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 use64bits.cbu; then
. ./use64bits.cbu
@@ -2719,24 +2724,6 @@ $define)
esac
esac
-: is AFS running?
-echo " "
-case "$afs" in
-$define|true) afs=true ;;
-$undef|false) afs=false ;;
-*) if test -d /afs; then
- afs=true
- else
- afs=false
- fi
- ;;
-esac
-if $afs; then
- echo "AFS may be running... I'll be extra cautious then..." >&4
-else
- echo "AFS does not seem to be running..." >&4
-fi
-
: decide how portable to be. Allow command line overrides.
case "$d_portable" in
"$undef") ;;
@@ -3001,14 +2988,13 @@ case "$prefix" in
esac
$cat <<EOM
-By default, $package will be installed in $dflt/bin, manual
-pages under $dflt/man, etc..., i.e. with $dflt as prefix for
-all installation directories. Typically set to /usr/local, but you
-may choose /usr if you wish to install $package among your system
-binaries. If you wish to have binaries under /bin but manual pages
-under /usr/local/man, that's ok: you will be prompted separately
-for each of the installation directories, the prefix being only used
-to set the defaults.
+By default, $package will be installed in $dflt/bin, manual pages
+under $dflt/man, etc..., i.e. with $dflt as prefix for all
+installation directories. Typically this is something like /usr/local.
+If you wish to have binaries under /usr/bin but other parts of the
+installation under /usr/local, that's ok: you will be prompted
+separately for each of the installation directories, the prefix being
+only used to set the defaults.
EOM
fn=d~
@@ -3027,6 +3013,57 @@ esac
prefix="$ans"
prefixexp="$ansexp"
+: is AFS running?
+echo " "
+case "$afs" in
+$define|true) afs=true ;;
+$undef|false) afs=false ;;
+*) if test -d /afs; then
+ afs=true
+ else
+ afs=false
+ fi
+ ;;
+esac
+if $afs; then
+ echo "AFS may be running... I'll be extra cautious then..." >&4
+else
+ echo "AFS does not seem to be running..." >&4
+fi
+
+: determine installation prefix for where package is to be installed.
+if $afs; then
+$cat <<EOM
+
+Since you are running AFS, I need to distinguish the directory in which
+files will reside from the directory in which they are installed (and from
+which they are presumably copied to the former directory by occult means).
+
+EOM
+ case "$installprefix" in
+ '') dflt=`echo $prefix | sed 's#^/afs/#/afs/.#'`;;
+ *) dflt="$installprefix";;
+ esac
+else
+$cat <<EOM
+
+In some special cases, particularly when building $package for distribution,
+it is convenient to distinguish between the directory in which files should
+be installed from the directory ($prefix) in which they
+will eventually reside. For most users, these two directories are the same.
+
+EOM
+ case "$installprefix" in
+ '') dflt=$prefix ;;
+ *) dflt=$installprefix;;
+ esac
+fi
+fn=d~
+rp='What installation prefix should I use for installing files?'
+. ./getfile
+installprefix="$ans"
+installprefixexp="$ansexp"
+
: set the prefixit variable, to compute a suitable default value
prefixit='case "$3" in
""|none)
@@ -3094,13 +3131,30 @@ else
apiversion="$version"
fi
+: determine installation style
+: For now, try to deduce it from prefix unless it is already set.
+: Reproduce behavior of 5.005 and earlier, maybe drop that in 5.7.
+case "$installstyle" in
+'') case "$prefix" in
+ *perl*) dflt='lib';;
+ *) dflt='lib/perl5' ;;
+ esac
+ ;;
+*) dflt='lib/perl5' ;;
+esac
+: Probably not worth prompting for this since we prompt for all
+: the directories individually, and the prompt would be too long and
+: confusing anyway.
+installstyle=$dflt
+
: determine where private library files go
: Usual default is /usr/local/lib/perl5/$version.
: Also allow things like /opt/perl/lib/$version, since
: /opt/perl/lib/perl5... would be redundant.
-case "$prefix" in
-*perl*) set dflt privlib lib/$version ;;
-*) set dflt privlib lib/$package/$version ;;
+: The default "style" setting is made in installstyle.U
+case "$installstyle" in
+*lib/perl5*) set dflt privlib lib/$package/$version ;;
+*) set dflt privlib lib/$version ;;
esac
eval $prefixit
$cat <<EOM
@@ -3112,29 +3166,11 @@ EOM
fn=d~+
rp='Pathname where the private library files will reside?'
. ./getfile
-if $test "X$privlibexp" != "X$ansexp"; then
- installprivlib=''
-fi
privlib="$ans"
privlibexp="$ansexp"
-if $afs; then
- $cat <<EOM
-
-Since you are running AFS, I need to distinguish the directory in which
-private files reside from the directory in which they are installed (and from
-which they are presumably copied to the former directory by occult means).
-
-EOM
- case "$installprivlib" in
- '') dflt=`echo $privlibexp | sed 's#^/afs/#/afs/.#'`;;
- *) dflt="$installprivlib";;
- esac
- fn=de~
- rp='Where will private files be installed?'
- . ./getfile
- installprivlib="$ans"
-else
- installprivlib="$privlibexp"
+: Change installation prefix, if necessary.
+if $test X"$prefix" != X"$installprefix"; then
+ installprivlib=`echo $privlibexp | sed 's#^$prefix#$installprefix#'`
fi
: set the prefixup variable, to restore leading tilda escape
@@ -3157,7 +3193,7 @@ case "$archlib" in
*) dflt="$archlib"
;;
esac
-cat <<EOM
+$cat <<EOM
$spackage contains architecture-dependent library files. If you are
sharing libraries in a heterogeneous environment, you might store
@@ -3170,32 +3206,15 @@ rp='Where do you want to put the public architecture-dependent libraries?'
. ./getfile
archlib="$ans"
archlibexp="$ansexp"
-
-if $afs; then
- $cat <<EOM
-
-Since you are running AFS, I need to distinguish the directory in
-which architecture-dependent library files reside from the directory
-in which they are installed (and from which they are presumably copied
-to the former directory by occult means).
-
-EOM
- case "$installarchlib" in
- '') dflt=`echo $archlibexp | sed 's#^/afs/#/afs/.#'`;;
- *) dflt="$installarchlib";;
- esac
- fn=de~
- rp='Where will architecture-dependent library files be installed?'
- . ./getfile
- installarchlib="$ans"
-else
- installarchlib="$archlibexp"
-fi
if $test X"$archlib" = X"$privlib"; then
d_archlib="$undef"
else
d_archlib="$define"
fi
+: Change installation prefix, if necessary.
+if $test X"$prefix" != X"$installprefix"; then
+ installarchlib=`echo $archlibexp | sed 's#^$prefix#$installprefix#'`
+fi
: make some quick guesses about what we are up against
echo " "
@@ -4584,30 +4603,16 @@ if $test "X$ansexp" != "X$binexp"; then
fi
bin="$ans"
binexp="$ansexp"
-if $afs; then
- $cat <<EOM
-
-Since you are running AFS, I need to distinguish the directory in which
-executables reside from the directory in which they are installed (and from
-which they are presumably copied to the former directory by occult means).
-
-EOM
- case "$installbin" in
- '') dflt=`echo $binexp | sed 's#^/afs/#/afs/.#'`;;
- *) dflt="$installbin";;
- esac
- fn=de~
- rp='Where will public executables be installed?'
- . ./getfile
- installbin="$ans"
-else
- installbin="$binexp"
+: Change installation prefix, if necessary.
+: XXX Bug? -- ignores Configure -Dinstallprefix setting.
+if $test X"$prefix" != X"$installprefix"; then
+ installbin=`echo binexp | sed 's#^$prefix#$installprefix#'`
fi
: determine whether to install perl also as /usr/bin/perl
echo " "
-if test -d /usr/bin -a "X$installbin" != X/usr/bin; then
+if $test -d /usr/bin -a "X$installbin" != X/usr/bin; then
$cat <<EOM
Many scripts expect to perl to be installed as /usr/bin/perl.
I can install the perl you are about to compile also as /usr/bin/perl
@@ -5576,27 +5581,13 @@ fi
man1dir="$ans"
man1direxp="$ansexp"
case "$man1dir" in
-'') man1dir=' '
+'') man1dir=' '
installman1dir='';;
esac
-if $afs; then
- $cat <<EOM
-Since you are running AFS, I need to distinguish the directory in which
-manual pages reside from the directory in which they are installed (and from
-which they are presumably copied to the former directory by occult means).
-
-EOM
- case "$installman1dir" in
- '') dflt=`echo $man1direxp | sed 's#^/afs/#/afs/.#'`;;
- *) dflt="$installman1dir";;
- esac
- fn=de~
- rp='Where will man pages be installed?'
- . ./getfile
- installman1dir="$ans"
-else
- installman1dir="$man1direxp"
+: Change installation prefix, if necessary.
+if $test X"$prefix" != X"$installprefix"; then
+ installman1dir=`echo $man1direxp | $sed 's#^$prefix#$installprefix#'`
fi
: What suffix to use on installed man pages
@@ -5703,52 +5694,44 @@ esac
echo "If you don't want the manual sources installed, answer 'none'."
prog=`echo $package | $sed 's/-*[0-9.]*$//'`
case "$man3dir" in
-'') case "$prefix" in
- *$prog*) dflt=`echo $man1dir |
- $sed -e 's/man1/man3/g' -e 's/man\.1/man\.3/g'` ;;
- *) dflt="$privlib/man/man3" ;;
- esac
+'') dflt=`echo $man1dir | $sed -e 's/man1/man3/g' -e 's/man\.1/man\.3/g'`
+ if $test -d "$privlib/man/man3"; then
+ cat <<EOM >&4
+
+WARNING: Previous versions of perl installed man3 pages into
+$privlib/man/man3. This version will suggest a
+new default of $dflt.
+EOM
+ tdflt=$dflt
+ dflt='n'
+ rp='Do you wish to preserve the old behavior?(y/n)'
+ . ./myread
+ case "$ans" in
+ y*) dflt="$privlib/man/man3" ;;
+ *) dflt=$tdflt ;;
+ esac
+ fi
;;
' ') dflt=none;;
*) dflt="$man3dir" ;;
esac
echo " "
-
fn=dn+~
rp="Where do the $package library man pages (source) go?"
. ./getfile
-if test "X$man3direxp" != "X$ansexp"; then
- installman3dir=''
-fi
-
man3dir="$ans"
man3direxp="$ansexp"
-case "$man3dir" in
-'') man3dir=' '
+case "$man1dir" in
+'') man3dir=' '
installman3dir='';;
esac
-if $afs; then
- $cat <<EOM
-Since you are running AFS, I need to distinguish the directory in which
-manual pages reside from the directory in which they are installed (and from
-which they are presumably copied to the former directory by occult means).
-
-EOM
- case "$installman3dir" in
- '') dflt=`echo $man3direxp | sed 's#^/afs/#/afs/.#'`;;
- *) dflt="$installman3dir";;
- esac
- fn=de~
- rp='Where will man pages be installed?'
- . ./getfile
- installman3dir="$ans"
-else
- installman3dir="$man3direxp"
+: Change installation prefix, if necessary.
+if $test X"$prefix" != X"$installprefix"; then
+ installman3dir=`echo $man3direxp | $sed 's#^$prefix#$installprefix#'`
fi
: What suffix to use on installed man pages
-
case "$man3dir" in
' ')
man3ext='0'
@@ -6147,9 +6130,10 @@ case "$scriptdir" in
dflt="$bin"
: guess some guesses
$test -d /usr/share/scripts && dflt=/usr/share/scripts
- $test -d /usr/share/bin && dflt=/usr/share/bin
- $test -d /usr/local/script && dflt=/usr/local/script
- $test -d $prefixexp/script && dflt=$prefixexp/script
+ $test -d /usr/share/bin && dflt=/usr/share/bin
+ $test -d /usr/local/script && dflt=/usr/local/script
+ $test -d /usr/local/scripts && dflt=/usr/local/scripts
+ $test -d $prefixexp/script && dflt=$prefixexp/script
set dflt
eval $prefixup
;;
@@ -6172,38 +6156,62 @@ if $test "X$ansexp" != "X$scriptdirexp"; then
fi
scriptdir="$ans"
scriptdirexp="$ansexp"
-if $afs; then
- $cat <<EOM
+: Change installation prefix, if necessary.
+if $test X"$prefix" != X"$installprefix"; then
+ installscript=`echo $scriptdirexp | sed 's#^$prefix#$installprefix#'`
+else
+ installscript="$scriptdirexp"
+fi
-Since you are running AFS, I need to distinguish the directory in which
-scripts reside from the directory in which they are installed (and from
-which they are presumably copied to the former directory by occult means).
+$cat <<EOM
+
+After $package is installed, you may wish to install various
+add-on modules and utilities. Typically, these add-ons will
+be installed under $prefix with the rest
+of this package. However, you may wish to install such add-ons
+elsewhere under a different prefix.
+
+If you do not wish to put everything under a single prefix, that's
+ok. You will be prompted for the individual locations; this siteprefix
+is only used to suggest the defaults.
+
+The default should be fine for most people.
EOM
- case "$installscript" in
- '') dflt=`echo $scriptdirexp | sed 's#^/afs/#/afs/.#'`;;
- *) dflt="$installscript";;
+fn=d~+
+rp='Installation prefix to use for add-on modules and utilities?'
+: XXX Here might be another good place for an installstyle setting.
+case "$siteprefix" in
+'') dflt=$prefix ;;
+*) dflt=$siteprefix ;;
+esac
+. ./getfile
+oldsiteprefix=''
+case "$siteprefix" in
+'') ;;
+*)
+ case "$ans" in
+ "$prefix") ;;
+ *) oldsiteprefix="$prefix";;
esac
- fn=de~
- rp='Where will public scripts be installed?'
- . ./getfile
- installscript="$ans"
-else
- installscript="$scriptdirexp"
-fi
+ ;;
+esac
+siteprefix="$ans"
+siteprefixexp="$ansexp"
: determine where site specific libraries go.
-: Usual default is /usr/local/lib/perl5/site_perl/$apiversion
+: Usual default is /usr/local/lib/perl5/site_perl
+: The default "style" setting is made in installstyle.U
+: XXX No longer works with Prefixit stuff.
prog=`echo $package | $sed 's/-*[0-9.]*$//'`
-case "$prefix" in
-*perl*) set dflt sitelib lib/site_$prog/$apiversion ;;
-*) set dflt sitelib lib/$package/site_$prog/$apiversion ;;
+case "$installstyle" in
+*lib/perl5*) dflt=$siteprefix/lib/site_$prog/ ;;
+*) dflt=$siteprefix/lib/site_$prog ;;
esac
-eval $prefixit
$cat <<EOM
-The installation process will also create a directory for
-site-specific extensions and modules. Some users find it convenient
+The installation process will create a directory for
+site-specific extensions and modules. Most users find it convenient
to place all site-specific files in this directory rather than in the
main distribution directory.
@@ -6211,38 +6219,19 @@ EOM
fn=d~+
rp='Pathname for the site-specific library files?'
. ./getfile
-if $test "X$sitelibexp" != "X$ansexp"; then
- installsitelib=''
-fi
sitelib="$ans"
sitelibexp="$ansexp"
-if $afs; then
- $cat <<EOM
-
-Since you are running AFS, I need to distinguish the directory in
-which site-specific files reside from the directory in which they are
-installed (and from which they are presumably copied to the former
-directory by occult means).
-
-EOM
- case "$installsitelib" in
- '') dflt=`echo $sitelibexp | sed 's#^/afs/#/afs/.#'`;;
- *) dflt="$installsitelib";;
- esac
- fn=de~
- rp='Where will site-specific files be installed?'
- . ./getfile
- installsitelib="$ans"
-else
- installsitelib="$sitelibexp"
+: Change installation prefix, if necessary.
+if $test X"$prefix" != X"$installprefix"; then
+ installsitelib=`echo $sitelibexp | sed 's#^$prefix#$installprefix#'`
fi
: determine where site specific architecture-dependent libraries go.
-: sitelib default is /usr/local/lib/perl5/site_perl/$apiversion
+: sitelib default is /usr/local/lib/perl5/site_perl/
: sitearch default is /usr/local/lib/perl5/site_perl/$apiversion/$archname
: sitelib may have an optional trailing /share.
tdflt=`echo $sitelib | $sed 's,/share$,,'`
-tdflt="$tdflt/$archname"
+tdflt="$tdflt/$apiversion/$archname"
set sitearch sitearch none
eval $prefixit
case "$sitearch" in
@@ -6258,30 +6247,11 @@ EOM
fn=nd~+
rp='Pathname for the site-specific architecture-dependent library files?'
. ./getfile
-if $test "X$sitearchexp" != "X$ansexp"; then
- installsitearch=''
-fi
sitearch="$ans"
sitearchexp="$ansexp"
-if $afs; then
- $cat <<EOM
-
-Since you are running AFS, I need to distinguish the directory in
-which site-specific architecture-dependent library files reside from
-the directory in which they are installed (and from which they are
-presumably copied to the former directory by occult means).
-
-EOM
- case "$installsitearch" in
- '') dflt=`echo $sitearchexp | sed 's#^/afs/#/afs/.#'`;;
- *) dflt="$installsitearch";;
- esac
- fn=de~
- rp='Where will site-specific architecture-dependent files be installed?'
- . ./getfile
- installsitearch="$ans"
-else
- installsitearch="$sitearchexp"
+: Change installation prefix, if necessary.
+if $test X"$prefix" != X"$installprefix"; then
+ installsitearch=`echo $sitearchexp | sed 's#^$prefix#$installprefix#'`
fi
cat <<EOM
@@ -13420,10 +13390,13 @@ installarchlib='$installarchlib'
installbin='$installbin'
installman1dir='$installman1dir'
installman3dir='$installman3dir'
+installprefix='$installprefix'
+installprefixexp='$installprefixexp'
installprivlib='$installprivlib'
installscript='$installscript'
installsitearch='$installsitearch'
installsitelib='$installsitelib'
+installstyle='$installstyle'
installusrbinperl='$installusrbinperl'
intsize='$intsize'
known_extensions='$known_extensions'
@@ -13552,6 +13525,8 @@ sitearch='$sitearch'
sitearchexp='$sitearchexp'
sitelib='$sitelib'
sitelibexp='$sitelibexp'
+siteprefix='$siteprefix'
+siteprefixexp='$siteprefixexp'
sizetype='$sizetype'
sleep='$sleep'
smail='$smail'