edk2: fix build on x86_64-darwin

ZHF #199919
This commit is contained in:
Randy Eckenrode 2022-11-06 18:54:18 -05:00
parent f54c651ba5
commit 4d3207ecf7
No known key found for this signature in database
GPG key ID: 64C1CD4EC2A600D9

View file

@ -61,7 +61,7 @@ edk2 = buildStdenv.mkDerivation {
${"GCC5_${targetArch}_PREFIX"}=stdenv.cc.targetPrefix;
makeFlags = [ "-C BaseTools" ]
++ lib.optionals (stdenv.cc.isClang) [ "BUILD_CC=clang BUILD_CXX=clang++ BUILD_AS=clang" ];
++ lib.optionals (stdenv.cc.isClang) [ "CXX=llvm BUILD_AR=ar BUILD_CC=clang BUILD_CXX=clang++ BUILD_AS=clang BUILD_LD=ld" ];
NIX_CFLAGS_COMPILE = "-Wno-return-type" + lib.optionalString (stdenv.cc.isGNU) " -Wno-error=stringop-truncation";