From: H.Merijn Brand Date: Sun, 27 Oct 2002 17:57:15 +0000 (+0000) Subject: Repair broken previous patch. I don't like it, but not repairing it X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=0ea9712b286c76e597ffb03868653e8d27bd971a;p=p5sagit%2Fp5-mst-13.2.git Repair broken previous patch. I don't like it, but not repairing it breaks each and every build. Will teach me to test on the same machine where I patched it. Sorry. p4raw-id: //depot/perl@18068 --- diff --git a/embed.pl b/embed.pl index 548294a..527b50b 100755 --- a/embed.pl +++ b/embed.pl @@ -32,14 +32,14 @@ Edit those files and run 'make regen_headers' to effect changes. EOW if ($file =~ m:\.[ch]$:) { -$warning =~ s:^: * :gm; -$warning =~ s: +$::gm; -$warning =~ s: :/:; -$warning =~ s:$:/:; + $warning =~ s:^: * :gm; + $warning =~ s: +$::gm; + $warning =~ s: :/:; + $warning =~ s:$:/:; } else { -$warning =~ s:^:# :gm; -$warning =~ s: +$::gm; + $warning =~ s:^:# :gm; + $warning =~ s: +$::gm; } $warning; } # do_not_edit @@ -51,7 +51,8 @@ open IN, "embed.fnc" or die $!; sub walk_table (&@) { my $function = shift; my $filename = shift || '-'; - my $leader = shift || do_not_edit ($filename); + my $leader = shift; + defined $leader or $leader = do_not_edit ($filename); my $trailer = shift; my $F; local *F; @@ -96,7 +97,7 @@ sub munge_c_files () { if (@_ > 1) { $functions->{$_[2]} = \@_ if $_[@_-1] =~ /\.\.\./; } - } '/dev/null'; + } '/dev/null', ''; local $^I = '.bak'; while (<>) { # if (/^#\s*include\s+"perl.h"/) { @@ -200,8 +201,8 @@ sub write_global_sym { $ret; } -walk_table(\&write_protos, "proto.h"); -walk_table(\&write_global_sym, "global.sym"); +walk_table(\&write_protos, "proto.h", ""); +walk_table(\&write_global_sym, "global.sym", ""); # XXX others that may need adding # warnhook @@ -334,7 +335,7 @@ walk_table { } } $ret; -} \*EM; +} \*EM, ""; for $sym (sort keys %ppsym) { $sym =~ s/^Perl_//; @@ -387,7 +388,7 @@ walk_table { } } $ret; -} \*EM; +} \*EM, ""; for $sym (sort keys %ppsym) { $sym =~ s/^Perl_//;