Merge pull request #238129 from alexfmpe/ispc-darwin
This commit is contained in:
commit
04294b836c
|
@ -1,5 +1,5 @@
|
|||
{ lib, stdenv, fetchFromGitHub, fetchpatch
|
||||
, cmake, which, m4, python3, bison, flex, llvmPackages, ncurses
|
||||
, cmake, which, m4, python3, bison, flex, llvmPackages, ncurses, xcode
|
||||
|
||||
# the default test target is sse4, but that is not supported by all Hydra agents
|
||||
, testedTargets ? if stdenv.isAarch64 || stdenv.isAarch32 then [ "neon-i32x4" ] else [ "sse2-i32x4" ]
|
||||
|
@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
|
|||
sha256 = "sha256-WBAVgjQjW4x9JGx6xotPoTVOePsPjBJEyBYA7TCTBvc=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake which m4 bison flex python3 llvmPackages.libllvm.dev ];
|
||||
nativeBuildInputs = [ cmake which m4 bison flex python3 llvmPackages.libllvm.dev ] ++ lib.lists.optionals stdenv.isDarwin [ xcode ];
|
||||
buildInputs = with llvmPackages; [
|
||||
libllvm libclang openmp ncurses
|
||||
];
|
||||
|
@ -30,8 +30,7 @@ stdenv.mkDerivation rec {
|
|||
|
||||
inherit testedTargets;
|
||||
|
||||
# needs 'transcendentals' executable, which is only on linux
|
||||
doCheck = stdenv.isLinux;
|
||||
doCheck = true;
|
||||
|
||||
# the compiler enforces -Werror, and -fno-strict-overflow makes it mad.
|
||||
# hilariously this is something of a double negative: 'disable' the
|
||||
|
@ -60,6 +59,8 @@ stdenv.mkDerivation rec {
|
|||
"-DISPC_INCLUDE_UTILS=OFF"
|
||||
("-DARM_ENABLED=" + (if stdenv.isAarch64 || stdenv.isAarch32 then "TRUE" else "FALSE"))
|
||||
("-DX86_ENABLED=" + (if stdenv.isx86_64 || stdenv.isx86_32 then "TRUE" else "FALSE"))
|
||||
] ++ lib.lists.optionals stdenv.isDarwin [
|
||||
"-DISPC_MACOS_SDK_PATH=${xcode}/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
|
|
|
@ -21582,6 +21582,7 @@ with pkgs;
|
|||
|
||||
ispc = callPackage ../development/compilers/ispc {
|
||||
inherit (llvmPackages) stdenv;
|
||||
xcode = darwin.xcode_14;
|
||||
};
|
||||
|
||||
isso = callPackage ../servers/isso {
|
||||
|
|
Loading…
Reference in a new issue