diff options
author | Khem Raj <raj.khem@gmail.com> | 2017-08-03 13:30:58 -0700 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2017-08-03 13:30:58 -0700 |
commit | d57ebcd4684ddaf5cb41c53ea086862d065f5462 (patch) | |
tree | 89321264d693a1e485479d856b32b1692b6e5983 /recipes-devtools/clang | |
parent | c1b298c4586ea93f15f85ec20051e927a6e3d735 (diff) | |
download | meta-clang-d57ebcd4684ddaf5cb41c53ea086862d065f5462.tar.gz |
clang: Add -DLLVM_ENABLE_ASSERTIONS=OFF and -DLLVM_ENABLE_EXPENSIVE_CHECKS=OFF
This should speed up clang when compiling other stuff
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'recipes-devtools/clang')
-rw-r--r-- | recipes-devtools/clang/clang_git.bb | 49 |
1 files changed, 27 insertions, 22 deletions
diff --git a/recipes-devtools/clang/clang_git.bb b/recipes-devtools/clang/clang_git.bb index e0e9c21..fb7854c 100644 --- a/recipes-devtools/clang/clang_git.bb +++ b/recipes-devtools/clang/clang_git.bb | |||
@@ -64,36 +64,41 @@ LLVM_TARGETS_TO_BUILD_append = ";${@get_clang_host_arch(bb, d)};${@get_clang_tar | |||
64 | 64 | ||
65 | LLVM_TARGETS_TO_BUILD_TARGET ?= "" | 65 | LLVM_TARGETS_TO_BUILD_TARGET ?= "" |
66 | LLVM_TARGETS_TO_BUILD_TARGET_append ?= "${@get_clang_target_arch(bb, d)}" | 66 | LLVM_TARGETS_TO_BUILD_TARGET_append ?= "${@get_clang_target_arch(bb, d)}" |
67 | 67 | EXTRA_OECMAKE += "-DLLVM_ENABLE_ASSERTIONS=OFF \ | |
68 | EXTRA_OECMAKE="-DLLVM_ENABLE_RTTI=True \ | 68 | -DLLVM_ENABLE_EXPENSIVE_CHECKS=OFF \ |
69 | -DLLVM_ENABLE_EH=True \ | 69 | -DLLVM_ENABLE_PIC=ON \ |
70 | -DLLVM_ENABLE_FFI=ON \ | 70 | -DLLVM_BINDINGS_LIST='' \ |
71 | -DFFI_INCLUDE_DIR=$(pkg-config --variable=includedir libffi) \ | 71 | -DLLVM_ENABLE_FFI=ON \ |
72 | -DCMAKE_SYSTEM_NAME=Linux \ | 72 | -DFFI_INCLUDE_DIR=$(pkg-config --variable=includedir libffi) \ |
73 | -DCMAKE_BUILD_TYPE=Release \ | 73 | -DLLVM_OPTIMIZED_TABLEGEN=ON \ |
74 | -DLLVM_BUILD_EXTERNAL_COMPILER_RT=True \ | 74 | -DLLVM_ENABLE_RTTI=ON \ |
75 | -G Ninja \ | 75 | -DLLVM_ENABLE_EH=ON \ |
76 | -DLLVM_BUILD_EXTERNAL_COMPILER_RT=ON \ | ||
77 | -DCMAKE_SYSTEM_NAME=Linux \ | ||
78 | -DCMAKE_BUILD_TYPE=Release \ | ||
79 | -DBUILD_SHARED_LIBS=OFF \ | ||
80 | -G Ninja \ | ||
76 | " | 81 | " |
77 | 82 | ||
78 | EXTRA_OECMAKE_append_class-native = "\ | 83 | EXTRA_OECMAKE_append_class-native = "\ |
79 | -DLLVM_TARGETS_TO_BUILD='${LLVM_TARGETS_TO_BUILD}' \ | 84 | -DLLVM_TARGETS_TO_BUILD='${LLVM_TARGETS_TO_BUILD}' \ |
80 | " | 85 | " |
81 | EXTRA_OECMAKE_append_class-nativesdk = "\ | 86 | EXTRA_OECMAKE_append_class-nativesdk = "\ |
82 | -DLLVM_TARGETS_TO_BUILD='${LLVM_TARGETS_TO_BUILD}' \ | 87 | -DCMAKE_CROSSCOMPILING:BOOL=ON \ |
83 | -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen \ | 88 | -DLLVM_TARGETS_TO_BUILD='${LLVM_TARGETS_TO_BUILD}' \ |
84 | -DCLANG_TABLEGEN=${STAGING_BINDIR_NATIVE}/clang-tblgen \ | 89 | -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen \ |
90 | -DCLANG_TABLEGEN=${STAGING_BINDIR_NATIVE}/clang-tblgen \ | ||
85 | " | 91 | " |
86 | EXTRA_OECMAKE_append_class-target = "\ | 92 | EXTRA_OECMAKE_append_class-target = "\ |
87 | -DBUILD_SHARED_LIBS=OFF \ | 93 | -DCMAKE_CROSSCOMPILING:BOOL=ON \ |
88 | -DLLVM_BUILD_LLVM_DYLIB=ON \ | 94 | -DLLVM_BUILD_LLVM_DYLIB=ON \ |
89 | -DLLVM_ENABLE_PIC=ON \ | 95 | -DLLVM_LINK_LLVM_DYLIB=ON \ |
90 | -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen \ | 96 | -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen \ |
91 | -DCLANG_TABLEGEN=${STAGING_BINDIR_NATIVE}/clang-tblgen \ | 97 | -DCLANG_TABLEGEN=${STAGING_BINDIR_NATIVE}/clang-tblgen \ |
92 | -DLLVM_TARGETS_TO_BUILD='${LLVM_TARGETS_TO_BUILD_TARGET}' \ | 98 | -DLLVM_TARGETS_TO_BUILD='${LLVM_TARGETS_TO_BUILD_TARGET}' \ |
93 | -DLLVM_TARGET_ARCH=${@get_clang_target_arch(bb, d)} \ | 99 | -DLLVM_TARGET_ARCH=${@get_clang_target_arch(bb, d)} \ |
94 | -DLLVM_DEFAULT_TARGET_TRIPLE=${TARGET_SYS} \ | 100 | -DLLVM_DEFAULT_TARGET_TRIPLE=${TARGET_SYS} \ |
95 | " | 101 | " |
96 | EXTRA_OEMAKE += "REQUIRES_RTTI=1 VERBOSE=1" | ||
97 | 102 | ||
98 | DEPENDS = "zlib libffi libxml2 ninja-native" | 103 | DEPENDS = "zlib libffi libxml2 ninja-native" |
99 | DEPENDS_remove_class-nativesdk = "nativesdk-binutils nativesdk-compiler-rt nativesdk-libcxx nativesdk-llvm-unwind" | 104 | DEPENDS_remove_class-nativesdk = "nativesdk-binutils nativesdk-compiler-rt nativesdk-libcxx nativesdk-llvm-unwind" |