llvm4: unconditionally set triples, not just on musl.
Split off from #42454 as requested.
This commit is contained in:
parent
798ad38c35
commit
0ac09be295
@ -100,6 +100,10 @@ in stdenv.mkDerivation (rec {
|
|||||||
"-DLLVM_ENABLE_FFI=ON"
|
"-DLLVM_ENABLE_FFI=ON"
|
||||||
"-DLLVM_ENABLE_RTTI=ON"
|
"-DLLVM_ENABLE_RTTI=ON"
|
||||||
"-DCOMPILER_RT_INCLUDE_TESTS=OFF" # FIXME: requires clang source code
|
"-DCOMPILER_RT_INCLUDE_TESTS=OFF" # FIXME: requires clang source code
|
||||||
|
|
||||||
|
"-DLLVM_HOST_TRIPLE=${stdenv.hostPlatform.config}"
|
||||||
|
"-DLLVM_DEFAULT_TARGET_TRIPLE=${stdenv.targetPlatform.config}"
|
||||||
|
"-DTARGET_TRIPLE=${stdenv.targetPlatform.config}"
|
||||||
]
|
]
|
||||||
++ stdenv.lib.optional enableSharedLibraries
|
++ stdenv.lib.optional enableSharedLibraries
|
||||||
"-DLLVM_LINK_LLVM_DYLIB=ON"
|
"-DLLVM_LINK_LLVM_DYLIB=ON"
|
||||||
@ -115,11 +119,6 @@ in stdenv.mkDerivation (rec {
|
|||||||
++ stdenv.lib.optionals (isDarwin) [
|
++ stdenv.lib.optionals (isDarwin) [
|
||||||
"-DLLVM_ENABLE_LIBCXX=ON"
|
"-DLLVM_ENABLE_LIBCXX=ON"
|
||||||
"-DCAN_TARGET_i386=false"
|
"-DCAN_TARGET_i386=false"
|
||||||
]
|
|
||||||
++ stdenv.lib.optionals stdenv.hostPlatform.isMusl [
|
|
||||||
"-DLLVM_HOST_TRIPLE=${stdenv.hostPlatform.config}"
|
|
||||||
"-DLLVM_DEFAULT_TARGET_TRIPLE=${stdenv.targetPlatform.config}"
|
|
||||||
"-DTARGET_TRIPLE=${stdenv.targetPlatform.config}"
|
|
||||||
];
|
];
|
||||||
|
|
||||||
postBuild = ''
|
postBuild = ''
|
||||||
|
Loading…
x
Reference in New Issue
Block a user