···4848 # Prior overrides are surely not valid as packages built with this run on
4949 # a different platform, and so are disabled.
5050 overrides = _: _: {};
5151- extraBuildInputs = [ ]; # Old ones run on wrong platform
5151+ extraBuildInputs = [ ] # Old ones run on wrong platform
5252+ ++ lib.optionals hostPlatform.isDarwin [ buildPackages.targetPackages.darwin.apple_sdk.frameworks.CoreFoundation ]
5353+ ;
5254 allowedRequisites = null;
53555456 hasCC = !targetPlatform.isGhcjs;
+12-1
pkgs/top-level/all-packages.nix
···3030 # just the plain stdenv.
3131 stdenv_32bit = lowPrio (if stdenv.hostPlatform.is32bit then stdenv else multiStdenv);
32323333- stdenvNoCC = stdenv.override { cc = null; hasCC = false; };
3333+ stdenvNoCC = stdenv.override (
3434+ { cc = null; hasCC = false; }
3535+3636+ // lib.optionalAttrs (stdenv.hostPlatform.isDarwin && (stdenv.hostPlatform != stdenv.buildPlatform)) {
3737+ # TODO: This is a hack to use stdenvNoCC to produce a CF when cross
3838+ # compiling. It's not very sound. The cross stdenv has:
3939+ # extraBuildInputs = [ targetPackages.darwin.apple_sdks.frameworks.CoreFoundation ]
4040+ # and uses stdenvNoCC. In order to make this not infinitely recursive, we need to exclude
4141+ # this extraBuildInput.
4242+ extraBuildInputs = [];
4343+ }
4444+ );
34453546 mkStdenvNoLibs = stdenv: let
3647 bintools = stdenv.cc.bintools.override {