diff options
| author | Mark Hatle <mark.hatle@xilinx.com> | 2020-01-31 12:24:23 -0800 |
|---|---|---|
| committer | Mark Hatle <mark.hatle@xilinx.com> | 2020-01-31 15:57:27 -0800 |
| commit | 3a6f68ef34561ae3003cfbfd82d8b175e33e830a (patch) | |
| tree | b1908307d9e52b6179a3b63f69538cb065a06c70 /meta-xilinx-standalone/recipes-core | |
| parent | 193ba57865784c6e36b0e481f4054578a187d3cf (diff) | |
| download | meta-xilinx-3a6f68ef34561ae3003cfbfd82d8b175e33e830a.tar.gz | |
Limit multilib toolchains to symlinks to the main toolchain
Multiple copies of the same binary toolchain will not help with anything,
so limit use to a single (primary) lib toolchain, and then new symlinks
to those toolchains to continue to enable the environment files.
Signed-off-by: Mark Hatle <mark.hatle@xilinx.com>
Diffstat (limited to 'meta-xilinx-standalone/recipes-core')
| -rw-r--r-- | meta-xilinx-standalone/recipes-core/meta/gnu-toolchain-canadian.bb | 25 | ||||
| -rw-r--r-- | meta-xilinx-standalone/recipes-core/packagegroups/packagegroup-cross-canadian.bbappend | 14 |
2 files changed, 39 insertions, 0 deletions
diff --git a/meta-xilinx-standalone/recipes-core/meta/gnu-toolchain-canadian.bb b/meta-xilinx-standalone/recipes-core/meta/gnu-toolchain-canadian.bb new file mode 100644 index 00000000..ca8885b8 --- /dev/null +++ b/meta-xilinx-standalone/recipes-core/meta/gnu-toolchain-canadian.bb | |||
| @@ -0,0 +1,25 @@ | |||
| 1 | inherit cross-canadian | ||
| 2 | |||
| 3 | SUMMARY = "Links to the various GNU toolchains for use with the Xilinx multilib toolchain" | ||
| 4 | PN = "gnu-toolchain-canadian-${TARGET_SYS}" | ||
| 5 | BPN = "gnu-toolchain-canadian" | ||
| 6 | |||
| 7 | LICENSE = "MIT" | ||
| 8 | |||
| 9 | do_install () { | ||
| 10 | if [ "${TARGET_SYS_MULTILIB_ORIGINAL}" != "" -a "${TARGET_SYS_MULTILIB_ORIGINAL}" != "${TARGET_SYS}" ]; then | ||
| 11 | mkdir -p ${D}${bindir} | ||
| 12 | |||
| 13 | # Create a link for each item references by the environment files | ||
| 14 | for each in gcc g++ as ld gdb strip ranlib objcopy objdump readelf ar nm ; do | ||
| 15 | ln -s ../${TARGET_SYS_MULTILIB_ORIGINAL}/${TARGET_SYS_MULTILIB_ORIGINAL}-${each} ${D}${bindir}/${TARGET_SYS}-$each | ||
| 16 | done | ||
| 17 | fi | ||
| 18 | } | ||
| 19 | |||
| 20 | INHIBIT_DEFAULT_DEPS = "1" | ||
| 21 | |||
| 22 | ALLOW_EMPTY_${PN} = "1" | ||
| 23 | FILES_${PN} = "${bindir}" | ||
| 24 | |||
| 25 | PACKAGES = "${PN}" | ||
diff --git a/meta-xilinx-standalone/recipes-core/packagegroups/packagegroup-cross-canadian.bbappend b/meta-xilinx-standalone/recipes-core/packagegroups/packagegroup-cross-canadian.bbappend new file mode 100644 index 00000000..456ec6c1 --- /dev/null +++ b/meta-xilinx-standalone/recipes-core/packagegroups/packagegroup-cross-canadian.bbappend | |||
| @@ -0,0 +1,14 @@ | |||
| 1 | # Avoid installing all of the alternative toolchains | ||
| 2 | # due to multilib enabled in the primary toolchain. | ||
| 3 | |||
| 4 | # Create the links to the multilib toolchain components | ||
| 5 | GNUTCLINKS = "gnu-toolchain-canadian-${TARGET_SYS}" | ||
| 6 | |||
| 7 | # Without the := the eval during do_package is occasionally missing multilibs | ||
| 8 | RDEPENDS_${PN}_xilinx-standalone := " \ | ||
| 9 | ${@all_multilib_tune_values(d, 'GNUTCLINKS')} \ | ||
| 10 | ${BINUTILS} \ | ||
| 11 | ${GCC} \ | ||
| 12 | ${GDB} \ | ||
| 13 | meta-environment-${MACHINE} \ | ||
| 14 | " | ||
