From 5548ff174ca661d6585f8838a9d1c72003daf603 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phan=20Kochen?= Date: Sat, 15 May 2021 17:28:37 +0200 Subject: [PATCH] getxbook: fix clang build --- pkgs/applications/misc/getxbook/default.nix | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/misc/getxbook/default.nix b/pkgs/applications/misc/getxbook/default.nix index a69f8d7f0574..15b7c37244fd 100644 --- a/pkgs/applications/misc/getxbook/default.nix +++ b/pkgs/applications/misc/getxbook/default.nix @@ -9,11 +9,13 @@ stdenv.mkDerivation rec { sha256 = "0ihwrx4gspj8l7fc8vxch6dpjrw1lvv9z3c19f0wxnmnxhv1cjvs"; }; - NIX_CFLAGS_COMPILE = builtins.toString [ - "-Wno-error=format-truncation" - "-Wno-error=deprecated-declarations" - "-Wno-error=stringop-overflow" - ]; + NIX_CFLAGS_COMPILE = builtins.toString ( + [ "-Wno-error=deprecated-declarations" ] + ++ lib.optionals (!stdenv.cc.isClang) [ + "-Wno-error=format-truncation" + "-Wno-error=stringop-overflow" + ] + ); buildInputs = [ openssl ];