about summary refs log tree commit diff
path: root/scripts
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2005-02-01T09·54+0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2005-02-01T09·54+0000
commita6b65fd5e107416588a6572a88518d8816abcb12 (patch)
treeb1a5df197e55b7a14cf31edae2de06d8a773c099 /scripts
parent06b44242860d62e12f9abe018c6f974ceaa30bb9 (diff)
* Get rid of hardcoded paths.
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/generate-patches.pl.in (renamed from scripts/generate-patches.pl)14
1 files changed, 7 insertions, 7 deletions
diff --git a/scripts/generate-patches.pl b/scripts/generate-patches.pl.in
index 68d3f20db9a0..cf9e241410d5 100755
--- a/scripts/generate-patches.pl
+++ b/scripts/generate-patches.pl.in
@@ -1,4 +1,4 @@
-#! /usr/bin/perl -w -I/home/eelco/nix/scripts
+#! @perl@ -w -I@libexecdir@/nix
 
 use strict;
 use POSIX qw(tmpnam);
@@ -186,22 +186,22 @@ foreach my $p (keys %dstOutPaths) {
         my $srcNarBz2 = getNarBz2 \%srcNarFiles, $closest;
         my $dstNarBz2 = getNarBz2 \%dstNarFiles, $p;
         
-        system("bunzip2 < $srcNarBz2 > $tmpdir/A") == 0
+        system("@bunzip2@ < $srcNarBz2 > $tmpdir/A") == 0
             or die "cannot unpack $srcNarBz2";
 
-        system("bunzip2 < $dstNarBz2 > $tmpdir/B") == 0
+        system("@bunzip2@ < $dstNarBz2 > $tmpdir/B") == 0
             or die "cannot unpack $dstNarBz2";
 
-        system("bsdiff $tmpdir/A $tmpdir/B $tmpdir/DIFF") == 0
+        system("@libexecdir@/bspatch $tmpdir/A $tmpdir/B $tmpdir/DIFF") == 0
             or die "cannot compute binary diff";
 
-        my $baseHash = `nix-hash --flat $tmpdir/A` or die;
+        my $baseHash = `@bindir@/nix-hash --flat $tmpdir/A` or die;
         chomp $baseHash;
 
-        my $narHash = `nix-hash --flat $tmpdir/B` or die;
+        my $narHash = `@bindir@/nix-hash --flat $tmpdir/B` or die;
         chomp $narHash;
 
-        my $narDiffHash = `nix-hash --flat $tmpdir/DIFF` or die;
+        my $narDiffHash = `@bindir@/nix-hash --flat $tmpdir/DIFF` or die;
         chomp $narDiffHash;
 
         my $narDiffSize = (stat "$tmpdir/DIFF")[7];