diff --git a/scripts/helpers/eosio.sh b/scripts/helpers/eosio.sh index f71d9d90f00..7f114b310dd 100755 --- a/scripts/helpers/eosio.sh +++ b/scripts/helpers/eosio.sh @@ -281,12 +281,15 @@ function build-clang() { if $BUILD_CLANG; then echo "${COLOR_CYAN}[Ensuring Clang support]${COLOR_NC}" if [[ ! -d $CLANG_ROOT ]]; then + if [[ $ARCH == "Darwin" ]]; then + export CMAKE_XTRA_FLAGS="-DCOMPILER_RT_INCLUDE_TESTS=0 -DCOMPILER_RT_BUILD_SANITIZERS=0 -DCOMPILER_RT_BUILD_XRAY=0" + fi execute bash -c "cd ${TEMP_DIR} \ && rm -rf clang10 \ && git clone --single-branch --branch $PINNED_COMPILER_BRANCH https://github.com/llvm/llvm-project clang10 \ && cd clang10 \ && mkdir build && cd build \ - && ${CMAKE} -G 'Unix Makefiles' -DCMAKE_INSTALL_PREFIX='${CLANG_ROOT}' -DLLVM_ENABLE_PROJECTS='lld;polly;clang;clang-tools-extra;libcxx;libcxxabi;libunwind;compiler-rt' -DLLVM_BUILD_LLVM_DYLIB=ON -DLLVM_ENABLE_RTTI=ON -DLLVM_INCLUDE_DOCS=OFF -DLLVM_TARGETS_TO_BUILD=host -DCMAKE_BUILD_TYPE=Release ../llvm \ + && ${CMAKE} -G 'Unix Makefiles' -DCMAKE_INSTALL_PREFIX='${CLANG_ROOT}' -DLLVM_ENABLE_PROJECTS='lld;polly;clang;clang-tools-extra;libcxx;libcxxabi;libunwind;compiler-rt' -DLLVM_BUILD_LLVM_DYLIB=ON -DLLVM_ENABLE_RTTI=ON -DLLVM_INCLUDE_DOCS=OFF -DLLVM_TARGETS_TO_BUILD=host -DCMAKE_BUILD_TYPE=Release ${CMAKE_XTRA_FLAGS} ../llvm \ && make -j${JOBS} \ && make install" echo " - Clang 10 successfully installed @ ${CLANG_ROOT}"