From: Chip Salzenberg Date: Tue, 28 Jan 1997 11:10:48 +0000 (+1200) Subject: Put all extensions' modules in $archlib X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=1dd15ed44b060a6466d83e3d6d09175516a30e5c;p=p5sagit%2Fp5-mst-13.2.git Put all extensions' modules in $archlib --- diff --git a/installperl b/installperl index e6e2bbe..bbcd1c3 100755 --- a/installperl +++ b/installperl @@ -30,6 +30,14 @@ umask 022; @pods = (); +%archpms = (Config => 1, FileHandle => 1, overload => 1); +find(sub { + if ("$File::Find::dir/$_" =~ m{^ext/[^/]+/(.*)\.pm$}) { + (my $pm = $1) =~ s{^lib/}{}; + $archpms{$pm} = 1; + } + }, 'ext'); + $ver = $]; $release = substr($ver,0,3); # Not used presently. $patchlevel = substr($ver,3,2); @@ -349,7 +357,8 @@ sub installlib { $name = "$dir/$name" if $dir ne ''; my $installlib = $installprivlib; - if ($dir =~ /^auto/ || $name =~ /^(Config|FileHandle|Safe)\.pm$/) { + if ($dir =~ /^auto/ || + ($name =~ /^(.*)\.(?:pm|pod)$/ && $archpms{$1})) { $installlib = $installarchlib; return unless $do_installarchlib; } else {