summaryrefslogtreecommitdiff
path: root/lib/ExtUtils/MM_VMS.pm
diff options
context:
space:
mode:
authorMichael G. Schwern <schwern@pobox.com>2002-04-29 20:24:59 -0400
committerJarkko Hietaniemi <jhi@iki.fi>2002-04-30 12:38:50 +0000
commitf582e4890c8c9d8f1af27c006641dda54d419af6 (patch)
treec041f3d30d213c8d55b6e8e69abd8615b0f0555c /lib/ExtUtils/MM_VMS.pm
parentedc2eac33c792d54399e570820645265bcb07080 (diff)
downloadperl-f582e4890c8c9d8f1af27c006641dda54d419af6.tar.gz
MakeMaker 5.91_02 -> 5.92_01
Message-ID: <20020430042459.GJ756@blackrider> p4raw-id: //depot/perl@16278
Diffstat (limited to 'lib/ExtUtils/MM_VMS.pm')
-rw-r--r--lib/ExtUtils/MM_VMS.pm53
1 files changed, 31 insertions, 22 deletions
diff --git a/lib/ExtUtils/MM_VMS.pm b/lib/ExtUtils/MM_VMS.pm
index d3c9ede1a6..044bd2e2e2 100644
--- a/lib/ExtUtils/MM_VMS.pm
+++ b/lib/ExtUtils/MM_VMS.pm
@@ -14,7 +14,7 @@ use VMS::Filespec;
use File::Basename;
use File::Spec;
use vars qw($Revision @ISA $VERSION);
-($VERSION) = $Revision = '5.63_01';
+($VERSION) = $Revision = '5.64_01';
require ExtUtils::MM_Any;
require ExtUtils::MM_Unix;
@@ -734,11 +734,10 @@ command line to find args.
sub pm_to_blib {
my($self) = @_;
- my($line,$from,$to,@m);
my($autodir) = File::Spec->catdir($self->{INST_LIB},'auto');
- my(@files) = @{$self->{PM_TO_BLIB}};
+ my(%files) = @{$self->{PM_TO_BLIB}};
- push @m, q{
+ my $m = <<'MAKE_FRAG';
# Dummy target to match Unix target name; we use pm_to_blib.ts as
# timestamp file to avoid repeated invocations under VMS
@@ -747,28 +746,38 @@ pm_to_blib : pm_to_blib.ts
# As always, keep under DCL's 255-char limit
pm_to_blib.ts : $(TO_INST_PM)
-};
-
- if (scalar(@files) > 0) { # protect ourselves from empty PM_TO_BLIB
-
- push(@m,qq[\t\$(NOECHO) \$(RM_F) .MM_tmp\n]);
- $line = ''; # avoid uninitialized var warning
- while ($from = shift(@files),$to = shift(@files)) {
- $line .= " $from $to";
- if (length($line) > 128) {
- push(@m,"\t\$(NOECHO) \$(PERL) -e \"print '$line'\" >>.MM_tmp\n");
- $line = '';
- }
- }
- push(@m,"\t\$(NOECHO) \$(PERL) -e \"print '$line'\" >>.MM_tmp\n") if $line;
+MAKE_FRAG
+
+ if( keys %files ) {
+ $m .= <<'MAKE_FRAG';
+ $(NOECHO) $(RM_F) .MM_tmp
+MAKE_FRAG
+
+ my $line = '';
+ while (my($from, $to) = each %files) {
+ $line .= " $from $to";
+ if (length($line) > 128) {
+ $m .= sprintf <<'MAKE_FRAG', $line;
+ $(NOECHO) $(PERL) -e "print '%s'" >>.MM_tmp
+MAKE_FRAG
+ $line = '';
+ }
+ }
+ $m .= sprintf <<'MAKE_FRAG', $line if $line;
+ $(NOECHO) $(PERL) -e "print '%s'" >>.MM_tmp
+MAKE_FRAG
- push(@m,q[ $(PERLRUN) "-MExtUtils::Install" -e "pm_to_blib({split(' ',<STDIN>)},'].$autodir.q[','$(PM_FILTER)')" <.MM_tmp]);
- push(@m,qq[\n\t\$(NOECHO) \$(RM_F) .MM_tmp\n]);
+ $m .= sprintf <<'MAKE_FRAG', $autodir;
+ $(PERLRUN) "-MExtUtils::Install" -e "pm_to_blib({split(' ',<STDIN>)},'%s','$(PM_FILTER)')" <.MM_tmp
+ $(NOECHO) $(RM_F) .MM_tmp
+MAKE_FRAG
}
- push(@m,qq[\t\$(NOECHO) \$(TOUCH) pm_to_blib.ts]);
+ $m .= <<'MAKE_FRAG';
+ $(NOECHO) $(TOUCH) pm_to_blib.ts
+MAKE_FRAG
- join('',@m);
+ return $m;
}
=item tool_autosplit (override)