Reviewed-by: Steven Shi <steven....@intel.com> > -----Original Message----- > From: Feng, Bob C > Sent: Monday, June 24, 2019 9:51 AM > To: devel@edk2.groups.io > Cc: Gao, Liming <liming....@intel.com>; Shi, Steven <steven....@intel.com>; > Rodriguez, Christian <christian.rodrig...@intel.com>; Feng, Bob C > <bob.c.f...@intel.com> > Subject: [Patch 1/2] BaseTools: refine CreateAsBuiltInf function > > BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1932 > ModuleAutogen.CreateAsBuiltInf IsOnlyCopy parameter > and related function can be moved out of CreateAsBuiltInf, > so that CreateAsBuiltInf is more clean. > > Cc: Liming Gao <liming....@intel.com> > Cc: Steven Shi <steven....@intel.com> > Cc: Christian Rodriguez <christian.rodrig...@intel.com> > Signed-off-by: Bob Feng <bob.c.f...@intel.com> > --- > BaseTools/Source/Python/AutoGen/AutoGen.py | 5 +---- > BaseTools/Source/Python/build/build.py | 6 ++++-- > 2 files changed, 5 insertions(+), 6 deletions(-) > > diff --git a/BaseTools/Source/Python/AutoGen/AutoGen.py > b/BaseTools/Source/Python/AutoGen/AutoGen.py > index f50941d422..45b81ed660 100644 > --- a/BaseTools/Source/Python/AutoGen/AutoGen.py > +++ b/BaseTools/Source/Python/AutoGen/AutoGen.py > @@ -3579,15 +3579,12 @@ class ModuleAutoGen(AutoGen): > fInputfile.close () > return OutputName > > ## Create AsBuilt INF file the module > # > - def CreateAsBuiltInf(self, IsOnlyCopy = False): > + def CreateAsBuiltInf(self): > self.OutputFile = set() > - if IsOnlyCopy and GlobalData.gBinCacheDest: > - self.CopyModuleToCache() > - return > > if self.IsAsBuiltInfCreated: > return > > # Skip INF file generation for libraries > diff --git a/BaseTools/Source/Python/build/build.py > b/BaseTools/Source/Python/build/build.py > index 2dca3c7b34..3ece4d4c61 100644 > --- a/BaseTools/Source/Python/build/build.py > +++ b/BaseTools/Source/Python/build/build.py > @@ -2217,17 +2217,19 @@ class Build(): > all_mod_set = set() > for Module in self.BuildModules: > Module.CreateAsBuiltInf() > all_mod_set.add(Module) > for Module in self.HashSkipModules: > - Module.CreateAsBuiltInf(True) > + if GlobalData.gBinCacheDest: > + Module.CopyModuleToCache() > all_mod_set.add(Module) > for Module in all_mod_set: > for lib in Module.LibraryAutoGenList: > all_lib_set.add(lib) > for lib in all_lib_set: > - lib.CreateAsBuiltInf(True) > + if GlobalData.gBinCacheDest: > + lib.CopyModuleToCache() > all_lib_set.clear() > all_mod_set.clear() > self.BuildModules = [] > self.HashSkipModules = [] > ## Do some clean-up works when error occurred > -- > 2.20.1.windows.1
-=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42734): https://edk2.groups.io/g/devel/message/42734 Mute This Topic: https://groups.io/mt/32187982/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-