From: Khem Raj Date: Wed, 22 Oct 2025 06:03:21 +0000 (-0700) Subject: compiler-rt: Remove the need to depend on libgcc X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=02c0579120a25b40359831ba1ed94fd15bcf9bcd;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git compiler-rt: Remove the need to depend on libgcc libgcc is only used in cmake tests for compiler checks which works in contained environment like OE, add depedencies on native version of compiler-rt and libcxx for compiler to use Do not build orc builtins, its only needed for JIT which OE does not use. Signed-off-by: Khem Raj --- diff --git a/meta/recipes-devtools/clang/compiler-rt_git.bb b/meta/recipes-devtools/clang/compiler-rt_git.bb index 8cf11edf85..f42f17e9ba 100644 --- a/meta/recipes-devtools/clang/compiler-rt_git.bb +++ b/meta/recipes-devtools/clang/compiler-rt_git.bb @@ -25,9 +25,8 @@ TUNE_CCARGS:remove = "-no-integrated-as" INHIBIT_DEFAULT_DEPS = "1" -DEPENDS += "libgcc" -DEPENDS:append:class-target = " virtual/cross-c++ ${MLPREFIX}clang-cross-${TARGET_ARCH} virtual/${MLPREFIX}libc gcc-runtime" -DEPENDS:append:class-nativesdk = " virtual/cross-c++ clang-native clang-crosssdk-${SDK_SYS} nativesdk-gcc-runtime" +DEPENDS:append:class-target = " virtual/cross-c++ ${MLPREFIX}clang-cross-${TARGET_ARCH} virtual/${MLPREFIX}libc libcxx-native compiler-rt-native" +DEPENDS:append:class-nativesdk = " virtual/cross-c++ clang-native clang-crosssdk-${SDK_SYS}" DEPENDS:append:class-native = " clang-native" DEPENDS:remove:class-native = "libcxx-native compiler-rt-native" @@ -76,6 +75,8 @@ INSTALL_VER ?= "${MAJOR_VER}.${MINOR_VER}.${PATCH_VER}${VER_SUFFIX}" INSTALL_VER:class-native = "${@oe.utils.trim_version("${PV}", 1)}" EXTRA_OECMAKE += "-DCMAKE_BUILD_TYPE=RelWithDebInfo \ + -DCMAKE_C_COMPILER_WORKS=ON \ + -DCMAKE_CXX_COMPILER_WORKS=ON \ -DCOMPILER_RT_STANDALONE_BUILD=ON \ -DCOMPILER_RT_INCLUDE_TESTS=OFF \ -DCOMPILER_RT_BUILD_XRAY=OFF \ @@ -100,6 +101,7 @@ EXTRA_OECMAKE:append:class-target = "\ -DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON \ -DCMAKE_POSITION_INDEPENDENT_CODE=ON \ -DLLVM_ENABLE_PER_TARGET_RUNTIME_DIR=OFF \ + -DCOMPILER_RT_BUILD_ORC=OFF \ " EXTRA_OECMAKE:append:class-nativesdk = "\ @@ -111,14 +113,13 @@ EXTRA_OECMAKE:append:class-nativesdk = "\ -DCMAKE_C_COMPILER_TARGET=${HOST_SYS} \ -DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON \ -DLLVM_ENABLE_PER_TARGET_RUNTIME_DIR=OFF \ + -DCOMPILER_RT_BUILD_ORC=OFF \ " do_install:append () { if [ "${HF}" = "hf" ]; then mv -f ${D}${nonarch_libdir}/clang/${INSTALL_VER}/lib/linux/libclang_rt.builtins-arm.a \ ${D}${nonarch_libdir}/clang/${INSTALL_VER}/lib/linux/libclang_rt.builtins-armhf.a - mv -f ${D}${nonarch_libdir}/clang/${INSTALL_VER}/lib/linux/liborc_rt-arm.a \ - ${D}${nonarch_libdir}/clang/${INSTALL_VER}/lib/linux/liborc_rt-armhf.a fi }