summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2000-09-28 13:18:10 +0100
committerJarkko Hietaniemi <jhi@iki.fi>2000-10-02 23:57:51 +0000
commitd873810b3537a2d7375918c521de90017ed077b7 (patch)
treea4cf246d37694e5507c4ca463411dc533eb03d11 /utils
parentc26893538723a2740afe1c2f89ea22856818835b (diff)
downloadperl-d873810b3537a2d7375918c521de90017ed077b7.tar.gz
[ID 20000928.002] perlcc & ByteCode.pm option mismatch
Message-Id: <E13ebha-0004IV-00@fruitbat.babyhippo.co.uk> Did not apply cleanly, manual intervention was needed. p4raw-id: //depot/perl@7117
Diffstat (limited to 'utils')
-rw-r--r--utils/perlcc.PL17
1 files changed, 9 insertions, 8 deletions
diff --git a/utils/perlcc.PL b/utils/perlcc.PL
index 0215c8daa6..0c4b726d35 100644
--- a/utils/perlcc.PL
+++ b/utils/perlcc.PL
@@ -231,17 +231,18 @@ EOF
vprint 1, "Compiling...";
vprint 3, "Calling $command";
- my ($output_r, $error_r) = spawnit($command);
- my @output = @$output_r;
- my @error = @$error_r;
+ my ($output_r, $error_r) = spawnit($command);
- if (@error && $? != 0) {
- die "$0: $Input did not compile, which can't happen:\n@error\n";
+ if (@$error_r && $? != 0) {
+ die "$0: $Input did not compile, which can't happen:\n@$error_r\n";
+ } else {
+ my @error = grep { !/^$Input syntax OK$/o } @$error_r;
+ warn "$0: Unexpected compiler output:\n@error" if @error;
}
-
+
# Write it and leave.
- print OUT @output or die "can't write $Output: $!";
- close OUT or die "can't close $Output: $!";
+ print OUT @$output_r or die "can't write $Output: $!";
+ close OUT or die "can't close $Output: $!";
# wait, how could it be anything but what you see next?
chmod 0777 & ~umask, $Output or die "can't chmod $Output: $!";