From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 134.134.136.20, mailfrom: zhijux.fan@intel.com) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by groups.io with SMTP; Tue, 07 May 2019 18:57:05 -0700 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga101.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 07 May 2019 18:57:04 -0700 X-ExtLoop1: 1 Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by orsmga008.jf.intel.com with ESMTP; 07 May 2019 18:57:04 -0700 Received: from FMSMSX109.amr.corp.intel.com (10.18.116.9) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.408.0; Tue, 7 May 2019 18:57:03 -0700 Received: from shsmsx104.ccr.corp.intel.com (10.239.4.70) by fmsmsx109.amr.corp.intel.com (10.18.116.9) with Microsoft SMTP Server (TLS) id 14.3.408.0; Tue, 7 May 2019 18:57:03 -0700 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.129]) by SHSMSX104.ccr.corp.intel.com ([169.254.5.33]) with mapi id 14.03.0415.000; Wed, 8 May 2019 09:57:01 +0800 From: "Fan, ZhijuX" To: "devel@edk2.groups.io" , "leif.lindholm@linaro.org" CC: "afish@apple.com" , "Gao, Liming" , "Feng, Bob C" , "Fan, ZhijuX" Subject: Re: FW: [edk2-devel] [PATCH V2] BaseTools:improve code to support C files with .C suffixes Thread-Topic: FW: [edk2-devel] [PATCH V2] BaseTools:improve code to support C files with .C suffixes Thread-Index: AdUEe7SOF0Lb/xo/QTyWjhkmAT2wu///fFwA//94MtCAAVNuAP/+x+vw Date: Wed, 8 May 2019 01:57:00 +0000 Message-ID: References: <5C1A24BA-648D-4A3F-AE88-034073AB5C13@apple.com> <20190507144002.gq3rdtappd3rupmd@bivouac.eciton.net> In-Reply-To: <20190507144002.gq3rdtappd3rupmd@bivouac.eciton.net> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.0.600.7 dlp-reaction: no-action x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Return-Path: zhijux.fan@intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hi Leif, In AutoGen\GenMake.py. It's around line 917 if File.Ext not in [".c", ".C"] or File.Name =3D=3D "AutoGen.c" there is similar code to check the .C file. The 'File' above refers to the source File.Some source files are named.C Any question, please let me know. Thanks. Best Regards Fan Zhiju > -----Original Message----- > From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of > Leif Lindholm > Sent: Tuesday, May 7, 2019 10:40 PM > To: devel@edk2.groups.io; Fan, ZhijuX > Cc: afish@apple.com; Gao, Liming ; Feng, Bob C > > Subject: Re: FW: [edk2-devel] [PATCH V2] BaseTools:improve code to > support C files with .C suffixes >=20 > Hi Fan Zhiju, >=20 > But where does the string come from that contains a .C suffix? > Is the tool internally converting things to uppercase, or is some source= file in > the build incorrectly named? >=20 > I am asking because it is not clear to me whether the patch resolves a > problem or hides one. >=20 > Best Regards, >=20 > Leif >=20 > On Tue, May 07, 2019 at 03:05:02AM +0000, Fan, ZhijuX wrote: > > This problem has nothing to do with the file system, We just use the > > filename as a string to compare with other strings Our unittest tested > > minplatform, Ovmf. This problem was found when building a platform > > inside Intel. > > We've tested it on Linux and Windows. > > > > Any question, please let me know. Thanks. > > > > Best Regards > > Fan Zhiju > > > > -----Original Message----- > > From: afish@apple.com [mailto:afish@apple.com] > > Sent: Tuesday, May 7, 2019 10:31 AM > > To: devel@edk2.groups.io; Fan, ZhijuX > > Cc: Gao, Liming ; Feng, Bob C > > > > Subject: Re: [edk2-devel] [PATCH V2] BaseTools:improve code to support > > C files with .C suffixes > > > > This brings up a question? Do we tests on a file system that is case s= ensitive? > Is this just lack of a test case? > > > > Thanks, > > > > Andrew Fish > > > > > On May 6, 2019, at 7:22 PM, Fan, ZhijuX wrote= : > > > > > > BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3D1773 > > > > > > Build break if C file suffixes of named .C instead of .c Code not > > > recognize filenames with .C suffixes. > > > > > > This patch adds code to Support both .c file and .C file > > > > > > Cc: Bob Feng > > > Cc: Liming Gao > > > Signed-off-by: Zhiju.Fan > > > --- > > > BaseTools/Source/Python/AutoGen/GenMake.py | 3 ++- > > > 1 file changed, 2 insertions(+), 1 deletion(-) > > > > > > diff --git a/BaseTools/Source/Python/AutoGen/GenMake.py > > > b/BaseTools/Source/Python/AutoGen/GenMake.py > > > index 0e0f9fd9b0..858ddedf8e 100644 > > > --- a/BaseTools/Source/Python/AutoGen/GenMake.py > > > +++ b/BaseTools/Source/Python/AutoGen/GenMake.py > > > @@ -1035,7 +1035,8 @@ cleanlib: > > > CmdTargetDict[CmdSign] =3D "%s %s" % > (CmdTargetDict[CmdSign], SingleCommandList[-1]) > > > Index =3D CommandList.index(Item) > > > CommandList.pop(Index) > > > - if SingleCommandList[-1].endswith("%s%s.c" % (T= AB_SLASH, > CmdSumDict[CmdSign.lstrip('/Fo').rsplit(TAB_SLASH, 1)[0]])): > > > + if SingleCommandList[-1].endswith("%s%s.c" % (T= AB_SLASH, > CmdSumDict[T.Target.SubDir])) or \ > > > + SingleCommandList[-1].endswith("%s%s.C"= % > (TAB_SLASH, CmdSumDict[T.Target.SubDir])): > > > Cpplist =3D CmdCppDict[T.Target.SubDir] > > > Cpplist.insert(0, '$(OBJLIST_%d): $(COMMON_D= EPS)' % > list(self.ObjTargetDict.keys()).index(T.Target.SubDir)) > > > T.Commands[Index] =3D '%s\n\t%s' % (' > > > \\\n\t'.join(Cpplist), CmdTargetDict[CmdSign]) > > > -- > > > 2.14.1.windows.1 > > > > > > > > > > > > > > > > > > > > > > > >=20 >=20