2016-12-16 14:22:02 +01:00
|
|
|
{ lib
|
2018-12-05 04:06:46 +01:00
|
|
|
, crossSystem, localSystem, config, overlays
|
2016-12-16 14:22:02 +01:00
|
|
|
, bootStages
|
|
|
|
, ...
|
|
|
|
}:
|
|
|
|
|
2018-12-05 04:06:46 +01:00
|
|
|
assert crossSystem == localSystem;
|
2016-12-16 14:22:02 +01:00
|
|
|
|
|
|
|
bootStages ++ [
|
2017-09-20 17:07:52 +02:00
|
|
|
(prevStage: {
|
2016-12-24 19:55:11 +01:00
|
|
|
inherit config overlays;
|
2016-12-16 14:22:02 +01:00
|
|
|
|
|
|
|
stdenv = import ../generic rec {
|
|
|
|
inherit config;
|
|
|
|
|
2017-08-22 00:26:08 +02:00
|
|
|
inherit (prevStage.stdenv) buildPlatform hostPlatform targetPlatform;
|
|
|
|
|
2016-12-16 14:22:02 +01:00
|
|
|
preHook = ''
|
|
|
|
export NIX_ENFORCE_PURITY="''${NIX_ENFORCE_PURITY-1}"
|
|
|
|
export NIX_ENFORCE_NO_NATIVE="''${NIX_ENFORCE_NO_NATIVE-1}"
|
|
|
|
export NIX_IGNORE_LD_THROUGH_GCC=1
|
|
|
|
'';
|
|
|
|
|
|
|
|
initialPath = (import ../common-path.nix) { pkgs = prevStage; };
|
|
|
|
|
|
|
|
cc = import ../../build-support/cc-wrapper {
|
|
|
|
nativeTools = false;
|
2017-09-20 17:07:52 +02:00
|
|
|
nativePrefix = lib.optionalString hostPlatform.isSunOS "/usr";
|
2016-12-16 14:22:02 +01:00
|
|
|
nativeLibc = true;
|
2017-09-20 17:07:52 +02:00
|
|
|
inherit (prevStage) stdenvNoCC binutils coreutils gnugrep;
|
2016-12-16 14:22:02 +01:00
|
|
|
cc = prevStage.gcc.cc;
|
|
|
|
isGNU = true;
|
|
|
|
shell = prevStage.bash + "/bin/sh";
|
|
|
|
};
|
|
|
|
|
|
|
|
shell = prevStage.bash + "/bin/sh";
|
|
|
|
|
2017-09-20 17:07:52 +02:00
|
|
|
fetchurlBoot = prevStage.stdenv.fetchurlBoot;
|
2016-12-16 14:22:02 +01:00
|
|
|
|
|
|
|
overrides = self: super: {
|
|
|
|
inherit cc;
|
|
|
|
inherit (cc) binutils;
|
|
|
|
inherit (prevStage)
|
|
|
|
gzip bzip2 xz bash coreutils diffutils findutils gawk
|
|
|
|
gnumake gnused gnutar gnugrep gnupatch perl;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
})
|
|
|
|
]
|