summary refs log tree commit diff
diff options
context:
space:
mode:
-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 68d3f20db9..cf9e241410 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];