From 604ca29bf0435053864ce168d2df57e70542d66e Mon Sep 17 00:00:00 2001 From: Armijn Hemel Date: Wed, 2 Aug 2006 20:44:17 +0000 Subject: [PATCH] add patches: * nix-0.10pre5896-paths.patch :: this path adds coreutils to the searchpath, so nix-prefetch-url can find "basename" * nix-0.10pre5896-chroot-once.patch :: unsets NIX_ROOT in various scripts, to prevent that when NIX_ROOT is set and one of the nix tools is called that chroot() is performed once more svn path=/nixpkgs/trunk/; revision=6023 --- pkgs/misc/nix-unstable/default.nix | 2 +- .../nix-0.10pre5896-chroot-once.patch | 28 +++++++++++++++++++ .../nix-unstable/nix-0.10pre5896-paths.patch | 14 ++++++++++ 3 files changed, 43 insertions(+), 1 deletion(-) create mode 100644 pkgs/misc/nix-unstable/nix-0.10pre5896-chroot-once.patch create mode 100644 pkgs/misc/nix-unstable/nix-0.10pre5896-paths.patch diff --git a/pkgs/misc/nix-unstable/default.nix b/pkgs/misc/nix-unstable/default.nix index d678d925d43..608a7638d13 100644 --- a/pkgs/misc/nix-unstable/default.nix +++ b/pkgs/misc/nix-unstable/default.nix @@ -20,5 +20,5 @@ stdenv.mkDerivation { # uncomment if you want to be able to use nix-prefetch-url when NIX_ROOT # is set #patches = [./nix-0.10pre5679.patch]; - patches = [./nix-0.10pre5896-date.patch]; + patches = [./nix-0.10pre5896-date.patch ./nix-0.10pre5896-paths.patch ./nix-0.10pre5896-chroot-once.patch]; } diff --git a/pkgs/misc/nix-unstable/nix-0.10pre5896-chroot-once.patch b/pkgs/misc/nix-unstable/nix-0.10pre5896-chroot-once.patch new file mode 100644 index 00000000000..3ff525ec97c --- /dev/null +++ b/pkgs/misc/nix-unstable/nix-0.10pre5896-chroot-once.patch @@ -0,0 +1,28 @@ +diff -rc nix-0.10pre5896/scripts/download-using-manifests.pl.in nix-0.10pre5896.new/scripts/download-using-manifests.pl.in +*** nix-0.10pre5896/scripts/download-using-manifests.pl.in 2006-07-24 20:39:47.000000000 +0200 +--- nix-0.10pre5896.new/scripts/download-using-manifests.pl.in 2006-08-02 21:45:53.000000000 +0200 +*************** +*** 9,14 **** +--- 9,15 ---- + + open LOGFILE, ">>$logFile" or die "cannot open log file $logFile"; + ++ delete $ENV{"NIX_ROOT"}; + + # Create a temporary directory. + my $tmpDir; +diff -rc nix-0.10pre5896/scripts/nix-prefetch-url.in nix-0.10pre5896.new/scripts/nix-prefetch-url.in +*** nix-0.10pre5896/scripts/nix-prefetch-url.in 2006-07-24 20:39:47.000000000 +0200 +--- nix-0.10pre5896.new/scripts/nix-prefetch-url.in 2006-08-02 21:13:46.000000000 +0200 +*************** +*** 3,8 **** +--- 3,11 ---- + url=$1 + expHash=$2 + ++ # to prevent doing more than 1 chroot ++ unset NIX_ROOT ++ + hashType=$NIX_HASH_ALGO + if test -z "$hashType"; then + hashType=md5 diff --git a/pkgs/misc/nix-unstable/nix-0.10pre5896-paths.patch b/pkgs/misc/nix-unstable/nix-0.10pre5896-paths.patch new file mode 100644 index 00000000000..430620c0039 --- /dev/null +++ b/pkgs/misc/nix-unstable/nix-0.10pre5896-paths.patch @@ -0,0 +1,14 @@ +diff -rc nix-0.10pre5896/scripts/nix-prefetch-url.in nix-0.10pre5896.new/scripts/nix-prefetch-url.in +*** nix-0.10pre5896/scripts/nix-prefetch-url.in 2006-07-24 20:39:47.000000000 +0200 +--- nix-0.10pre5896.new/scripts/nix-prefetch-url.in 2006-08-02 20:01:15.000000000 +0200 +*************** +*** 3,8 **** +--- 3,10 ---- + url=$1 + expHash=$2 + ++ export PATH=$PATH:@coreutils@ ++ + hashType=$NIX_HASH_ALGO + if test -z "$hashType"; then + hashType=md5