git.iko.soy/typeable/nixpkgs
on master help sign in
cryptominisat: fix build on darwin
commite3d703bb921c482add5d6bd633990a00b729ccc0 authorJörg Thalheim <joerg@thalheim.io> dateThu 9 Jul 2020, 08:11 (6 years ago) parent3628d0d
2 files changed+31
pkgs/applications/science/logic/cryptominisat/0001-fix-build-on-Nix-macOS.patch+29 pkgs/applications/science/logic/cryptominisat/default.nix+2
pkgs/applications/science/logic/cryptominisat/0001-fix-build-on-Nix-macOS.patchnew file+29
@@ -0,0 +1,29 @@
1+From b1bfa51c4032b4eedc61b536c852b6ff2a295f07 Mon Sep 17 00:00:00 2001
2+From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= <joerg@thalheim.io>
3+Date: Thu, 9 Jul 2020 08:08:25 +0100
4+Subject: [PATCH] fix build on Nix/macOS
5+MIME-Version: 1.0
6+Content-Type: text/plain; charset=UTF-8
7+Content-Transfer-Encoding: 8bit
8+
9+Signed-off-by: Jörg Thalheim <joerg@thalheim.io>
10+---
11+ python/CMakeLists.txt | 2 +-
12+ 1 file changed, 1 insertion(+), 1 deletion(-)
13+
14+diff --git a/python/CMakeLists.txt b/python/CMakeLists.txt
15+index f549ca7..5a23f25 100644
16+--- a/python/CMakeLists.txt
17++++ b/python/CMakeLists.txt
18+@@ -77,7 +77,7 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "Windows")
19+ ARGS setup.py build_ext --inplace
20+ DEPENDS cryptominisat5
21+ )
22+-elseif (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
23++elseif (${CMAKE_SYSTEM_NAME} MATCHES "Darwin" AND NOT DEFINED ENV{NIX_CC})
24+ execute_process(COMMAND xcrun --show-sdk-path
25+ OUTPUT_VARIABLE PY_OSX_SDK_PATH
26+ OUTPUT_STRIP_TRAILING_WHITESPACE)
27+--
28+2.24.3 (Apple Git-128)
29+
pkgs/applications/science/logic/cryptominisat/default.nix+2
@@ -11,6 +11,8 @@ stdenv.mkDerivation rec {
1111 sha256 = "00hmxdlyhn7pwk9jlvc5g0l5z5xqfchjzf5jgn3pkj9xhl8yqq50";
1212 };
1313
14+ patches = [ ./0001-fix-build-on-Nix-macOS.patch ];
15+
1416 buildInputs = [ python3 boost ];
1517 nativeBuildInputs = [ cmake xxd ];
1618