From patchwork Sat Jul 13 22:27:24 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Petazzoni X-Patchwork-Id: 258844 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from fraxinus.osuosl.org (fraxinus.osuosl.org [140.211.166.137]) by ozlabs.org (Postfix) with ESMTP id AA8292C0150 for ; Sun, 14 Jul 2013 08:28:06 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id D9B3192586; Sat, 13 Jul 2013 22:28:05 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id scbFNvvayd2i; Sat, 13 Jul 2013 22:28:04 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 998289273C; Sat, 13 Jul 2013 22:28:01 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from silver.osuosl.org (silver.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 769F91BFA28 for ; Sat, 13 Jul 2013 22:28:02 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 0030931D2E for ; Sat, 13 Jul 2013 22:27:58 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id c69QBbY4d2DD for ; Sat, 13 Jul 2013 22:27:57 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail.free-electrons.com (mail.free-electrons.com [94.23.35.102]) by silver.osuosl.org (Postfix) with ESMTP id 9806931D16 for ; Sat, 13 Jul 2013 22:27:57 +0000 (UTC) Received: by mail.free-electrons.com (Postfix, from userid 106) id 458867D7; Sun, 14 Jul 2013 00:27:56 +0200 (CEST) Received: from localhost (unknown [37.161.184.84]) by mail.free-electrons.com (Postfix) with ESMTPSA id 7A479768 for ; Sun, 14 Jul 2013 00:27:55 +0200 (CEST) From: Thomas Petazzoni To: buildroot@uclibc.org Date: Sun, 14 Jul 2013 00:27:24 +0200 Message-Id: <1373754468-7527-2-git-send-email-thomas.petazzoni@free-electrons.com> X-Mailer: git-send-email 1.8.1.2 In-Reply-To: <1373754468-7527-1-git-send-email-thomas.petazzoni@free-electrons.com> References: <1373754468-7527-1-git-send-email-thomas.petazzoni@free-electrons.com> Subject: [Buildroot] [PATCHv2 01/25] gcc: use BR2_EXTRA_GCC_CONFIG_OPTIONS in gcc-initial and gcc-intermediate X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net When refactoring the internal toolchain backend logic, the code was changed to pass the custom configure options given through BR2_EXTRA_GCC_CONFIG_OPTIONS only for the gcc final pass, with the idea that we're only interested by user customization for the final compiler. However, the beaglebone_defconfig was passing --with-float=hard --with-fpu=vfpv3-d16 as BR2_EXTRA_GCC_CONFIG_OPTIONS, and since the refactoring, it was causing build failures of the beaglebone_defconfig (with messages saying that Busybox is built to use VFP arguments, but libc/libm are not). This is due to the fact that the gcc intermediate, which is used to build the C library, wasn't built to generate hard float, while the final compiler was generating hard float. So, we get back to the original situation where the options in BR2_EXTRA_GCC_CONFIG_OPTIONS are passed to all of the compiler passes. Of course, the specific case of hard float will be fixed by following patches in this area, but the idea still remains: the three gcc should have the same options, if those options affected the ABI of the generated code. Signed-off-by: Thomas Petazzoni --- package/gcc/Config.in.host | 4 +++- package/gcc/gcc-initial/gcc-initial.mk | 3 ++- package/gcc/gcc-intermediate/gcc-intermediate.mk | 3 ++- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/package/gcc/Config.in.host b/package/gcc/Config.in.host index 0836f9f..a529d14 100644 --- a/package/gcc/Config.in.host +++ b/package/gcc/Config.in.host @@ -88,7 +88,9 @@ config BR2_EXTRA_GCC_CONFIG_OPTIONS string "Additional gcc options" default "" help - Any additional gcc configure options you may want to include.... + Any additional gcc configure options you may want to + include. Those options are applied for all of the gcc + initial, gcc intermediate and gcc final passes. config BR2_INSTALL_OBJC bool "Build/install Objective-C compiler and runtime?" diff --git a/package/gcc/gcc-initial/gcc-initial.mk b/package/gcc/gcc-initial/gcc-initial.mk index 05c956a..e468419 100644 --- a/package/gcc/gcc-initial/gcc-initial.mk +++ b/package/gcc/gcc-initial/gcc-initial.mk @@ -31,7 +31,8 @@ HOST_GCC_INITIAL_CONF_OPT = \ --without-headers \ --with-newlib \ --disable-largefile \ - --disable-nls + --disable-nls \ + $(call qstrip,$(BR2_EXTRA_GCC_CONFIG_OPTIONS)) HOST_GCC_INITIAL_MAKE_OPT = all-gcc HOST_GCC_INITIAL_INSTALL_OPT = install-gcc diff --git a/package/gcc/gcc-intermediate/gcc-intermediate.mk b/package/gcc/gcc-intermediate/gcc-intermediate.mk index 5460000..a666025 100644 --- a/package/gcc/gcc-intermediate/gcc-intermediate.mk +++ b/package/gcc/gcc-intermediate/gcc-intermediate.mk @@ -30,7 +30,8 @@ HOST_GCC_INTERMEDIATE_CONF_OPT = \ $(HOST_GCC_COMMON_CONF_OPT) \ --enable-languages=c \ --disable-largefile \ - --disable-nls + --disable-nls \ + $(call qstrip,$(BR2_EXTRA_GCC_CONFIG_OPTIONS)) HOST_GCC_INTERMEDIATE_MAKE_OPT = all-gcc ifeq ($(BR2_GCC_SUPPORTS_FINEGRAINEDMTUNE),y)