diff options
author | Chip Salzenberg <chip@pobox.com> | 1999-04-13 04:13:02 +0000 |
---|---|---|
committer | Todd Rinaldo <toddr@cpanel.net> | 2019-10-19 07:03:08 -0500 |
commit | da8e539c8c4a3148fdfeb75f2aa33fd74759e883 (patch) | |
tree | ad000c3c3b3e9706bed8f1e2e57c7df21b483e10 | |
parent | 0b83b2241845cbddb9061b3b25c628584d4abb7b (diff) | |
download | perl-da8e539c8c4a3148fdfeb75f2aa33fd74759e883.tar.gz |
New config variable $installusrbinperl, defaulting 'undef'
for NetBSD. (from Jarkko)
p4raw-id: //depot/maint-5.004/perl@3233
-rwxr-xr-x | Configure | 28 | ||||
-rw-r--r-- | hints/netbsd.sh | 4 | ||||
-rwxr-xr-x | installperl | 3 |
3 files changed, 34 insertions, 1 deletions
@@ -651,6 +651,8 @@ undef='undef' smallmach='pdp11 i8086 z8000 i80286 iAPX286' rmlist='' +installusrbinperl='' + : We must find out about Eunice early eunicefix=':' if test -f /etc/unixtovms; then @@ -2989,6 +2991,31 @@ else installbin="$binexp" fi +echo " " +case "$installusrbinperl" in +'') 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 +(in addition to $installbin/perl). +EOM + dflt='y' + rp="Do you want to install perl as /usr/bin/perl?" + . ./myread + case "$ans" in + [yY]*) val="$define";; + *) val="$undef";; + esac + fi + ;; +esac +case "$installusrbinperl" in +"$undef"|[nN]*) val="$undef";; +*) val="$define";; +esac +set installusrbinperl +eval $setvar + : determine where manual pages are on this system echo " " case "$sysman" in @@ -10562,6 +10589,7 @@ installprivlib='$installprivlib' installscript='$installscript' installsitearch='$installsitearch' installsitelib='$installsitelib' +installusrbinperl='$installusrbinperl' intsize='$intsize' known_extensions='$known_extensions' ksh='$ksh' diff --git a/hints/netbsd.sh b/hints/netbsd.sh index 9239170c26..39a1e9d5bc 100644 --- a/hints/netbsd.sh +++ b/hints/netbsd.sh @@ -62,6 +62,10 @@ d_setruid="$undef" case "$usevfork" in '') usevfork=true ;; esac + +# Pre-empt the /usr/bin/perl question of installperl. +installusrbinperl='undef' + # Avoid telldir prototype conflict in pp_sys.c (NetBSD uses const DIR *) # Configure should test for this. Volunteers? pp_sys_cflags='ccflags="$ccflags -DHAS_TELLDIR_PROTOTYPE"' diff --git a/installperl b/installperl index 009276cf6a..8ecb7c353a 100755 --- a/installperl +++ b/installperl @@ -178,7 +178,8 @@ if (! $versiononly && ! samepath($installbin, '.') && ($^O ne 'dos')) { $mainperl_is_instperl = 0; -if (!$versiononly && !$nonono && $^O ne 'MSWin32' && -t STDIN && -t STDERR +if ($Config{installusrbinperl} eq 'define' && + !$versiononly && !$nonono && $^O ne 'MSWin32' && -t STDIN && -t STDERR && -w $mainperldir && ! samepath($mainperldir, $installbin)) { local($usrbinperl) = "$mainperldir/perl$exe_ext"; local($instperl) = "$installbin/perl$exe_ext"; |