sys-devel/llvm: Include all experimental targets in -9999
authorMichał Górny <mgorny@gentoo.org>
Tue, 15 Aug 2017 11:18:31 +0000 (13:18 +0200)
committerMichał Górny <mgorny@gentoo.org>
Tue, 15 Aug 2017 12:35:32 +0000 (14:35 +0200)
sys-devel/llvm/llvm-9999.ebuild

index 65914f3a340be4a4800042ff7660c9107e4fe10d..e6a3f23898b40cd551b73d3ff1ea12205e715372 100644 (file)
@@ -17,9 +17,12 @@ SRC_URI=""
 EGIT_REPO_URI="https://git.llvm.org/git/llvm.git
        https://github.com/llvm-mirror/llvm.git"
 
+# Those are in lib/Targets, without explicit CMakeLists.txt mention
+ALL_LLVM_EXPERIMENTAL_TARGETS=( AVR Nios2 RISCV WebAssembly )
 # Keep in sync with CMakeLists.txt
 ALL_LLVM_TARGETS=( AArch64 AMDGPU ARM BPF Hexagon Lanai Mips MSP430
-       NVPTX PowerPC Sparc SystemZ X86 XCore )
+       NVPTX PowerPC Sparc SystemZ X86 XCore
+       "${ALL_LLVM_EXPERIMENTAL_TARGETS[@]}" )
 ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" )
 
 # Additional licenses:
@@ -106,7 +109,10 @@ multilib_src_configure() {
                -DLLVM_LIBDIR_SUFFIX=${libdir#lib}
 
                -DBUILD_SHARED_LIBS=ON
-               -DLLVM_TARGETS_TO_BUILD="${LLVM_TARGETS// /;}"
+               # cheap hack: LLVM combines both anyway, and the only difference
+               # is that the former list is explicitly verified at cmake time
+               -DLLVM_TARGETS_TO_BUILD=""
+               -DLLVM_EXPERIMENTAL_TARGETS_TO_BUILD="${LLVM_TARGETS// /;}"
                -DLLVM_BUILD_TESTS=$(usex test)
 
                -DLLVM_ENABLE_FFI=$(usex libffi)