From 68513e40711cd942144a1da9c9e434b378c2c762 Mon Sep 17 00:00:00 2001 From: Daiderd Jordan Date: Tue, 14 Jan 2020 12:43:54 +0100 Subject: [PATCH] cmake: move CMAKE_OSX_ARCHITECTURES out of the stdenv This was initially introduced in 92188d9d1751892ddbf8913da73dfc150d18fadb, not clear how relevant this still is but i686 isn't supported anymore so disable it explicitly. --- pkgs/development/tools/build-managers/cmake/setup-hook.sh | 3 +++ pkgs/stdenv/darwin/default.nix | 1 - 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/development/tools/build-managers/cmake/setup-hook.sh b/pkgs/development/tools/build-managers/cmake/setup-hook.sh index 5479067d637e..87bbefa6bbfa 100755 --- a/pkgs/development/tools/build-managers/cmake/setup-hook.sh +++ b/pkgs/development/tools/build-managers/cmake/setup-hook.sh @@ -50,6 +50,9 @@ cmakeConfigurePhase() { # because we usually do not package the framework cmakeFlags="-DCMAKE_FIND_FRAMEWORK=last $cmakeFlags" + # on macOS i686 was only relevant for 10.5 or earlier. + cmakeFlags="-DCMAKE_OSX_ARCHITECTURES=x86_64 $cmakeFlags" + # we never want to use the global macOS SDK cmakeFlags="-DCMAKE_OSX_SYSROOT= $cmakeFlags" diff --git a/pkgs/stdenv/darwin/default.nix b/pkgs/stdenv/darwin/default.nix index 7a9c20fd6a7b..4f91d18a3764 100644 --- a/pkgs/stdenv/darwin/default.nix +++ b/pkgs/stdenv/darwin/default.nix @@ -34,7 +34,6 @@ in rec { export NIX_ENFORCE_NO_NATIVE=''${NIX_ENFORCE_NO_NATIVE-1} export NIX_ENFORCE_PURITY=''${NIX_ENFORCE_PURITY-1} export NIX_IGNORE_LD_THROUGH_GCC=1 - export CMAKE_OSX_ARCHITECTURES=x86_64 export SDKROOT= # Ensure consistent LC_VERSION_MIN_MACOSX and remove LC_UUID.