summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorYann E. MORIN <yann.morin.1998@free.fr>2017-03-14 11:30:31 -0700
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>2017-03-26 15:49:12 +0200
commitbcecbed654c517cf9349c7e108d014a0831d3aed (patch)
treed0d5ce9e7a3d0d7360720390163c2d01834faa25 /arch
parent8efa2d8de920228130235ad6c0a2aeb19a6ae4be (diff)
downloadbuildroot-bcecbed654c517cf9349c7e108d014a0831d3aed.tar.gz
buildroot-bcecbed654c517cf9349c7e108d014a0831d3aed.zip
arch/xtensa: add definitions for the Xtensa overlay
Currently, we have four packages that need to use the Xtensa overlay: binutils, gcc-initial, gcc-final and gdb. However, they all use three different ways to check for, and use the overlay. Furthermore, two of them define the same variable: XTENSA_CORE_NAME is defined both by binutils and gdb In order to sanitise that, have the Xtensa architecture export the appropriate variables: the name of the core and the path to the overlay tarball. Packages can then check and use those variables. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/arch.mk.xtensa15
1 files changed, 15 insertions, 0 deletions
diff --git a/arch/arch.mk.xtensa b/arch/arch.mk.xtensa
new file mode 100644
index 0000000000..7c8beb194d
--- /dev/null
+++ b/arch/arch.mk.xtensa
@@ -0,0 +1,15 @@
+################################################################################
+# Those two variables can be used by packages that need to extract the overlay.
+#
+# ARCH_XTENSA_CORE_NAME is the name of the Xtensa core; empty if none or the
+# standard 'fsf' core.
+# ARCH_XTENSA_OVERLAY_TAR is the path to the overlay tarball; only valid when
+# ARCH_XTENSA_CORE_NAME is not empty.
+#
+# Example:
+# ifneq ($(ARCH_XTENSA_CORE_NAME),)
+# tar xf $(ARCH_XTENSA_OVERLAY_TAR) -C $(@D) --strip-components=1 gcc
+# endif
+################################################################################
+ARCH_XTENSA_CORE_NAME = $(call qstrip,$(BR2_XTENSA_CORE_NAME))
+ARCH_XTENSA_OVERLAY_TAR = $(call qstrip,$(BR2_XTENSA_OVERLAY_DIR))/xtensa_$(ARCH_XTENSA_CORE_NAME).tar
OpenPOWER on IntegriCloud