X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=installperl;h=6f4a3691e804f164593c33f71e44faf80c931aba;hb=793019c7a82cb5cc23f2539a00b7092ee19100a5;hp=f7e69b8aeb20f44eaa220b022db9b0175c52f500;hpb=99d21f8bc43125eacfa8aced0256e0e27fb2201d;p=p5sagit%2Fp5-mst-13.2.git diff --git a/installperl b/installperl index f7e69b8..6f4a369 100755 --- a/installperl +++ b/installperl @@ -153,10 +153,20 @@ if ((-e "testcompile") && (defined($ENV{'COMPILE'}))) { push(@scripts, map("$_.exe", @scripts)); } +# Exclude nonxs extensions that are not architecture dependent +my @nonxs = grep(!/^Errno$/, split(' ', $Config{'nonxs_ext'})); + find(sub { - if ("$File::Find::dir/$_" =~ m{^ext\b(.*)/([^/]+)\.pm$}) { + if (($File::Find::name =~ m{^ext\b(.*)/([^/]+)\.pm$}) && + ! grep { (my $dir = $_) =~ s/\//-/g; + $File::Find::name =~ /^ext\/$dir/ } @nonxs) + { my($path, $modname) = ($1,$2); + # Change hypenated name like Filter-Util-Call to nested + # directory name Filter/Util/Call + $path =~ s{-}{/}g; + # strip to optional "/lib", or remove trailing component $path =~ s{.*/lib\b}{} or $path =~ s{/[^/]*$}{}; @@ -212,7 +222,6 @@ if ($nwinstall) { $installsitelib = $Config{installnwlib}; } -my $d_dosuid = $Config{d_dosuid}; my $binexp = $Config{binexp}; if ($Is_VMS) { # Hang in there until File::Spec hits the big time @@ -225,8 +234,6 @@ if ($Is_VMS) { # Hang in there until File::Spec hits the big time # Do some quick sanity checks. -if (!$opts{notify} && $d_dosuid && $>) { die "You must run as root to install suidperl\n"; } - $installbin || die "No installbin directory in config.sh\n"; -d $installbin || mkpath($installbin, $opts{verbose}, 0777); -d $installbin || $opts{notify} || die "$installbin is not a directory\n"; @@ -243,7 +250,6 @@ else { -x $dbg . 'perl' . $exe_ext || die "${dbg}perl$exe_ext isn't executable!\n"; } } --x 'suidperl' . $exe_ext|| die "suidperl isn't executable!\n" if $d_dosuid; -f 't/rantests' || $Is_W32 || warn "WARNING: You've never run 'make test' or", @@ -331,12 +337,6 @@ else { copy("perl.exe", "$installbin/$perl.exe"); } -safe_unlink("$installbin/s$perl_verbase$ver$exe_ext"); -if ($d_dosuid) { - copy("suidperl$exe_ext", "$installbin/s$perl_verbase$ver$exe_ext"); - chmod(04711, "$installbin/s$perl_verbase$ver$exe_ext"); -} - # Install library files. my ($do_installarchlib, $do_installprivlib) = (0, 0); @@ -432,9 +432,6 @@ if (! $versiononly && ! samepath($installbin, '.') && ($^O ne 'dos') && ! $Is_VM link("$installbin/$perl_verbase$ver$exe_ext", "$installbin/$perl$exe_ext"); } - link("$installbin/$perl_verbase$ver$exe_ext", - "$installbin/suid$perl$exe_ext") - if $d_dosuid; } # For development purposes it can be very useful to have multiple perls @@ -612,6 +609,7 @@ if (!$versiononly && $otherperls) { next unless m,^/,; # Use &samepath here because some systems have other dirs linked # to $mainperldir (like SunOS) + next unless -d; next if samepath($_, $binexp); next if samepath($_, cwd()); next if ($mainperl_is_instperl && samepath($_, $mainperldir)); @@ -749,11 +747,13 @@ sub installlib { $name = "$dir/$name" if $dir ne ''; + return if $name eq 'ExtUtils/XSSymSet.pm' and !$Is_VMS; + my $installlib = $installprivlib; - if ($dir =~ /^auto/ || + if ($dir =~ /^auto\// || ($name =~ /^(.*)\.(?:pm|pod)$/ && $archpms{$1}) || ($name =~ /^(.*)\.(?:h|lib)$/i && ($Is_W32 || $Is_NetWare)) || - $name eq 'Config_heavy.pl' + $name=~/^Config_(heavy|git)\.pl\z/ ) { $installlib = $installarchlib; return unless $do_installarchlib;