about summary refs log tree commit diff
path: root/pkgs/stdenv/generic/setup.sh
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/stdenv/generic/setup.sh')
-rw-r--r--pkgs/stdenv/generic/setup.sh9
1 files changed, 2 insertions, 7 deletions
diff --git a/pkgs/stdenv/generic/setup.sh b/pkgs/stdenv/generic/setup.sh
index 1cc60ebf02bc..82ea0863a707 100644
--- a/pkgs/stdenv/generic/setup.sh
+++ b/pkgs/stdenv/generic/setup.sh
@@ -370,9 +370,8 @@ substitute() {
         content="${content//"$pattern"/$replacement}"
     done
 
-    printf "%s" "$content" > "$output".tmp
-    if [ -x "$output" ]; then chmod +x "$output".tmp; fi
-    mv -f "$output".tmp "$output"
+    chmod -f +w "$output" || true
+    printf "%s" "$content" > "$output"
 }
 
 
@@ -783,8 +782,6 @@ showPhaseHeader() {
 
 
 genericBuild() {
-    header "building $out"
-
     if [ -n "$buildCommand" ]; then
         eval "$buildCommand"
         return
@@ -828,8 +825,6 @@ genericBuild() {
 
         stopNest
     done
-
-    stopNest
 }