From patchwork Tue Apr 15 21:09:37 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jon Loeliger X-Patchwork-Id: 339436 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (unknown [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 88C56140096 for ; Wed, 16 Apr 2014 16:33:30 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id CEDB94BCBF; Wed, 16 Apr 2014 08:33:28 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id kH2L3cy1WfP2; Wed, 16 Apr 2014 08:33:28 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id CFA5A4BCC0; Wed, 16 Apr 2014 08:33:24 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 4A2CF4B9B4 for ; Wed, 16 Apr 2014 00:05:14 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DY9UqTeqcFIR for ; Wed, 16 Apr 2014 00:05:09 +0200 (CEST) X-Greylist: delayed 3311 seconds by postgrey-1.27 at theia; Wed, 16 Apr 2014 00:05:05 CEST X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from aserp1050.oracle.com (aserp1050.oracle.com [141.146.126.70]) by theia.denx.de (Postfix) with ESMTPS id 815664B9B2 for ; Wed, 16 Apr 2014 00:05:05 +0200 (CEST) Received: from aserp1040.oracle.com (aserp1040.oracle.com [141.146.126.69]) by aserp1050.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id s3FL9wwh001888 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 15 Apr 2014 21:09:59 GMT Received: from acsinet21.oracle.com (acsinet21.oracle.com [141.146.126.237]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id s3FL9qFD011354 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 15 Apr 2014 21:09:53 GMT Received: from crmail-aus.us.oracle.com (crmail-aus.us.oracle.com [10.135.216.47]) by acsinet21.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id s3FL9q4i008328 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 15 Apr 2014 21:09:52 GMT Received: from gato.us.oracle.com (gato.us.oracle.com [10.135.216.34]) by crmail-aus.us.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id s3FL9q9n029586; Tue, 15 Apr 2014 16:09:52 -0500 (CDT) Received: (from jloelige@localhost) by gato.us.oracle.com (8.14.4/8.14.4) id s3FL9qug012193; Tue, 15 Apr 2014 16:09:52 -0500 From: Jon Loeliger To: u-boot@lists.denx.de Date: Tue, 15 Apr 2014 16:09:37 -0500 Message-Id: <1397596177-10103-1-git-send-email-jon.loeliger@oracle.com> X-Mailer: git-send-email 1.9.0 X-Source-IP: aserp1040.oracle.com [141.146.126.69] X-Mailman-Approved-At: Wed, 16 Apr 2014 08:33:22 +0200 Cc: trini@ti.com Subject: [U-Boot] [PATCH] build: Use filechk rules to create and update u-boot.lds X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de Prior to this patch, the top-level linker script u-boot.lds used a simple $(call if_changed) check when generated. That mechanism misses cases where a possible include file change induces a change in the u-boot.lds too. This patch converts it to a stronger check using ($call filechk) that will also notice differences in file contents and will catch changes due to pre-processing as well. Signed-off-by: Jon Loeliger --- Makefile | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index b807e5c..dcc42b2 100644 --- a/Makefile +++ b/Makefile @@ -1052,12 +1052,13 @@ depend dep: @echo '*** Warning: make $@ is unnecessary now.' # --------------------------------------------------------------------------- -quiet_cmd_cpp_lds = LDS $@ -cmd_cpp_lds = $(CPP) $(cpp_flags) $(LDPPFLAGS) -ansi -D__ASSEMBLY__ \ - -x assembler-with-cpp -P -o $@ $< +define filechk_ubootlds + ($(CPP) $(cpp_flags) $(LDPPFLAGS) -ansi -D__ASSEMBLY__ \ + -x assembler-with-cpp -P -o - -) +endef u-boot.lds: $(LDSCRIPT) prepare FORCE - $(call if_changed,cpp_lds) + $(call filechk,ubootlds) PHONY += nand_spl nand_spl: prepare