diff --git a/srcpkgs/llvm10/template b/srcpkgs/llvm10/template index 902ca3f505..62c75d0006 100644 --- a/srcpkgs/llvm10/template +++ b/srcpkgs/llvm10/template @@ -1,7 +1,7 @@ # Template file for 'llvm10' pkgname=llvm10 version=10.0.0 -revision=3 +revision=4 wrksrc="llvm-${version}.src" build_style=cmake configure_args=" @@ -103,8 +103,12 @@ post_patch() { mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld fi # Move lldb files into the llvm source. - if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then - mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb + if [ -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then + if [ "$_lldb_enable" = "yes" ]; then + mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb + else + rm -rf ${XBPS_BUILDDIR}/lldb-${version}.src + fi fi # Move compiler-rt files into the llvm source. if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then @@ -156,6 +160,7 @@ pre_configure() { ppc*) _arch="PowerPC";; esac configure_args+=" -DLLVM_TARGET_ARCH=${_arch}" + configure_args+=" -DLLVM_HOST_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}" configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}" }