python{310,311,312,313}: fix LTO build

Python LTO builds using clang require the clang’s `llvm-ar` even on Darwin.
This commit is contained in:
Randy Eckenrode 2024-07-20 21:33:28 -04:00
parent 312e20a312
commit 53f938e573
No known key found for this signature in database
GPG Key ID: 64C1CD4EC2A600D9

View File

@ -158,7 +158,7 @@ let
] ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
buildPackages.stdenv.cc
pythonOnBuildForHost
] ++ optionals (stdenv.cc.isClang && !stdenv.isDarwin && (!stdenv.hostPlatform.useAndroidPrebuilt or false) && (enableLTO || enableOptimizations)) [
] ++ optionals (stdenv.cc.isClang && (!stdenv.hostPlatform.useAndroidPrebuilt or false) && (enableLTO || enableOptimizations)) [
stdenv.cc.cc.libllvm.out
];