From patchwork Sun Jul 9 18:02:36 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= X-Patchwork-Id: 9831853 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id F31D660317 for ; Sun, 9 Jul 2017 18:06:26 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id CEFED25EA6 for ; Sun, 9 Jul 2017 18:06:26 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id ACB7127FB7; Sun, 9 Jul 2017 18:06:26 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D47FC25EA6 for ; Sun, 9 Jul 2017 18:06:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752456AbdGISGZ (ORCPT ); Sun, 9 Jul 2017 14:06:25 -0400 Received: from metis.ext.4.pengutronix.de ([92.198.50.35]:38631 "EHLO metis.ext.4.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752335AbdGISGY (ORCPT ); Sun, 9 Jul 2017 14:06:24 -0400 Received: from dude.hi.pengutronix.de ([2001:67c:670:100:1d::7]) by metis.ext.pengutronix.de with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dUGb1-0002Fl-LB; Sun, 09 Jul 2017 20:06:15 +0200 Received: from ukl by dude.hi.pengutronix.de with local (Exim 4.89) (envelope-from ) id 1dUGaz-0006sm-7T; Sun, 09 Jul 2017 20:06:13 +0200 From: =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= To: Masahiro Yamada , Michal Marek Cc: Ben Hutchings , kernel@pengutronix.de, linux-kbuild@vger.kernel.org Subject: [PATCH v2] kbuild: Enable Large File Support for hostprogs Date: Sun, 9 Jul 2017 20:02:36 +0200 Message-Id: <20170709180236.25184-1-u.kleine-koenig@pengutronix.de> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170629121724.cnv5eymfnlctdifk@pengutronix.de> References: <20170629121724.cnv5eymfnlctdifk@pengutronix.de> MIME-Version: 1.0 X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::7 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kbuild@vger.kernel.org Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This fixes the following build error for me when building on an 32 bit machine using an XFS file system: $ make scripts/basic/fixdep HOSTCC scripts/basic/fixdep fixdep: error fstat'ing depfile: scripts/basic/.fixdep.d: Value too large for defined data type Signed-off-by: Uwe Kleine-König --- Changes since v1: - rebase on current linus/master (conflicts with 9f3f1fd29976 ("kbuild: Add __cc-option macro")) - also add HOST_LFS_CFLAGS to HOSTCXXFLAGS Makefile | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 06ef9947cf7c..7c901e644bf6 100644 --- a/Makefile +++ b/Makefile @@ -294,10 +294,16 @@ CONFIG_SHELL := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \ else if [ -x /bin/bash ]; then echo /bin/bash; \ else echo sh; fi ; fi) +HOST_LFS_CFLAGS := $(shell getconf LFS_CFLAGS) +HOST_LFS_LDFLAGS := $(shell getconf LFS_LDFLAGS) +HOST_LFS_LIBS := $(shell getconf LFS_LIBS) + HOSTCC = gcc HOSTCXX = g++ -HOSTCFLAGS := -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89 -HOSTCXXFLAGS = -O2 +HOSTCFLAGS := -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89 $(HOST_LFS_CFLAGS) +HOSTLDFLAGS := $(HOST_LFS_LDFLAGS) +HOST_LOADLIBES := $(HOST_LFS_LIBS) +HOSTCXXFLAGS := -O2 $(HOST_LFS_CFLAGS) ifeq ($(shell $(HOSTCC) -v 2>&1 | grep -c "clang version"), 1) HOSTCFLAGS += -Wno-unused-value -Wno-unused-parameter \ @@ -408,7 +414,7 @@ KERNELVERSION = $(VERSION)$(if $(PATCHLEVEL),.$(PATCHLEVEL)$(if $(SUBLEVEL),.$(S export VERSION PATCHLEVEL SUBLEVEL KERNELRELEASE KERNELVERSION export ARCH SRCARCH CONFIG_SHELL HOSTCC HOSTCFLAGS CROSS_COMPILE AS LD CC -export CPP AR NM STRIP OBJCOPY OBJDUMP +export CPP AR NM STRIP OBJCOPY OBJDUMP HOSTLDFLAGS HOST_LOADLIBES export MAKE AWK GENKSYMS INSTALLKERNEL PERL PYTHON UTS_MACHINE export HOSTCXX HOSTCXXFLAGS LDFLAGS_MODULE CHECK CHECKFLAGS