diff options
author | Daiderd Jordan <daiderd@gmail.com> | 2017-07-08 22:21:32 +0200 |
---|---|---|
committer | Daiderd Jordan <daiderd@gmail.com> | 2017-07-08 22:22:17 +0200 |
commit | 980346592c07e565c90f947a68f4ea1a2f3e3dc2 (patch) | |
tree | e6b44f9a5458db30026c2a1645aa6e14db1b51fe /pkgs/stdenv | |
parent | 800d44984f50947122fa39de559127e416f0ddc8 (diff) | |
parent | 7e3a1a58cf8e5bf6cac5811493389953090f678a (diff) | |
download | nixlib-980346592c07e565c90f947a68f4ea1a2f3e3dc2.tar nixlib-980346592c07e565c90f947a68f4ea1a2f3e3dc2.tar.gz nixlib-980346592c07e565c90f947a68f4ea1a2f3e3dc2.tar.bz2 nixlib-980346592c07e565c90f947a68f4ea1a2f3e3dc2.tar.lz nixlib-980346592c07e565c90f947a68f4ea1a2f3e3dc2.tar.xz nixlib-980346592c07e565c90f947a68f4ea1a2f3e3dc2.tar.zst nixlib-980346592c07e565c90f947a68f4ea1a2f3e3dc2.zip |
Merge branch 'staging' into master
Diffstat (limited to 'pkgs/stdenv')
-rw-r--r-- | pkgs/stdenv/darwin/default.nix | 20 | ||||
-rw-r--r-- | pkgs/stdenv/linux/default.nix | 10 |
2 files changed, 27 insertions, 3 deletions
diff --git a/pkgs/stdenv/darwin/default.nix b/pkgs/stdenv/darwin/default.nix index 0e68b5c8e128..f6d9bcac5104 100644 --- a/pkgs/stdenv/darwin/default.nix +++ b/pkgs/stdenv/darwin/default.nix @@ -54,14 +54,17 @@ in rec { __sandboxProfile = binShClosure + libSystemProfile; }; - stageFun = step: last: {shell ? "${bootstrapTools}/bin/sh", + stageFun = step: last: {shell ? "${bootstrapTools}/bin/bash", overrides ? (self: super: {}), extraPreHook ? "", extraBuildInputs, allowedRequisites ? null}: let thisStdenv = import ../generic { - inherit config shell extraBuildInputs allowedRequisites; + inherit config shell extraBuildInputs; + allowedRequisites = if allowedRequisites == null then null else allowedRequisites ++ [ + thisStdenv.cc.expand-response-params + ]; name = "stdenv-darwin-boot-${toString step}"; @@ -77,12 +80,17 @@ in rec { nativeTools = true; nativePrefix = bootstrapTools; nativeLibc = false; + buildPackages = lib.optionalAttrs (last ? stdenv) { + inherit (last) stdenv; + }; + hostPlatform = localSystem; + targetPlatform = localSystem; libc = last.pkgs.darwin.Libsystem; isClang = true; cc = { name = "clang-9.9.9"; outPath = bootstrapTools; }; }; - preHook = stage0.stdenv.lib.optionalString (shell == "${bootstrapTools}/bin/sh") '' + preHook = stage0.stdenv.lib.optionalString (shell == "${bootstrapTools}/bin/bash") '' # Don't patch #!/interpreter because it leads to retained # dependencies on the bootstrapTools in the final stdenv. dontPatchShebangs=1 @@ -294,6 +302,11 @@ in rec { inherit shell; nativeTools = false; nativeLibc = false; + buildPackages = { + inherit (prevStage) stdenv; + }; + hostPlatform = localSystem; + targetPlatform = localSystem; inherit (pkgs) coreutils binutils gnugrep; inherit (pkgs.darwin) dyld; cc = pkgs.llvmPackages.clang-unwrapped; @@ -314,6 +327,7 @@ in rec { gzip ncurses.out ncurses.dev ncurses.man gnused bash gawk gnugrep llvmPackages.clang-unwrapped patch pcre.out binutils-raw.out binutils-raw.dev binutils gettext + cc.expand-response-params ]) ++ (with pkgs.darwin; [ dyld Libsystem CF cctools ICU libiconv locale ]); diff --git a/pkgs/stdenv/linux/default.nix b/pkgs/stdenv/linux/default.nix index a27aca771abd..c475d2d1e927 100644 --- a/pkgs/stdenv/linux/default.nix +++ b/pkgs/stdenv/linux/default.nix @@ -76,6 +76,11 @@ let else lib.makeOverridable (import ../../build-support/cc-wrapper) { nativeTools = false; nativeLibc = false; + buildPackages = lib.optionalAttrs (prevStage ? stdenv) { + inherit (prevStage) stdenv; + }; + hostPlatform = localSystem; + targetPlatform = localSystem; cc = prevStage.gcc-unwrapped; isGNU = true; libc = prevStage.glibc; @@ -236,6 +241,11 @@ in nativeTools = false; nativeLibc = false; isGNU = true; + buildPackages = { + inherit (prevStage) stdenv; + }; + hostPlatform = localSystem; + targetPlatform = localSystem; cc = prevStage.gcc-unwrapped; libc = self.glibc; inherit (self) stdenv binutils coreutils gnugrep; |