From 1acb4aaf7d02798efbd1a4de5f53c4eed6d4ffc4 Mon Sep 17 00:00:00 2001 From: Weijia Wang <9713184+wegank@users.noreply.github.com> Date: Sun, 5 Nov 2023 19:49:04 +0100 Subject: [PATCH] onnxruntime: fix build with clang 16 --- pkgs/development/libraries/onnxruntime/default.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pkgs/development/libraries/onnxruntime/default.nix b/pkgs/development/libraries/onnxruntime/default.nix index 5252875b27e9..7a8b8570f62c 100644 --- a/pkgs/development/libraries/onnxruntime/default.nix +++ b/pkgs/development/libraries/onnxruntime/default.nix @@ -154,6 +154,13 @@ stdenv.mkDerivation rec { "-Donnxruntime_ENABLE_PYTHON=ON" ]; + env = lib.optionalAttrs stdenv.cc.isClang { + NIX_CFLAGS_COMPILE = toString [ + "-Wno-error=deprecated-declarations" + "-Wno-error=unused-but-set-variable" + ]; + }; + doCheck = true; postPatch = ''