diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2003-09-01 14:14:49 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2003-09-01 14:14:49 +0000 |
commit | 0e9de459b923410f2c7af3887364c6d4cd0df24e (patch) | |
tree | ce3a153916706b7f57a1fd3c8526aeb938c5ff4b /pod | |
parent | dd993642b6a1d34014597cd0beb8e3655151a9e7 (diff) | |
download | perl-0e9de459b923410f2c7af3887364c6d4cd0df24e.tar.gz |
From Craig Berry, following the example of the other podxxx.PL
in relying on basename($0, '.PL') to Do The Right Thing with
regard to the case of the extension, which could be either
.pl or .PL on VMS depending on version-specific features.
p4raw-id: //depot/perl@20983
Diffstat (limited to 'pod')
-rw-r--r-- | pod/pod2usage.PL | 5 | ||||
-rw-r--r-- | pod/podselect.PL | 5 |
2 files changed, 4 insertions, 6 deletions
diff --git a/pod/pod2usage.PL b/pod/pod2usage.PL index 1c1296a19f..6df506234d 100644 --- a/pod/pod2usage.PL +++ b/pod/pod2usage.PL @@ -15,9 +15,8 @@ use Cwd; # This is so that make depend always knows where to find PL derivatives. $origdir = cwd; chdir(dirname($0)); -($file = basename($0)) =~ s/\.PL$//; -$file =~ s/\.pl$// if ($^O eq 'os2' or $^O eq 'dos'); # "case-forgiving" -$file =~ s/\.pl$/.com/ if ($^O eq 'VMS'); # "case-forgiving" +$file = basename($0, '.PL'); +$file .= '.com' if $^O eq 'VMS'; open OUT,">$file" or die "Can't create $file: $!"; diff --git a/pod/podselect.PL b/pod/podselect.PL index b6b8c9b9e4..d3e204effc 100644 --- a/pod/podselect.PL +++ b/pod/podselect.PL @@ -15,9 +15,8 @@ use Cwd; # This is so that make depend always knows where to find PL derivatives. $origdir = cwd; chdir(dirname($0)); -($file = basename($0)) =~ s/\.PL$//; -$file =~ s/\.pl$// if ($^O eq 'os2' or $^O eq 'dos'); # "case-forgiving" -$file =~ s/\.pl$/.com/ if ($^O eq 'VMS'); # "case-forgiving" +$file = basename($0, '.PL'); +$file .= '.com' if $^O eq 'VMS'; open OUT,">$file" or die "Can't create $file: $!"; |