From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 192.55.52.151, mailfrom: zailiang.sun@intel.com) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by groups.io with SMTP; Wed, 10 Jul 2019 21:55:51 -0700 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 Jul 2019 21:55:51 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.63,476,1557212400"; d="scan'208";a="249672926" Received: from fmsmsx107.amr.corp.intel.com ([10.18.124.205]) by orsmga001.jf.intel.com with ESMTP; 10 Jul 2019 21:55:50 -0700 Received: from shsmsx101.ccr.corp.intel.com (10.239.4.153) by fmsmsx107.amr.corp.intel.com (10.18.124.205) with Microsoft SMTP Server (TLS) id 14.3.439.0; Wed, 10 Jul 2019 21:55:50 -0700 Received: from shsmsx104.ccr.corp.intel.com ([169.254.5.110]) by SHSMSX101.ccr.corp.intel.com ([169.254.1.134]) with mapi id 14.03.0439.000; Thu, 11 Jul 2019 12:55:48 +0800 From: "Sun, Zailiang" To: "devel@edk2.groups.io" , "Kinney, Michael D" CC: "Qian, Yi" , Gary Lin Subject: Re: [edk2-devel] [edk2-platforms Patch 16/28] Vlv2TbltDevicePkg: Update Linux build scripts Thread-Topic: [edk2-devel] [edk2-platforms Patch 16/28] Vlv2TbltDevicePkg: Update Linux build scripts Thread-Index: AQHVN1KDMsWlMP1NK0qibrpXj3HGPKbE2yZg Date: Thu, 11 Jul 2019 04:55:48 +0000 Message-ID: <7CB7EF03E15B5D48981329A508747A9850C95EC9@SHSMSX104.ccr.corp.intel.com> References: <20190710190516.6012-1-michael.d.kinney@intel.com> <20190710190516.6012-17-michael.d.kinney@intel.com> In-Reply-To: <20190710190516.6012-17-michael.d.kinney@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Return-Path: zailiang.sun@intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-By: Zailiang Sun > -----Original Message----- > From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of > Michael D Kinney > Sent: Thursday, July 11, 2019 3:05 AM > To: devel@edk2.groups.io > Cc: Sun, Zailiang ; Qian, Yi = ; > Gary Lin > Subject: [edk2-devel] [edk2-platforms Patch 16/28] Vlv2TbltDevicePkg: > Update Linux build scripts >=20 > * Do not change WORKSPACE env var. > Assume it is set before running script. > * Access Conf dir relative to WORKSPACE > * Run Build_IFWI.sh from the Vlv2Tbl2DevicePkg dir > * run bld_vlv.sh from same dir as Build_IFWI.sh >=20 > Cc: Zailiang Sun > Cc: Yi Qian > Cc: Gary Lin > Signed-off-by: Michael D Kinney > --- > .../Intel/Vlv2TbltDevicePkg/Build_IFWI.sh | 5 +- > Platform/Intel/Vlv2TbltDevicePkg/bld_vlv.sh | 49 ++++++++++--------- > 2 files changed, 26 insertions(+), 28 deletions(-) >=20 > diff --git a/Platform/Intel/Vlv2TbltDevicePkg/Build_IFWI.sh > b/Platform/Intel/Vlv2TbltDevicePkg/Build_IFWI.sh > index 2a22309f5f..f8954cc9cd 100755 > --- a/Platform/Intel/Vlv2TbltDevicePkg/Build_IFWI.sh > +++ b/Platform/Intel/Vlv2TbltDevicePkg/Build_IFWI.sh > @@ -85,13 +85,10 @@ else > IFWI_Suffix=3D"/S $3" > fi >=20 > -## Go to root directory > -cd ../../.. > - > ## Build BIOS > echo > "=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D" > echo "Build_IFWI: Calling BIOS build Script..." > -./Platform/Intel/$PLATFORM_PACKAGE/bld_vlv.sh $Build_Flags > $Platform_Type $Build_Target > +. bld_vlv.sh $Build_Flags $Platform_Type $Build_Target >=20 > echo > echo Finished Building BIOS. > diff --git a/Platform/Intel/Vlv2TbltDevicePkg/bld_vlv.sh > b/Platform/Intel/Vlv2TbltDevicePkg/bld_vlv.sh > index c68e59398a..aac8534677 100755 > --- a/Platform/Intel/Vlv2TbltDevicePkg/bld_vlv.sh > +++ b/Platform/Intel/Vlv2TbltDevicePkg/bld_vlv.sh > @@ -26,7 +26,6 @@ echo -e $(date) >=20 > ##******************************************************** > ************** > ## Initial Setup >=20 > ##******************************************************** > ************** > -export WORKSPACE=3D$(pwd) > #build_threads=3D($NUMBER_OF_PROCESSORS)+1 > Build_Flags=3D > exitCode=3D0 > @@ -38,31 +37,31 @@ export PLATFORM_PATH=3D$WORKSPACE/edk2- > platforms/Platform/Intel/ > export SILICON_PATH=3D$WORKSPACE/edk2-platforms/Silicon/Intel/ > export BINARY_PATH=3D$WORKSPACE/edk2-non-osi/Silicon/Intel/ > export > PACKAGES_PATH=3D$PLATFORM_PATH:$SILICON_PATH:$BINARY_PATH:$COR > E_PATH > -cd ./edk2 >=20 > ## Clean up previous build files. > -if [ -e $CORE_PATH/EDK2.log ]; then > - rm $CORE_PATH/EDK2.log > +if [ -e $WORKSPACE/EDK2.log ]; then > + rm $WORKSPACE/EDK2.log > fi >=20 > -if [ -e $CORE_PATH/Unitool.log ]; then > - rm $CORE_PATH/Unitool.log > +if [ -e $WORKSPACE/Unitool.log ]; then > + rm $WORKSPACE/Unitool.log > fi >=20 > -if [ -e $CORE_PATH/Conf/target.txt ]; then > - rm $CORE_PATH/Conf/target.txt > +if [ -e $WORKSPACE/Conf/target.txt ]; then > + rm $WORKSPACE/Conf/target.txt > fi >=20 > -if [ -e $CORE_PATH/Conf/tools_def.txt ]; then > - rm $CORE_PATH/Conf/tools_def.txt > +if [ -e $WORKSPACE/Conf/tools_def.txt ]; then > + rm $WORKSPACE/Conf/tools_def.txt > fi >=20 > -if [ -e $CORE_PATH/Conf/build_rule.txt ]; then > - rm $CORE_PATH/Conf/build_rule.txt > +if [ -e $WORKSPACE/Conf/build_rule.txt ]; then > + rm $WORKSPACE/Conf/build_rule.txt > fi >=20 > ## Setup EDK environment. Edksetup puts new copies of target.txt, > tools_def.txt, build_rule.txt in WorkSpace\Conf ## Also run edksetup as > soon as possible to avoid it from changing environment variables we're > overriding > +cd $CORE_PATH > . edksetup.sh BaseTools > make -C BaseTools >=20 > @@ -72,6 +71,8 @@ > PLATFORM_PKG_PATH=3D$PLATFORM_PATH/$PLATFORM_PACKAGE > config_file=3D$PLATFORM_PKG_PATH/PlatformPkgConfig.dsc > auto_config_inc=3D$PLATFORM_PKG_PATH/AutoPlatformCFG.txt >=20 > +cd $PLATFORM_PKG_PATH > + > ## create new AutoPlatformCFG.txt file > if [ -f "$auto_config_inc" ]; then > rm $auto_config_inc > @@ -149,11 +150,11 @@ echo "Ensuring correct build directory is present = for > GenBiosId..." >=20 > echo Modifying Conf files for this build... > ## Remove lines with these tags from target.txt -sed -i > '/^ACTIVE_PLATFORM/d' Conf/target.txt -sed -i '/^TARGET /d' > Conf/target.txt -sed -i '/^TARGET_ARCH/d' Conf/target.txt -sed -i > '/^TOOL_CHAIN_TAG/d' Conf/target.txt -sed -i > '/^MAX_CONCURRENT_THREAD_NUMBER/d' Conf/target.txt > +sed -i '/^ACTIVE_PLATFORM/d' $WORKSPACE/Conf/target.txt sed -i > +'/^TARGET /d' $WORKSPACE/Conf/target.txt sed -i '/^TARGET_ARCH/d' > +$WORKSPACE/Conf/target.txt sed -i '/^TOOL_CHAIN_TAG/d' > +$WORKSPACE/Conf/target.txt sed -i > '/^MAX_CONCURRENT_THREAD_NUMBER/d' > +$WORKSPACE/Conf/target.txt >=20 > gcc_version=3D$(gcc -v 2>&1 | tail -1 | awk '{print $3}') case $gcc_ve= rsion in > @@ -174,15 +175,15 @@ esac >=20 > ACTIVE_PLATFORM=3D$PLATFORM_PKG_PATH/PlatformPkgGcc"$Arch".dsc > export TOOL_CHAIN_TAG=3D$TARGET_TOOLS > -MAX_CONCURRENT_THREAD_NUMBER=3D1 > -echo ACTIVE_PLATFORM =3D $ACTIVE_PLATFORM >> > Conf/target.txt > -echo TARGET =3D $TARGET >> = Conf/target.txt > -echo TOOL_CHAIN_TAG =3D $TOOL_CHAIN_TAG >> > Conf/target.txt > -echo MAX_CONCURRENT_THREAD_NUMBER =3D > $MAX_CONCURRENT_THREAD_NUMBER >> Conf/target.txt > +MAX_CONCURRENT_THREAD_NUMBER=3D8 > +echo ACTIVE_PLATFORM =3D $ACTIVE_PLATFORM >> > $WORKSPACE/Conf/target.txt > +echo TARGET =3D $TARGET >> > $WORKSPACE/Conf/target.txt > +echo TOOL_CHAIN_TAG =3D $TOOL_CHAIN_TAG >> > $WORKSPACE/Conf/target.txt > +echo MAX_CONCURRENT_THREAD_NUMBER =3D > $MAX_CONCURRENT_THREAD_NUMBER >> > +$WORKSPACE/Conf/target.txt > if [ $Arch =3D=3D "IA32" ]; then > - echo TARGET_ARCH =3D IA32 >> = Conf/target.txt > + echo TARGET_ARCH =3D IA32 >> > $WORKSPACE/Conf/target.txt > else > - echo TARGET_ARCH =3D IA32 X64 >> = Conf/target.txt > + echo TARGET_ARCH =3D IA32 X64 >> > $WORKSPACE/Conf/target.txt > fi >=20 >=20 > ##******************************************************** > ************** > -- > 2.21.0.windows.1 >=20 >=20 >=20