From nobody Wed May 1 04:54:48 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) smtp.mailfrom=edk2-devel-bounces@lists.01.org Return-Path: Received: from ml01.01.org (ml01.01.org [198.145.21.10]) by mx.zohomail.com with SMTPS id 1511839145565255.916066713104; Mon, 27 Nov 2017 19:19:05 -0800 (PST) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id DCD342034A783; Mon, 27 Nov 2017 19:14:41 -0800 (PST) Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 21B3F2034A764 for ; Mon, 27 Nov 2017 19:14:39 -0800 (PST) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 27 Nov 2017 19:19:01 -0800 Received: from shwde7172.ccr.corp.intel.com ([10.239.9.15]) by orsmga002.jf.intel.com with ESMTP; 27 Nov 2017 19:19:00 -0800 X-Original-To: edk2-devel@lists.01.org Received-SPF: none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) client-ip=198.145.21.10; envelope-from=edk2-devel-bounces@lists.01.org; helo=ml01.01.org; Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=134.134.136.65; helo=mga03.intel.com; envelope-from=liming.gao@intel.com; receiver=edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.44,466,1505804400"; d="scan'208";a="12730868" From: Liming Gao To: edk2-devel@lists.01.org Date: Tue, 28 Nov 2017 11:18:50 +0800 Message-Id: <1511839132-720-2-git-send-email-liming.gao@intel.com> X-Mailer: git-send-email 2.8.0.windows.1 In-Reply-To: <1511839132-720-1-git-send-email-liming.gao@intel.com> References: <1511839132-720-1-git-send-email-liming.gao@intel.com> Subject: [edk2] [PATCH v2 1/3] BaseTools: Replace ARCH with HOST_ARCH in C Makefile to avoid conflict X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" X-ZohoMail: RSF_4 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" https://bugzilla.tianocore.org/show_bug.cgi?id=3D793 ARCH is too generic. It may cause confuse of target arch or host arch. To be clarified, replace it with HOST_ARCH in BaseTools C Makefile. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao Reviewed-by: Yonghong Zhu =20 --- BaseTools/Source/C/BootSectImage/GNUmakefile | 2 +- BaseTools/Source/C/BrotliCompress/GNUmakefile | 2 +- BaseTools/Source/C/Common/GNUmakefile | 2 +- BaseTools/Source/C/EfiLdrImage/GNUmakefile | 2 +- BaseTools/Source/C/EfiRom/GNUmakefile | 2 +- BaseTools/Source/C/GNUmakefile | 28 ++++++++++++---------= ---- BaseTools/Source/C/GenCrc32/GNUmakefile | 2 +- BaseTools/Source/C/GenFfs/GNUmakefile | 2 +- BaseTools/Source/C/GenFv/GNUmakefile | 2 +- BaseTools/Source/C/GenFw/GNUmakefile | 2 +- BaseTools/Source/C/GenPage/GNUmakefile | 2 +- BaseTools/Source/C/GenSec/GNUmakefile | 2 +- BaseTools/Source/C/GenVtf/GNUmakefile | 2 +- BaseTools/Source/C/GnuGenBootSector/GNUmakefile | 2 +- BaseTools/Source/C/LzmaCompress/GNUmakefile | 2 +- BaseTools/Source/C/Makefile | 2 +- BaseTools/Source/C/Makefiles/footer.makefile | 8 +++---- BaseTools/Source/C/Makefiles/header.makefile | 20 +++++++++--------- BaseTools/Source/C/Makefiles/ms.common | 8 +++---- BaseTools/Source/C/Split/GNUmakefile | 2 +- BaseTools/Source/C/TianoCompress/GNUmakefile | 2 +- BaseTools/Source/C/VfrCompile/GNUmakefile | 2 +- BaseTools/Source/C/VolInfo/GNUmakefile | 2 +- 23 files changed, 51 insertions(+), 51 deletions(-) diff --git a/BaseTools/Source/C/BootSectImage/GNUmakefile b/BaseTools/Sourc= e/C/BootSectImage/GNUmakefile index 5f7cb98..90800a4 100644 --- a/BaseTools/Source/C/BootSectImage/GNUmakefile +++ b/BaseTools/Source/C/BootSectImage/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D BootSectImage diff --git a/BaseTools/Source/C/BrotliCompress/GNUmakefile b/BaseTools/Sour= ce/C/BrotliCompress/GNUmakefile index 368edbd..3426a00 100644 --- a/BaseTools/Source/C/BrotliCompress/GNUmakefile +++ b/BaseTools/Source/C/BrotliCompress/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D Brotli diff --git a/BaseTools/Source/C/Common/GNUmakefile b/BaseTools/Source/C/Com= mon/GNUmakefile index a193557..5cbca9a 100644 --- a/BaseTools/Source/C/Common/GNUmakefile +++ b/BaseTools/Source/C/Common/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 # VPATH =3D .. diff --git a/BaseTools/Source/C/EfiLdrImage/GNUmakefile b/BaseTools/Source/= C/EfiLdrImage/GNUmakefile index 99f786f..75c04ea 100644 --- a/BaseTools/Source/C/EfiLdrImage/GNUmakefile +++ b/BaseTools/Source/C/EfiLdrImage/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D EfiLdrImage diff --git a/BaseTools/Source/C/EfiRom/GNUmakefile b/BaseTools/Source/C/Efi= Rom/GNUmakefile index 433c126..a13111c 100644 --- a/BaseTools/Source/C/EfiRom/GNUmakefile +++ b/BaseTools/Source/C/EfiRom/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D EfiRom diff --git a/BaseTools/Source/C/GNUmakefile b/BaseTools/Source/C/GNUmakefile index 83e188c..53ddb67 100644 --- a/BaseTools/Source/C/GNUmakefile +++ b/BaseTools/Source/C/GNUmakefile @@ -12,40 +12,40 @@ # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IM= PLIED. # =20 -ifndef ARCH +ifndef HOST_ARCH # - # If ARCH is not defined, then we use 'uname -m' to attempt - # try to figure out the appropriate ARCH. + # If HOST_ARCH is not defined, then we use 'uname -m' to attempt + # try to figure out the appropriate HOST_ARCH. # uname_m =3D $(shell uname -m) - $(info Attempting to detect ARCH from 'uname -m': $(uname_m)) + $(info Attempting to detect HOST_ARCH from 'uname -m': $(uname_m)) ifneq (,$(strip $(filter $(uname_m), x86_64 amd64))) - ARCH=3DX64 + HOST_ARCH=3DX64 endif ifeq ($(patsubst i%86,IA32,$(uname_m)),IA32) - ARCH=3DIA32 + HOST_ARCH=3DIA32 endif ifneq (,$(findstring aarch64,$(uname_m))) - ARCH=3DAARCH64 + HOST_ARCH=3DAARCH64 endif ifneq (,$(findstring arm,$(uname_m))) - ARCH=3DARM + HOST_ARCH=3DARM endif - ifndef ARCH - $(info Could not detected ARCH from uname results) - $(error ARCH is not defined!) + ifndef HOST_ARCH + $(info Could not detected HOST_ARCH from uname results) + $(error HOST_ARCH is not defined!) endif - $(info Detected ARCH of $(ARCH) using uname.) + $(info Detected HOST_ARCH of $(HOST_ARCH) using uname.) endif =20 -export ARCH +export HOST_ARCH =20 MAKEROOT =3D . =20 include Makefiles/header.makefile =20 all: makerootdir subdirs $(MAKEROOT)/libs - @echo Finished building BaseTools C Tools with ARCH=3D$(ARCH) + @echo Finished building BaseTools C Tools with HOST_ARCH=3D$(HOST_ARCH) =20 LIBRARIES =3D Common # NON_BUILDABLE_APPLICATIONS =3D GenBootSector BootSectImage diff --git a/BaseTools/Source/C/GenCrc32/GNUmakefile b/BaseTools/Source/C/G= enCrc32/GNUmakefile index 15b4dad..a3b4aa8 100644 --- a/BaseTools/Source/C/GenCrc32/GNUmakefile +++ b/BaseTools/Source/C/GenCrc32/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D GenCrc32 diff --git a/BaseTools/Source/C/GenFfs/GNUmakefile b/BaseTools/Source/C/Gen= Ffs/GNUmakefile index 04f5bb8..af0a27c 100644 --- a/BaseTools/Source/C/GenFfs/GNUmakefile +++ b/BaseTools/Source/C/GenFfs/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D GenFfs diff --git a/BaseTools/Source/C/GenFv/GNUmakefile b/BaseTools/Source/C/GenF= v/GNUmakefile index 58ad16c..008ceb7 100644 --- a/BaseTools/Source/C/GenFv/GNUmakefile +++ b/BaseTools/Source/C/GenFv/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D GenFv diff --git a/BaseTools/Source/C/GenFw/GNUmakefile b/BaseTools/Source/C/GenF= w/GNUmakefile index ec5b872..89b2aa6 100644 --- a/BaseTools/Source/C/GenFw/GNUmakefile +++ b/BaseTools/Source/C/GenFw/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D GenFw diff --git a/BaseTools/Source/C/GenPage/GNUmakefile b/BaseTools/Source/C/Ge= nPage/GNUmakefile index e1eab87..9b5a4d3 100644 --- a/BaseTools/Source/C/GenPage/GNUmakefile +++ b/BaseTools/Source/C/GenPage/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D GenPage diff --git a/BaseTools/Source/C/GenSec/GNUmakefile b/BaseTools/Source/C/Gen= Sec/GNUmakefile index c2d289c..6c8fd44 100644 --- a/BaseTools/Source/C/GenSec/GNUmakefile +++ b/BaseTools/Source/C/GenSec/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D GenSec diff --git a/BaseTools/Source/C/GenVtf/GNUmakefile b/BaseTools/Source/C/Gen= Vtf/GNUmakefile index ff6599f..4eb4cc7 100644 --- a/BaseTools/Source/C/GenVtf/GNUmakefile +++ b/BaseTools/Source/C/GenVtf/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D GenVtf diff --git a/BaseTools/Source/C/GnuGenBootSector/GNUmakefile b/BaseTools/So= urce/C/GnuGenBootSector/GNUmakefile index e9d32f8..350014a 100644 --- a/BaseTools/Source/C/GnuGenBootSector/GNUmakefile +++ b/BaseTools/Source/C/GnuGenBootSector/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D GnuGenBootSector diff --git a/BaseTools/Source/C/LzmaCompress/GNUmakefile b/BaseTools/Source= /C/LzmaCompress/GNUmakefile index 63d7ee0..390a97f 100644 --- a/BaseTools/Source/C/LzmaCompress/GNUmakefile +++ b/BaseTools/Source/C/LzmaCompress/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D LzmaCompress diff --git a/BaseTools/Source/C/Makefile b/BaseTools/Source/C/Makefile index 77d3b97..50be773 100644 --- a/BaseTools/Source/C/Makefile +++ b/BaseTools/Source/C/Makefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH =3D IA32 +HOST_ARCH =3D IA32 =20 !INCLUDE Makefiles\ms.common =20 diff --git a/BaseTools/Source/C/Makefiles/footer.makefile b/BaseTools/Sourc= e/C/Makefiles/footer.makefile index 390873b..0926aa9 100644 --- a/BaseTools/Source/C/Makefiles/footer.makefile +++ b/BaseTools/Source/C/Makefiles/footer.makefile @@ -13,12 +13,12 @@ =20 DEPFILES =3D $(OBJECTS:%.o=3D%.d) =20 -$(MAKEROOT)/libs-$(ARCH): - mkdir -p $(MAKEROOT)/libs-$(ARCH) +$(MAKEROOT)/libs-$(HOST_ARCH): + mkdir -p $(MAKEROOT)/libs-$(HOST_ARCH) =20 .PHONY: install -install: $(MAKEROOT)/libs-$(ARCH) $(LIBRARY) - cp $(LIBRARY) $(MAKEROOT)/libs-$(ARCH) +install: $(MAKEROOT)/libs-$(HOST_ARCH) $(LIBRARY) + cp $(LIBRARY) $(MAKEROOT)/libs-$(HOST_ARCH) =20 $(LIBRARY): $(OBJECTS)=20 $(BUILD_AR) crs $@ $^ diff --git a/BaseTools/Source/C/Makefiles/header.makefile b/BaseTools/Sourc= e/C/Makefiles/header.makefile index 063982b..27aa28b 100644 --- a/BaseTools/Source/C/Makefiles/header.makefile +++ b/BaseTools/Source/C/Makefiles/header.makefile @@ -1,10 +1,10 @@ ## @file # # The makefile can be invoked with -# ARCH =3D x86_64 or x64 for EM64T build -# ARCH =3D ia32 or IA32 for IA32 build -# ARCH =3D ia64 or IA64 for IA64 build -# ARCH =3D Arm or ARM for ARM build +# HOST_ARCH =3D x86_64 or x64 for EM64T build +# HOST_ARCH =3D ia32 or IA32 for IA32 build +# HOST_ARCH =3D ia64 or IA64 for IA64 build +# HOST_ARCH =3D Arm or ARM for ARM build # # Copyright (c) 2007 - 2016, Intel Corporation. All rights reserved.
# This program and the accompanying materials @@ -15,7 +15,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. =20 -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 =20 CYGWIN:=3D$(findstring CYGWIN, $(shell uname -s)) LINUX:=3D$(findstring Linux, $(shell uname -s)) @@ -27,19 +27,19 @@ BUILD_AS ?=3D gcc BUILD_AR ?=3D ar BUILD_LD ?=3D ld LINKER ?=3D $(BUILD_CC) -ifeq ($(ARCH), IA32) +ifeq ($(HOST_ARCH), IA32) ARCH_INCLUDE =3D -I $(MAKEROOT)/Include/Ia32/ endif =20 -ifeq ($(ARCH), X64) +ifeq ($(HOST_ARCH), X64) ARCH_INCLUDE =3D -I $(MAKEROOT)/Include/X64/ endif =20 -ifeq ($(ARCH), ARM) +ifeq ($(HOST_ARCH), ARM) ARCH_INCLUDE =3D -I $(MAKEROOT)/Include/Arm/ endif =20 -ifeq ($(ARCH), AARCH64) +ifeq ($(HOST_ARCH), AARCH64) ARCH_INCLUDE =3D -I $(MAKEROOT)/Include/AArch64/ endif =20 @@ -54,7 +54,7 @@ endif BUILD_LFLAGS =3D BUILD_CXXFLAGS =3D -Wno-unused-result =20 -ifeq ($(ARCH), IA32) +ifeq ($(HOST_ARCH), IA32) # # Snow Leopard is a 32-bit and 64-bit environment. uname -m returns i386,= but gcc defaults=20 # to x86_64. So make sure tools match uname -m. You can manual have a 64-= bit kernal on Snow Leopard diff --git a/BaseTools/Source/C/Makefiles/ms.common b/BaseTools/Source/C/Ma= kefiles/ms.common index 69735e6..a6bfea5 100644 --- a/BaseTools/Source/C/Makefiles/ms.common +++ b/BaseTools/Source/C/Makefiles/ms.common @@ -19,8 +19,8 @@ !ERROR "BASE_TOOLS_PATH is not set! Please run build_tools.bat at first!" !ENDIF =20 -!IFNDEF ARCH -ARCH =3D IA32 +!IFNDEF HOST_ARCH +HOST_ARCH =3D IA32 !ENDIF =20 MAKE =3D nmake -nologo @@ -36,7 +36,7 @@ LIB_PATH =3D $(BASE_TOOLS_PATH)\Lib SYS_BIN_PATH=3D$(EDK_TOOLS_PATH)\Bin SYS_LIB_PATH=3D$(EDK_TOOLS_PATH)\Lib =20 -!IF "$(ARCH)"=3D=3D"IA32" +!IF "$(HOST_ARCH)"=3D=3D"IA32" ARCH_INCLUDE =3D $(SOURCE_PATH)\Include\Ia32 BIN_PATH =3D $(BASE_TOOLS_PATH)\Bin\Win32 LIB_PATH =3D $(BASE_TOOLS_PATH)\Lib\Win32 @@ -44,7 +44,7 @@ SYS_BIN_PATH =3D $(EDK_TOOLS_PATH)\Bin\Win32 SYS_LIB_PATH =3D $(EDK_TOOLS_PATH)\Lib\Win32 !ENDIF =20 -!IF "$(ARCH)"=3D=3D"X64" +!IF "$(HOST_ARCH)"=3D=3D"X64" ARCH_INCLUDE =3D $(SOURCE_PATH)\Include\X64 BIN_PATH =3D $(BASE_TOOLS_PATH)\Bin\Win64 LIB_PATH =3D $(BASE_TOOLS_PATH)\Lib\Win64 diff --git a/BaseTools/Source/C/Split/GNUmakefile b/BaseTools/Source/C/Spli= t/GNUmakefile index e38a01f..a42fe1a 100644 --- a/BaseTools/Source/C/Split/GNUmakefile +++ b/BaseTools/Source/C/Split/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D Split diff --git a/BaseTools/Source/C/TianoCompress/GNUmakefile b/BaseTools/Sourc= e/C/TianoCompress/GNUmakefile index e4f3a69..403b363 100644 --- a/BaseTools/Source/C/TianoCompress/GNUmakefile +++ b/BaseTools/Source/C/TianoCompress/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D TianoCompress diff --git a/BaseTools/Source/C/VfrCompile/GNUmakefile b/BaseTools/Source/C= /VfrCompile/GNUmakefile index 2ebf3e0..b9f8f8c 100644 --- a/BaseTools/Source/C/VfrCompile/GNUmakefile +++ b/BaseTools/Source/C/VfrCompile/GNUmakefile @@ -11,7 +11,7 @@ # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # =20 -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D VfrCompile diff --git a/BaseTools/Source/C/VolInfo/GNUmakefile b/BaseTools/Source/C/Vo= lInfo/GNUmakefile index d5f115a..86929c5 100644 --- a/BaseTools/Source/C/VolInfo/GNUmakefile +++ b/BaseTools/Source/C/VolInfo/GNUmakefile @@ -10,7 +10,7 @@ # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMP= LIED. # -ARCH ?=3D IA32 +HOST_ARCH ?=3D IA32 MAKEROOT ?=3D .. =20 APPNAME =3D VolInfo --=20 2.8.0.windows.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Wed May 1 04:54:48 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) smtp.mailfrom=edk2-devel-bounces@lists.01.org Return-Path: Received: from ml01.01.org (ml01.01.org [198.145.21.10]) by mx.zohomail.com with SMTPS id 1511839147480967.798015047284; Mon, 27 Nov 2017 19:19:07 -0800 (PST) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 1BB942034A786; Mon, 27 Nov 2017 19:14:42 -0800 (PST) Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 1E6612034A771 for ; Mon, 27 Nov 2017 19:14:40 -0800 (PST) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 27 Nov 2017 19:19:02 -0800 Received: from shwde7172.ccr.corp.intel.com ([10.239.9.15]) by orsmga002.jf.intel.com with ESMTP; 27 Nov 2017 19:19:01 -0800 X-Original-To: edk2-devel@lists.01.org Received-SPF: none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) client-ip=198.145.21.10; envelope-from=edk2-devel-bounces@lists.01.org; helo=ml01.01.org; Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=134.134.136.65; helo=mga03.intel.com; envelope-from=liming.gao@intel.com; receiver=edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.44,466,1505804400"; d="scan'208";a="12730875" From: Liming Gao To: edk2-devel@lists.01.org Date: Tue, 28 Nov 2017 11:18:51 +0800 Message-Id: <1511839132-720-3-git-send-email-liming.gao@intel.com> X-Mailer: git-send-email 2.8.0.windows.1 In-Reply-To: <1511839132-720-1-git-send-email-liming.gao@intel.com> References: <1511839132-720-1-git-send-email-liming.gao@intel.com> Subject: [edk2] [PATCH v2 2/3] BaseTools: Update BaseTools top GNUMakefile with the clear dependency X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" X-ZohoMail: RSF_4 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" https://bugzilla.tianocore.org/show_bug.cgi?id=3D786 After GNUmakefile dependency is fixed up, it can make with -j N to enable multiple thread build in base tools C source and save build time. In my linux host machine, make -j 4 to compile BaseTools and save ~60% time. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao Reviewed-by: Yonghong Zhu =20 --- BaseTools/GNUmakefile | 8 +++----- BaseTools/Source/C/GNUmakefile | 11 +++++++++-- 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/BaseTools/GNUmakefile b/BaseTools/GNUmakefile index 790d33a..6325e40 100644 --- a/BaseTools/GNUmakefile +++ b/BaseTools/GNUmakefile @@ -1,7 +1,7 @@ ## @file # GNU/Linux makefile for Base Tools project build. # -# Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.
+# Copyright (c) 2009 - 2017, Intel Corporation. All rights reserved.
# This program and the accompanying materials # are licensed and made available under the terms and conditions of the BS= D License # which accompanies this distribution. The full text of the license may b= e found at @@ -24,12 +24,10 @@ subdirs: $(SUBDIRS) $(SUBDIRS): $(MAKE) -C $@ =20 +Tests: $(SOURCE_SUBDIRS) + .PHONY: $(CLEAN_SUBDIRS) $(CLEAN_SUBDIRS): -$(MAKE) -C $(@:-clean=3D) clean =20 clean: $(CLEAN_SUBDIRS) - -test: - @$(MAKE) -C Tests - diff --git a/BaseTools/Source/C/GNUmakefile b/BaseTools/Source/C/GNUmakefile index 53ddb67..50b6759 100644 --- a/BaseTools/Source/C/GNUmakefile +++ b/BaseTools/Source/C/GNUmakefile @@ -1,7 +1,7 @@ ## @file # GNU/Linux makefile for C tools build. # -# Copyright (c) 2007 - 2012, Intel Corporation. All rights reserved.
+# Copyright (c) 2007 - 2017, Intel Corporation. All rights reserved.
# # This program and the accompanying materials # are licensed and made available under the terms and conditions of the B= SD License @@ -44,10 +44,11 @@ MAKEROOT =3D . =20 include Makefiles/header.makefile =20 -all: makerootdir subdirs $(MAKEROOT)/libs +all: makerootdir subdirs @echo Finished building BaseTools C Tools with HOST_ARCH=3D$(HOST_ARCH) =20 LIBRARIES =3D Common +VFRAUTOGEN =3D VfrCompile/VfrLexer.h # NON_BUILDABLE_APPLICATIONS =3D GenBootSector BootSectImage APPLICATIONS =3D \ GnuGenBootSector \ @@ -70,6 +71,9 @@ APPLICATIONS =3D \ =20 SUBDIRS :=3D $(LIBRARIES) $(APPLICATIONS) =20 +$(LIBRARIES): $(MAKEROOT)/libs +$(APPLICATIONS): $(LIBRARIES) $(MAKEROOT)/bin $(VFRAUTOGEN) + .PHONY: outputdirs makerootdir: -mkdir -p $(MAKEROOT) @@ -83,6 +87,9 @@ $(SUBDIRS): $(patsubst %,%-clean,$(sort $(SUBDIRS))): -$(MAKE) -C $(@:-clean=3D) clean =20 +$(VFRAUTOGEN): VfrCompile/VfrSyntax.g=20 + $(MAKE) -C VfrCompile VfrLexer.h + clean: $(patsubst %,%-clean,$(sort $(SUBDIRS))) =20 clean: localClean --=20 2.8.0.windows.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Wed May 1 04:54:48 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) smtp.mailfrom=edk2-devel-bounces@lists.01.org Return-Path: Received: from ml01.01.org (ml01.01.org [198.145.21.10]) by mx.zohomail.com with SMTPS id 15118391502116.109085046984546; Mon, 27 Nov 2017 19:19:10 -0800 (PST) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 54A9E2034A789; Mon, 27 Nov 2017 19:14:42 -0800 (PST) Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 0FB072034A771 for ; Mon, 27 Nov 2017 19:14:41 -0800 (PST) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 27 Nov 2017 19:19:03 -0800 Received: from shwde7172.ccr.corp.intel.com ([10.239.9.15]) by orsmga002.jf.intel.com with ESMTP; 27 Nov 2017 19:19:03 -0800 X-Original-To: edk2-devel@lists.01.org Received-SPF: none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) client-ip=198.145.21.10; envelope-from=edk2-devel-bounces@lists.01.org; helo=ml01.01.org; Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=134.134.136.65; helo=mga03.intel.com; envelope-from=liming.gao@intel.com; receiver=edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.44,466,1505804400"; d="scan'208";a="12730880" From: Liming Gao To: edk2-devel@lists.01.org Date: Tue, 28 Nov 2017 11:18:52 +0800 Message-Id: <1511839132-720-4-git-send-email-liming.gao@intel.com> X-Mailer: git-send-email 2.8.0.windows.1 In-Reply-To: <1511839132-720-1-git-send-email-liming.gao@intel.com> References: <1511839132-720-1-git-send-email-liming.gao@intel.com> Subject: [edk2] [PATCH v2 3/3] BaseTools: Update C tools top GNUMakefile to adjust tool order X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" X-ZohoMail: RSF_4 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Place the tool that takes much build time at the first. This can improve build performance when make -j N used. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao Reviewed-by: Yonghong Zhu =20 --- BaseTools/Source/C/GNUmakefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/BaseTools/Source/C/GNUmakefile b/BaseTools/Source/C/GNUmakefile index 50b6759..0dc7482 100644 --- a/BaseTools/Source/C/GNUmakefile +++ b/BaseTools/Source/C/GNUmakefile @@ -51,9 +51,10 @@ LIBRARIES =3D Common VFRAUTOGEN =3D VfrCompile/VfrLexer.h # NON_BUILDABLE_APPLICATIONS =3D GenBootSector BootSectImage APPLICATIONS =3D \ + BrotliCompress \ + VfrCompile \ GnuGenBootSector \ BootSectImage \ - BrotliCompress \ EfiLdrImage \ EfiRom \ GenFfs \ @@ -66,8 +67,7 @@ APPLICATIONS =3D \ LzmaCompress \ Split \ TianoCompress \ - VolInfo \ - VfrCompile + VolInfo =20 SUBDIRS :=3D $(LIBRARIES) $(APPLICATIONS) =20 --=20 2.8.0.windows.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel