diff options
author | Eelco Dolstra <e.dolstra@tudelft.nl> | 2008-11-20 15:44:59 +0000 |
---|---|---|
committer | Eelco Dolstra <e.dolstra@tudelft.nl> | 2008-11-20 15:44:59 +0000 |
commit | 4213b8d8ec8cf478e43b0ec3dc4068e5e55f097a (patch) | |
tree | 2b95c8d933bae74c21d06ba7149d2ec1ab8924b0 /scripts/nix-build.in | |
parent | eb86b6f5a5429075866eca40d3cc4b864e7499ae (diff) | |
download | guix-4213b8d8ec8cf478e43b0ec3dc4068e5e55f097a.tar.gz |
* Urgh.
Diffstat (limited to 'scripts/nix-build.in')
-rw-r--r-- | scripts/nix-build.in | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/scripts/nix-build.in b/scripts/nix-build.in index a674a00415..30ada24e0d 100644 --- a/scripts/nix-build.in +++ b/scripts/nix-build.in @@ -2,6 +2,8 @@ use strict; +my $binDir = $ENV{"NIX_BIN_DIR"} || "@bindir@"; + my $addDrvLink = 0; my $addOutLink = 1; @@ -124,7 +126,7 @@ foreach my $expr (@exprs) { # Instantiate. my @drvPaths; # !!! would prefer the perl 5.8.0 pipe open feature here. - my $pid = open(DRVPATHS, "-|") || exec "@bindir@/nix-instantiate", "--add-root", $drvLink, "--indirect", @instArgs, $expr; + my $pid = open(DRVPATHS, "-|") || exec "$binDir/nix-instantiate", "--add-root", $drvLink, "--indirect", @instArgs, $expr; while (<DRVPATHS>) {chomp; push @drvPaths, $_;} close DRVPATHS or exit 1; @@ -135,7 +137,7 @@ foreach my $expr (@exprs) { # Build. my @outPaths; - $pid = open(OUTPATHS, "-|") || exec "@bindir@/nix-store", "--add-root", $outLink, "--indirect", "-rv", + $pid = open(OUTPATHS, "-|") || exec "$binDir/nix-store", "--add-root", $outLink, "--indirect", "-rv", @buildArgs, @drvPaths; while (<OUTPATHS>) {chomp; push @outPaths, $_;} close OUTPATHS or exit 1; |