summaryrefslogtreecommitdiff
path: root/build-aux/prefix-gnulib-mk
diff options
context:
space:
mode:
authorJim Meyering <meyering@fb.com>2013-01-27 09:54:55 -0800
committerJim Meyering <meyering@fb.com>2013-03-15 22:13:46 -0700
commitcbd4dafd96be16e8e727663decb1002883813483 (patch)
tree775cbf7eaea1324f78c266ae6ed615d1005db9b8 /build-aux/prefix-gnulib-mk
parent726c760e3f7660648770641222fa84a3fcfd5849 (diff)
downloadgnulib-cbd4dafd96be16e8e727663decb1002883813483.tar.gz
prefix-gnulib-mk: give better diagnostics
* build-aux/prefix-gnulib-mk: Don't just "die". Give better diagnostics upon failure.
Diffstat (limited to 'build-aux/prefix-gnulib-mk')
-rwxr-xr-xbuild-aux/prefix-gnulib-mk5
1 files changed, 3 insertions, 2 deletions
diff --git a/build-aux/prefix-gnulib-mk b/build-aux/prefix-gnulib-mk
index 7553f6542d..4d0518fa1f 100755
--- a/build-aux/prefix-gnulib-mk
+++ b/build-aux/prefix-gnulib-mk
@@ -189,10 +189,11 @@ sub process ($)
{
my ($file) = @_;
my ($bak) = "$file.bak";
- rename ($file, $bak) or die;
+ rename ($file, $bak) or die "$ME: rename $file $bak failed: $!\n";
my $contents = contents ($bak);
$contents = prefix ($contents);
- my $out = new IO::File(">$file") or die;
+ my $out = new IO::File(">$file")
+ or die "$ME: $file: failed to open for writing: $!\n";
print $out $contents;
}