Message ID | 884EA965490E3C4D8E66AEF41E98025006C816@ezex10.ezchip.com |
---|---|
State | Superseded |
Headers | show |
Noam, All, On 2014-02-23 15:41 +0000, Noam Camus spake thusly: [--SNIP--] > Below is the revised patch. > Is it OK? > Is it the right way to bring up the corrections? Please just re-send the patch as you did the first time. Be sure to annotate it as: [PATCH v2] blabla You can do that with: git send-email --annotate [...] [--SNIP--] > diff --git a/toolchain/toolchain-buildroot/Config.in b/toolchain/toolchain-buildroot/Config.in > index cd88889..216f308 100644 > --- a/toolchain/toolchain-buildroot/Config.in > +++ b/toolchain/toolchain-buildroot/Config.in > @@ -69,6 +69,18 @@ config BR2_TOOLCHAIN_BUILDROOT_LIBC > default "glibc" if BR2_TOOLCHAIN_BUILDROOT_EGLIBC > default "glibc" if BR2_TOOLCHAIN_BUILDROOT_GLIBC > > +config BR2_TOOLCHAIN_BUILDROOT_VENDOR > + string "custom toolchain vendor name" > + default "buildroot" > + help > + This option accepts name for vendor field in toolchain tuple. > + The toolchain tuple full format is: > + cpu-vendor-kernel-os > + You may use it in case of custom toolchain. > + e.g. if your gcc depend on this field to make decisions. > + NOTE: "unknown" is not allowed since it may be confused > + with host toolchain. I think Thomas said on IRC that he will have a better wording for the help text. Wait a little bit for his suggestion, before re-sending. Thanks! Regards, Yann E. MORIN.
Dear Noam Camus, On Sun, 23 Feb 2014 15:41:43 +0000, Noam Camus wrote: > +config BR2_TOOLCHAIN_BUILDROOT_VENDOR > + string "custom toolchain vendor name" > + default "buildroot" > + help > + This option accepts name for vendor field in toolchain tuple. > + The toolchain tuple full format is: > + cpu-vendor-kernel-os > + You may use it in case of custom toolchain. > + e.g. if your gcc depend on this field to make decisions. > + NOTE: "unknown" is not allowed since it may be confused > + with host toolchain. A better wording IMO: This option allows to customize the "vendor" part of the toolchain tuple, where the toolchain tuple has the form <cpu>-<vendor>-<kernel>-<os>. The default value, "buildroot", is fine for most cases, except in very specific situations where gcc might make different decisions based on the vendor part of the tuple. The value "unknown" is not allowed as the cross-compiling toolchain might then be confused with the native toolchain when the target and host architecture are identical. If you're not sure, just leave the default "buildroot" value. Thomas
>A better wording IMO: > This option allows to customize the "vendor" part of the > toolchain tuple, where the toolchain tuple has the form > <cpu>-<vendor>-<kernel>-<os>. The default value, "buildroot", > is fine for most cases, except in very specific situations > where gcc might make different decisions based on the vendor > part of the tuple. The value "unknown" is not allowed as the > cross-compiling toolchain might then be confused with the > native toolchain when the target and host architecture are > identical. > If you're not sure, just leave the default "buildroot" value. Thanks It is indeed much better. I will send PATCH V2
==================================================== When the toolchain is custom we can denote that by setting in the triplet the vendor part. This is done through configution, where the default is buildroot. Signed-off-by: Noam Camus <noamc@ezchip.com> --- package/Makefile.in | 12 +++++++++++- toolchain/toolchain-buildroot/Config.in | 12 ++++++++++++ 2 files changed, 23 insertions(+), 1 deletions(-) diff --git a/package/Makefile.in b/package/Makefile.in index eea7043..bdd6889 100644 --- a/package/Makefile.in +++ b/package/Makefile.in @@ -20,8 +20,18 @@ endif MAKE1:=$(HOSTMAKE) -j1 MAKE:=$(HOSTMAKE) $(if $(PARALLEL_JOBS),-j$(PARALLEL_JOBS)) +ifeq ($(BR2_TOOLCHAIN_BUILDROOT_VENDOR),) +VENDOR:=buildroot +else +ifeq ($(BR2_TOOLCHAIN_BUILDROOT_VENDOR),unknown) +$(error You may not provide 'unknown' as vendor to toolchain tuple) +else VENDOR:=$(call qstrip,$(BR2_TOOLCHAIN_BUILDROOT_VENDOR)) +endif +endif + # Compute GNU_TARGET_NAME -GNU_TARGET_NAME=$(ARCH)-buildroot-$(TARGET_OS)-$(LIBC)$(ABI) +GNU_TARGET_NAME=$(ARCH)-$(VENDOR)-$(TARGET_OS)-$(LIBC)$(ABI) # Blackfin FLAT needs uclinux ifeq ($(BR2_bfin)$(BR2_BINFMT_FLAT),yy) diff --git a/toolchain/toolchain-buildroot/Config.in b/toolchain/toolchain-buildroot/Config.in index cd88889..216f308 100644 --- a/toolchain/toolchain-buildroot/Config.in +++ b/toolchain/toolchain-buildroot/Config.in @@ -69,6 +69,18 @@ config BR2_TOOLCHAIN_BUILDROOT_LIBC default "glibc" if BR2_TOOLCHAIN_BUILDROOT_EGLIBC default "glibc" if BR2_TOOLCHAIN_BUILDROOT_GLIBC +config BR2_TOOLCHAIN_BUILDROOT_VENDOR + string "custom toolchain vendor name" + default "buildroot" + help + This option accepts name for vendor field in toolchain tuple. + The toolchain tuple full format is: + cpu-vendor-kernel-os + You may use it in case of custom toolchain. + e.g. if your gcc depend on this field to make decisions. + NOTE: "unknown" is not allowed since it may be confused + with host toolchain. + source "package/uclibc/Config.in" source "package/binutils/Config.in.host"