summaryrefslogtreecommitdiffstats
path: root/pkgs/development/compilers/halide
diff options
context:
space:
mode:
authorTom Westerhout <14264576+twesterhout@users.noreply.github.com>2023-08-21 19:34:53 +0200
committerTom Westerhout <14264576+twesterhout@users.noreply.github.com>2023-08-21 19:34:53 +0200
commited6e240d32e6359be3947bdd8c852876e4464e4f (patch)
tree6fbde39808ed938db98def9efcd641b0f573c6b7 /pkgs/development/compilers/halide
parent77486e6c93353cdabccb650bc257e270be0cddb1 (diff)
halide: disable float16 support on aarch16-linux
Diffstat (limited to 'pkgs/development/compilers/halide')
-rw-r--r--pkgs/development/compilers/halide/default.nix9
1 files changed, 9 insertions, 0 deletions
diff --git a/pkgs/development/compilers/halide/default.nix b/pkgs/development/compilers/halide/default.nix
index 8a93b3cbb9d1..b508433bf94b 100644
--- a/pkgs/development/compilers/halide/default.nix
+++ b/pkgs/development/compilers/halide/default.nix
@@ -27,6 +27,15 @@ stdenv.mkDerivation rec {
sha256 = "sha256-lJQrXkJgBmGb/QMSxwuPkkHOSgEDowLWzIolp1km2Y8=";
};
+ postPatch = ''
+ # See https://github.com/halide/Halide/issues/7785
+ substituteInPlace 'src/runtime/HalideRuntime.h' \
+ --replace '#if defined(__x86_64__) || defined(__i386__) || defined(__arm__) || defined(__aarch64__)
+ #define HALIDE_CPP_COMPILER_HAS_FLOAT16' \
+ '#if defined(__x86_64__) || defined(__i386__)
+ #define HALIDE_CPP_COMPILER_HAS_FLOAT16'
+ '';
+
cmakeFlags = [
"-DWARNINGS_AS_ERRORS=OFF"
"-DWITH_PYTHON_BINDINGS=OFF"