diff options
author | Anton Korobeynikov <asl@math.spbu.ru> | 2009-04-21 16:04:14 +0000 |
---|---|---|
committer | Anton Korobeynikov <asl@math.spbu.ru> | 2009-04-21 16:04:14 +0000 |
commit | 8d8fbf204db2e051a9b37b2f9d5431cab748bfde (patch) | |
tree | 35031c33e3c6ddd5617b075facc3acf81c5afe34 /utils/GenLibDeps.pl | |
parent | 005e7984ccc20c65a3bdfc112021b337935131a9 (diff) | |
download | external_llvm-8d8fbf204db2e051a9b37b2f9d5431cab748bfde.zip external_llvm-8d8fbf204db2e051a9b37b2f9d5431cab748bfde.tar.gz external_llvm-8d8fbf204db2e051a9b37b2f9d5431cab748bfde.tar.bz2 |
'The "or die" is intended to catch the case where nm returned a
non-zero exit status, so nm will already have printed some error
messages.'
Patch by Jay Foad!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@69677 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils/GenLibDeps.pl')
-rwxr-xr-x | utils/GenLibDeps.pl | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/utils/GenLibDeps.pl b/utils/GenLibDeps.pl index e501774..73f3e71 100755 --- a/utils/GenLibDeps.pl +++ b/utils/GenLibDeps.pl @@ -66,7 +66,7 @@ foreach my $lib (@libs ) { # this strips both LF and CRLF. $libdefs{$_} = $lib; } - close DEFS; + close DEFS or die "nm failed"; } # Gather definitions from the object files. @@ -79,7 +79,7 @@ foreach my $obj (@objs ) { # this strips both LF and CRLF. $objdefs{$_} = $obj; } - close DEFS; + close DEFS or die "nm failed"; } # Generate one entry in the <dl> list. This generates the <dt> and <dd> elements @@ -113,7 +113,7 @@ sub gen_one_entry { } } } - close UNDEFS; + close UNDEFS or die "nm failed"; unless(keys %DepLibs) { # above failed open UNDEFS, "$nmPath -g -u $Directory/$lib |"; @@ -138,6 +138,7 @@ sub gen_one_entry { } } } + close UNDEFS or die "nm failed"; } for my $key (sort keys %DepLibs) { |