X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=installperl;h=09ffc806dd53505e429427be0c2f49fd958d780c;hb=be341bcebb03d2f97192fb78a6a1bc33c7bca5ce;hp=f56af9e1dcc4007ca3a200a50d6855af3407f671;hpb=f82fed50423908a8d40f3a83f4f60df8cbc01b22;p=p5sagit%2Fp5-mst-13.2.git diff --git a/installperl b/installperl index f56af9e..09ffc80 100755 --- a/installperl +++ b/installperl @@ -25,6 +25,7 @@ use File::Compare; use File::Copy (); use File::Path (); use ExtUtils::Packlist; +use Config; use subs qw(unlink link chmod); use vars qw($packlist); @@ -74,7 +75,7 @@ my %archpms = ( Config => 1, ); -if ($osname eq 'dos') { +if ($^O eq 'dos') { push(@scripts,'djgpp/fixpmain'); $archpms{config} = $archpms{filehand} = 1; } @@ -199,7 +200,7 @@ if ($Is_VMS) { copy("perlshr$exe_ext", "$installbin/${perl}shr$exe_ext"); chmod(0755, "$installbin/${perl}shr$exe_ext"); } -elsif ($osname eq 'mpeix') { +elsif ($^O eq 'mpeix') { # MPE lacks hard links and requires that executables with special # capabilities reside in the MPE namespace. safe_unlink("$installbin/perl$ver$exe_ext", $Config{perlpath}); @@ -253,17 +254,17 @@ else { mkpath("$installarchlib/CORE", 1, 0777); my @corefiles; if ($Is_VMS) { # We did core file selection during build - my $coredir = "lib/$Config{'arch'}/$ver"; + my $coredir = "lib/$Config{archname}/$ver/CORE"; $coredir =~ tr/./_/; - @corefiles = map { s|^$coredir/||i; } <$coredir/*.*>; + map { s|^$coredir/||i; } @corefiles = <$coredir/*.*>; } else { # [als] hard-coded 'libperl' name... not good! @corefiles = <*.h libperl*.*>; # AIX needs perl.exp installed as well. - push(@corefiles,'perl.exp') if $osname eq 'aix'; - if ($osname eq 'mpeix') { + push(@corefiles,'perl.exp') if $^O eq 'aix'; + if ($^O eq 'mpeix') { # MPE needs mpeixish.h installed as well. mkpath("$installarchlib/CORE/mpeix", 1, 0777); push(@corefiles,'mpeix/mpeixish.h'); @@ -374,9 +375,8 @@ if (! $versiononly) { if (! $versiononly) { safe_unlink("$installscript/pstruct$scr_ext"); - if ($osname eq 'dos' or $Is_VMS or $osname eq 'transit') { + if ($^O eq 'dos' or $Is_VMS or $^O eq 'transit') { copy("$installscript/c2ph$scr_ext", "$installscript/pstruct$scr_ext"); - chmod(0755, "$installscript/pstruct$scr_ext"); } else { link("$installscript/c2ph$scr_ext", "$installscript/pstruct$scr_ext"); }