From e078edbf99f733c04ec8ca50ff10d2200b6d14d4 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sun, 27 Apr 2014 01:23:07 +0100 Subject: binutils/gcc/gdb: Add TARGET_ARCH to PN for all cross recipes This allows them to co-exist together in the native sysroot, with one set of cross tools per target architecture. (From OE-Core rev: a2c5509520d5c3e082f55844e6545d0309565f8f) Signed-off-by: Richard Purdie --- meta/recipes-devtools/binutils/binutils-cross.inc | 3 +++ meta/recipes-devtools/binutils/binutils-crosssdk_2.24.bb | 2 ++ meta/recipes-devtools/gcc/gcc-common.inc | 2 ++ meta/recipes-devtools/gcc/gcc-cross-canadian.inc | 1 - meta/recipes-devtools/gcc/gcc-cross-initial.inc | 6 ++++-- meta/recipes-devtools/gcc/gcc-cross.inc | 8 +++++--- meta/recipes-devtools/gcc/gcc-crosssdk-initial.inc | 2 ++ meta/recipes-devtools/gcc/gcc-crosssdk.inc | 2 ++ meta/recipes-devtools/gcc/gcc-runtime.inc | 2 +- meta/recipes-devtools/gcc/libgcc-common.inc | 2 +- meta/recipes-devtools/gcc/libgcc-initial.inc | 4 ++-- meta/recipes-devtools/gcc/libgfortran.inc | 2 +- meta/recipes-devtools/gdb/gdb-cross.inc | 3 +++ 13 files changed, 28 insertions(+), 11 deletions(-) (limited to 'meta/recipes-devtools') diff --git a/meta/recipes-devtools/binutils/binutils-cross.inc b/meta/recipes-devtools/binutils/binutils-cross.inc index 300a1d3..fd3d801 100644 --- a/meta/recipes-devtools/binutils/binutils-cross.inc +++ b/meta/recipes-devtools/binutils/binutils-cross.inc @@ -1,6 +1,9 @@ inherit cross PROVIDES = "virtual/${TARGET_PREFIX}binutils" +PN = "binutils-cross-${TARGET_ARCH}" +BPN = "binutils" + INHIBIT_DEFAULT_DEPS = "1" INHIBIT_AUTOTOOLS_DEPS = "1" diff --git a/meta/recipes-devtools/binutils/binutils-crosssdk_2.24.bb b/meta/recipes-devtools/binutils/binutils-crosssdk_2.24.bb index 8af407f..b6d9a21 100644 --- a/meta/recipes-devtools/binutils/binutils-crosssdk_2.24.bb +++ b/meta/recipes-devtools/binutils/binutils-crosssdk_2.24.bb @@ -2,6 +2,8 @@ require binutils-cross_${PV}.bb inherit crosssdk +PN = "binutils-crosssdk-${TARGET_ARCH}" + PROVIDES = "virtual/${TARGET_PREFIX}binutils-crosssdk" SRC_URI += "file://relocatable_sdk.patch" diff --git a/meta/recipes-devtools/gcc/gcc-common.inc b/meta/recipes-devtools/gcc/gcc-common.inc index 1e00249..a96bcaa 100644 --- a/meta/recipes-devtools/gcc/gcc-common.inc +++ b/meta/recipes-devtools/gcc/gcc-common.inc @@ -7,6 +7,8 @@ NATIVEDEPS = "" inherit autotools gettext +BPN = "gcc" + def get_gcc_fpu_setting(bb, d): if d.getVar('ARMPKGSFX_EABI', True) == "hf" and d.getVar('TRANSLATED_TARGET_ARCH', True) == "arm": return "--with-float=hard" diff --git a/meta/recipes-devtools/gcc/gcc-cross-canadian.inc b/meta/recipes-devtools/gcc/gcc-cross-canadian.inc index 8d979b1..307f73c 100644 --- a/meta/recipes-devtools/gcc/gcc-cross-canadian.inc +++ b/meta/recipes-devtools/gcc/gcc-cross-canadian.inc @@ -2,7 +2,6 @@ inherit cross-canadian SUMMARY = "GNU cc and gcc C compilers (cross-canadian for ${TARGET_ARCH} target)" PN = "gcc-cross-canadian-${TRANSLATED_TARGET_ARCH}" -BPN = "gcc" DEPENDS = "virtual/${TARGET_PREFIX}gcc virtual/${HOST_PREFIX}binutils-crosssdk virtual/nativesdk-${HOST_PREFIX}libc-for-gcc nativesdk-gettext" diff --git a/meta/recipes-devtools/gcc/gcc-cross-initial.inc b/meta/recipes-devtools/gcc/gcc-cross-initial.inc index 897e055..5a6da8b 100644 --- a/meta/recipes-devtools/gcc/gcc-cross-initial.inc +++ b/meta/recipes-devtools/gcc/gcc-cross-initial.inc @@ -5,6 +5,8 @@ PACKAGES = "" INHIBIT_AUTOTOOLS_DEPS = "1" INHIBIT_DEFAULT_DEPS = "1" +PN = "gcc-cross-initial-${TARGET_ARCH}" + CROSS_TARGET_SYS_DIR_append = ".${PN}" # This is intended to be a -very- basic config @@ -68,8 +70,8 @@ do_install () { # gcc-runtime installs libgcc into a special location in staging since it breaks doing a standalone build case ${PN} in - *gcc-cross-initial|*gcc-crosssdk-initial) - dest=${D}/${includedir}/gcc-build-internal-initial-${MULTIMACH_TARGET_SYS} + *gcc-cross-initial-${TARGET_ARCH}|*gcc-crosssdk-initial-${TARGET_ARCH}) + dest=${D}/${includedir}/gcc-build-internal-initial-${TARGET_SYS} hardlinkdir . $dest ;; esac diff --git a/meta/recipes-devtools/gcc/gcc-cross.inc b/meta/recipes-devtools/gcc/gcc-cross.inc index 27ebcf6..ef88d3f 100644 --- a/meta/recipes-devtools/gcc/gcc-cross.inc +++ b/meta/recipes-devtools/gcc/gcc-cross.inc @@ -9,6 +9,8 @@ python () { d.setVar("EXTRADEPENDS", "linux-libc-headers") } +PN = "gcc-cross-${TARGET_ARCH}" + require gcc-configure-common.inc EXTRA_OECONF += " --enable-poison-system-directories" @@ -138,7 +140,7 @@ STOP INHIBIT_PACKAGE_STRIP = "1" # Compute how to get from libexecdir to bindir in python (easier than shell) -BINRELPATH = "${@os.path.relpath(d.expand("${STAGING_DIR_NATIVE}${prefix_native}/bin/${MULTIMACH_TARGET_SYS}"), d.expand("${libexecdir}/gcc/${TARGET_SYS}/${BINV}"))}" +BINRELPATH = "${@os.path.relpath(d.expand("${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}"), d.expand("${libexecdir}/gcc/${TARGET_SYS}/${BINV}"))}" do_install () { ( cd ${B}/${TARGET_SYS}/libgcc; oe_runmake 'DESTDIR=${D}' install-unwind_h ) @@ -177,8 +179,8 @@ do_install () { # gcc-runtime installs libgcc into a special location in staging since it breaks doing a standalone build case ${PN} in - *gcc-cross|*gcc-crosssdk) - dest=${D}/${includedir}/gcc-build-internal-${MULTIMACH_TARGET_SYS} + *gcc-cross-${TARGET_ARCH}|*gcc-crosssdk-${TARGET_ARCH}) + dest=${D}/${includedir}/gcc-build-internal-${TARGET_SYS} hardlinkdir . $dest ;; esac diff --git a/meta/recipes-devtools/gcc/gcc-crosssdk-initial.inc b/meta/recipes-devtools/gcc/gcc-crosssdk-initial.inc index c6f74a6..7d2599c 100644 --- a/meta/recipes-devtools/gcc/gcc-crosssdk-initial.inc +++ b/meta/recipes-devtools/gcc/gcc-crosssdk-initial.inc @@ -1,5 +1,7 @@ inherit crosssdk +PN = "gcc-crosssdk-initial-${TARGET_ARCH}" + SYSTEMHEADERS = "${SDKPATHNATIVE}${prefix_nativesdk}/include" SYSTEMLIBS = "${SDKPATHNATIVE}${base_libdir_nativesdk}/" SYSTEMLIBS1 = "${SDKPATHNATIVE}${libdir_nativesdk}/" diff --git a/meta/recipes-devtools/gcc/gcc-crosssdk.inc b/meta/recipes-devtools/gcc/gcc-crosssdk.inc index 5fe0b94..53f880f 100644 --- a/meta/recipes-devtools/gcc/gcc-crosssdk.inc +++ b/meta/recipes-devtools/gcc/gcc-crosssdk.inc @@ -1,5 +1,7 @@ inherit crosssdk +PN = "gcc-crosssdk-${TARGET_ARCH}" + SYSTEMHEADERS = "${SDKPATHNATIVE}${prefix_nativesdk}/include" SYSTEMLIBS = "${SDKPATHNATIVE}${base_libdir_nativesdk}/" SYSTEMLIBS1 = "${SDKPATHNATIVE}${libdir_nativesdk}/" diff --git a/meta/recipes-devtools/gcc/gcc-runtime.inc b/meta/recipes-devtools/gcc/gcc-runtime.inc index 2e82a09..5fd2a8c 100644 --- a/meta/recipes-devtools/gcc/gcc-runtime.inc +++ b/meta/recipes-devtools/gcc/gcc-runtime.inc @@ -20,7 +20,7 @@ RUNTIMETARGET = "libssp libstdc++-v3 libgomp libatomic" do_configure () { export CXX="${CXX} -nostdinc++ -nostdlib++" - mtarget=`echo ${MULTIMACH_TARGET_SYS} | sed -e s#-${SDKPKGSUFFIX}##` + mtarget=`echo ${TARGET_SYS} | sed -e s#-${SDKPKGSUFFIX}##` target=`echo ${TARGET_SYS} | sed -e s#-${SDKPKGSUFFIX}##` hardlinkdir ${STAGING_INCDIR_NATIVE}/gcc-build-internal-$mtarget ${B} for d in libgcc ${RUNTIMETARGET}; do diff --git a/meta/recipes-devtools/gcc/libgcc-common.inc b/meta/recipes-devtools/gcc/libgcc-common.inc index b30bcfe..c81a80c 100644 --- a/meta/recipes-devtools/gcc/libgcc-common.inc +++ b/meta/recipes-devtools/gcc/libgcc-common.inc @@ -3,7 +3,7 @@ BPN = "libgcc" INHIBIT_DEFAULT_DEPS = "1" do_configure () { - target=`echo ${MULTIMACH_TARGET_SYS} | sed -e s#-${SDKPKGSUFFIX}##` + target=`echo ${TARGET_SYS} | sed -e s#-${SDKPKGSUFFIX}##` install -d ${D}${base_libdir} ${D}${libdir} hardlinkdir ${STAGING_INCDIR_NATIVE}/${LIBGCCBUILDTREENAME}$target/ ${B} mkdir -p ${B}/${BPN} diff --git a/meta/recipes-devtools/gcc/libgcc-initial.inc b/meta/recipes-devtools/gcc/libgcc-initial.inc index 2ba27a8..27e2e45 100644 --- a/meta/recipes-devtools/gcc/libgcc-initial.inc +++ b/meta/recipes-devtools/gcc/libgcc-initial.inc @@ -2,8 +2,8 @@ require libgcc-common.inc DEPENDS = "virtual/${TARGET_PREFIX}gcc-initial" -STAGINGCC = "gcc-cross-initial" -STAGINGCC_class-nativesdk = "gcc-crosssdk-initial" +STAGINGCC = "gcc-cross-initial-${TARGET_ARCH}" +STAGINGCC_class-nativesdk = "gcc-crosssdk-initial-${TARGET_ARCH}" PATH_prepend = "${STAGING_BINDIR_TOOLCHAIN}.${STAGINGCC}:" PACKAGES = "" diff --git a/meta/recipes-devtools/gcc/libgfortran.inc b/meta/recipes-devtools/gcc/libgfortran.inc index 30e5ffe..7bf4121 100644 --- a/meta/recipes-devtools/gcc/libgfortran.inc +++ b/meta/recipes-devtools/gcc/libgfortran.inc @@ -5,7 +5,7 @@ EXTRA_OECONF_PATHS = " \ --with-build-sysroot=${STAGING_DIR_TARGET}" do_configure () { - mtarget=`echo ${MULTIMACH_TARGET_SYS} | sed -e s#-${SDKPKGSUFFIX}##` + mtarget=`echo ${TARGET_SYS} | sed -e s#-${SDKPKGSUFFIX}##` target=`echo ${TARGET_SYS} | sed -e s#-${SDKPKGSUFFIX}##` hardlinkdir ${STAGING_INCDIR_NATIVE}/gcc-build-internal-$mtarget ${B} diff --git a/meta/recipes-devtools/gdb/gdb-cross.inc b/meta/recipes-devtools/gdb/gdb-cross.inc index 6fc98ff..cb99b06 100644 --- a/meta/recipes-devtools/gdb/gdb-cross.inc +++ b/meta/recipes-devtools/gdb/gdb-cross.inc @@ -8,6 +8,9 @@ EXTRA_OECONF += "--without-python" GDBPROPREFIX = "" +PN = "gdb-cross-${TARGET_ARCH}" +BPN = "gdb" + inherit cross inherit gettext -- cgit v1.1