python311Packages.lxml: avoid rebuild on gcc platforms

It's a bit impractical that our env parameter does
not have this property (with empty strings).
This commit is contained in:
Vladimír Čunát 2023-12-23 22:09:12 +01:00
parent f380d904e5
commit 71c906fbfa
No known key found for this signature in database
GPG key ID: E747DF1F9575A3AA

View file

@ -22,7 +22,9 @@ buildPythonPackage rec {
nativeBuildInputs = [ libxml2.dev libxslt.dev cython ] ++ lib.optionals stdenv.isDarwin [ xcodebuild ];
buildInputs = [ libxml2 libxslt zlib ];
env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.cc.isClang "-Wno-error=incompatible-function-pointer-types";
env = lib.optionalAttrs stdenv.cc.isClang {
NIX_CFLAGS_COMPILE = "-Wno-error=incompatible-function-pointer-types";
};
# tests are meant to be ran "in-place" in the same directory as src
doCheck = false;