From e52ff6135d7d33ec9e4f61ba00524eb4b0e53555 Mon Sep 17 00:00:00 2001 From: Christopher Larson Date: Thu, 2 Jul 2020 00:23:49 +0500 Subject: [PATCH] gcc-runtime-external: symlink TARGET_SYS, not move There are two cases where TARGET_SYS might not match EXTERNAL_TARGET_SYS. In one case, the external toolchain simply used a different one than we did, and we need to align expectations, but in another, they may not match due to multilib usage, and in such a case we likely need both available. Signed-off-by: Christopher Larson --- recipes-external/gcc/gcc-runtime-external.bb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes-external/gcc/gcc-runtime-external.bb b/recipes-external/gcc/gcc-runtime-external.bb index f859e86..c020682 100644 --- a/recipes-external/gcc/gcc-runtime-external.bb +++ b/recipes-external/gcc/gcc-runtime-external.bb @@ -48,10 +48,10 @@ mkdir_if_no_dest () { } do_install_extra () { - if [ "${TARGET_SYS}" != "${EXTERNAL_TARGET_SYS}" ]; then + if [ "${TARGET_SYS}" != "${EXTERNAL_TARGET_SYS}" ] && [ -z "${MLPREFIX}" ]; then if [ -e "${D}${includedir}/c++/${GCC_VERSION}/${EXTERNAL_TARGET_SYS}" ]; then if ! [ -e "${D}${includedir}/c++/${GCC_VERSION}/${TARGET_SYS}" ]; then - mv -v "${D}${includedir}/c++/${GCC_VERSION}/${EXTERNAL_TARGET_SYS}/." "${D}${includedir}/c++/${GCC_VERSION}/${TARGET_SYS}/" + ln -s ${EXTERNAL_TARGET_SYS} ${D}${includedir}/c++/${GCC_VERSION}/${TARGET_SYS} fi fi fi