From: Craig A. Berry Date: Sun, 31 Dec 2000 11:17:37 +0000 (-0600) Subject: ext/Encode/Makefile.PL line shortening X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=c429baeeab809c5b2796233c46f836ff02370313;p=p5sagit%2Fp5-mst-13.2.git ext/Encode/Makefile.PL line shortening Message-Id: <5.0.2.1.0.20001230195844.025636c0@exchi01> p4raw-id: //depot/perl@8286 --- diff --git a/ext/Encode/Makefile.PL b/ext/Encode/Makefile.PL index 754a326..4b1ec95 100644 --- a/ext/Encode/Makefile.PL +++ b/ext/Encode/Makefile.PL @@ -74,15 +74,35 @@ sub postamble $str .= "\n\n"; foreach my $table (keys %tables) { + my $numlines = 1; + my $lengthsofar = length($str); + my $continuator = ''; $str .= "$table.c : compile Makefile.PL"; foreach my $file (@{$tables{$table}}) { - $str .= ' '.$self->catfile($dir,$file); + $str .= $continuator.' '.$self->catfile($dir,$file); + if ( length($str)-$lengthsofar > 128*$numlines ) + { + $continuator .= " \\\n\t"; + $numlines++; + } else { + $continuator = ''; + } } + $numlines = 1; + $lengthsofar = length($str); + $continuator = ''; $str .= "\n\t\$(PERL) compile \$\@"; foreach my $file (@{$tables{$table}}) { - $str .= ' '.$self->catfile($dir,$file); + $str .= $continuator.' '.$self->catfile($dir,$file); + if ( length($str)-$lengthsofar > 128*$numlines ) + { + $continuator .= "\n\t\$(PERL) compile \$\@"; + $numlines++; + } else { + $continuator = ''; + } } $str .= "\n\n"; }