summary refs log tree commit diff
path: root/pkgs/stdenv
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2012-01-19 15:29:20 +0000
committerEelco Dolstra <eelco.dolstra@logicblox.com>2012-01-19 15:29:20 +0000
commit0d71e75222949f4e4a5ea8af8ac4666c3bb80579 (patch)
treec7f436fdff1257859f271ce60e99be20a1159fac /pkgs/stdenv
parent26affd7238ad8ae40ba0b02975a785546c51af8e (diff)
downloadnixlib-0d71e75222949f4e4a5ea8af8ac4666c3bb80579.tar
nixlib-0d71e75222949f4e4a5ea8af8ac4666c3bb80579.tar.gz
nixlib-0d71e75222949f4e4a5ea8af8ac4666c3bb80579.tar.bz2
nixlib-0d71e75222949f4e4a5ea8af8ac4666c3bb80579.tar.lz
nixlib-0d71e75222949f4e4a5ea8af8ac4666c3bb80579.tar.xz
nixlib-0d71e75222949f4e4a5ea8af8ac4666c3bb80579.tar.zst
nixlib-0d71e75222949f4e4a5ea8af8ac4666c3bb80579.zip
* Get rid of params1-5, they're obsolete.
svn path=/nixpkgs/branches/stdenv-updates/; revision=31700
Diffstat (limited to 'pkgs/stdenv')
-rw-r--r--pkgs/stdenv/generic/builder.sh21
-rw-r--r--pkgs/stdenv/generic/default.nix4
-rw-r--r--pkgs/stdenv/generic/setup.sh11
-rw-r--r--pkgs/stdenv/linux/default.nix1
4 files changed, 6 insertions, 31 deletions
diff --git a/pkgs/stdenv/generic/builder.sh b/pkgs/stdenv/generic/builder.sh
index 01e86ce39986..82620f96ef5c 100644
--- a/pkgs/stdenv/generic/builder.sh
+++ b/pkgs/stdenv/generic/builder.sh
@@ -1,32 +1,17 @@
-p1=$param1
-p2=$param2
-p3=$param3
-p4=$param4
-p5=$param5
-_preHook="$preHook"
-_postHook="$postHook"
-preHook=
-postHook=
-
 export PATH=
 for i in $initialPath; do
-    if test "$i" = /; then i=; fi
+    if [ "$i" = / ]; then i=; fi
     PATH=$PATH${PATH:+:}$i/bin
 done
 
 mkdir $out
 
 sed \
-    -e "s^@preHook@^$_preHook^g" \
-    -e "s^@postHook@^$_postHook^g" \
+    -e "s^@preHook@^$preHook^g" \
+    -e "s^@postHook@^$postHook^g" \
     -e "s^@initialPath@^$initialPath^g" \
     -e "s^@gcc@^$gcc^g" \
     -e "s^@shell@^$shell^g" \
-    -e "s^@param1@^$p1^g" \
-    -e "s^@param2@^$p2^g" \
-    -e "s^@param3@^$p3^g" \
-    -e "s^@param4@^$p4^g" \
-    -e "s^@param5@^$p5^g" \
     < "$setup" > "$out/setup"
 
 # Allow the user to install stdenv using nix-env and get the packages
diff --git a/pkgs/stdenv/generic/default.nix b/pkgs/stdenv/generic/default.nix
index b26bda91695f..b3f6c16eb02c 100644
--- a/pkgs/stdenv/generic/default.nix
+++ b/pkgs/stdenv/generic/default.nix
@@ -1,5 +1,4 @@
 { system, name, preHook ? null, postHook ? null, initialPath, gcc, shell
-, param1 ? "", param2 ? "", param3 ? "", param4 ? "", param5 ? ""
 , extraAttrs ? {}, overrides ? (pkgs: {})
 
 , # The `fetchurl' to use for downloading curl and its dependencies
@@ -27,9 +26,6 @@ let
 
         inherit preHook postHook initialPath gcc shell;
 
-        # TODO: make this more elegant.
-        inherit param1 param2 param3 param4 param5;
-
         propagatedUserEnvPkgs = [gcc] ++
           lib.filter lib.isDerivation initialPath;
       }
diff --git a/pkgs/stdenv/generic/setup.sh b/pkgs/stdenv/generic/setup.sh
index 9ea97c1bf581..ee1bd51caa93 100644
--- a/pkgs/stdenv/generic/setup.sh
+++ b/pkgs/stdenv/generic/setup.sh
@@ -106,20 +106,15 @@ fi
 
 # Execute the pre-hook.
 export SHELL=@shell@
-if test -z "$shell"; then
+if [ -z "$shell" ]; then
     export shell=@shell@
 fi
-param1=@param1@
-param2=@param2@
-param3=@param3@
-param4=@param4@
-param5=@param5@
-if test -n "@preHook@"; then source @preHook@; fi
+if [ -n "@preHook@" ]; then source @preHook@; fi
 runHook preHook
 
 
 # Check that the pre-hook initialised SHELL.
-if test -z "$SHELL"; then echo "SHELL not set"; exit 1; fi
+if [ -z "$SHELL" ]; then echo "SHELL not set"; exit 1; fi
 
 
 # Hack: run gcc's setup hook.
diff --git a/pkgs/stdenv/linux/default.nix b/pkgs/stdenv/linux/default.nix
index 900b6253c713..9937fd5db6ef 100644
--- a/pkgs/stdenv/linux/default.nix
+++ b/pkgs/stdenv/linux/default.nix
@@ -82,7 +82,6 @@ rec {
     import ../generic {
       inherit system;
       name = "stdenv-linux-boot";
-      param1 = bootstrapTools;
       preHook = builtins.toFile "prehook.sh"
         ''
           # Don't patch #!/interpreter because it leads to retained