diff options
author | Steven Shi <steven.shi@intel.com> | 2019-05-30 10:31:27 +0800 |
---|---|---|
committer | Feng, Bob C <bob.c.feng@intel.com> | 2019-05-31 19:46:16 +0800 |
commit | 3a0b998bf3b58c74e56caa1ab11e3a0e200e5a77 (patch) | |
tree | d022710333f461b64a0dc1eed86a1eb83af59930 /BaseTools/Source/Python | |
parent | e2afc8ab59c3dc6cf368c339a26840f0869a2356 (diff) | |
download | edk2-3a0b998bf3b58c74e56caa1ab11e3a0e200e5a77.tar.gz edk2-3a0b998bf3b58c74e56caa1ab11e3a0e200e5a77.tar.bz2 edk2-3a0b998bf3b58c74e56caa1ab11e3a0e200e5a77.zip |
BaseTools:Extend the binary cache to support library cache
https://bugzilla.tianocore.org/show_bug.cgi?id=1797
Current binary cache doesn't support to save and restore
the library module. If a driver module cache miss happen,
all its dependency library modules need rebuild which
is very time-consuming. This patch is to extend the binary
cache to support library.
Cc: Liming Gao <liming.gao@intel.com>
Cc: Bob Feng <bob.c.feng@intel.com>
Cc: Christian Rodriguez <christian.rodriguez@intel.com>
Signed-off-by: Steven Shi <steven.shi@intel.com>
Reviewed-by: Bob Feng <bob.c.feng@intel.com>
Diffstat (limited to 'BaseTools/Source/Python')
-rw-r--r-- | BaseTools/Source/Python/AutoGen/AutoGen.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/BaseTools/Source/Python/AutoGen/AutoGen.py b/BaseTools/Source/Python/AutoGen/AutoGen.py index a5bef4f7c6..7b35f837f5 100644 --- a/BaseTools/Source/Python/AutoGen/AutoGen.py +++ b/BaseTools/Source/Python/AutoGen/AutoGen.py @@ -3906,6 +3906,12 @@ class ModuleAutoGen(AutoGen): ModuleFile = path.join(self.OutputDir, self.Name + '.inf')
if os.path.exists(ModuleFile):
shutil.copy2(ModuleFile, FileDir)
+ else:
+ OutputDir = self.OutputDir.replace('\\', '/').strip('/')
+ DebugDir = self.DebugDir.replace('\\', '/').strip('/')
+ for Item in self.CodaTargetList:
+ File = Item.Target.Path.replace('\\', '/').strip('/').replace(DebugDir, '').replace(OutputDir, '').strip('/')
+ self.OutputFile.add(File)
if not self.OutputFile:
Ma = self.BuildDatabase[self.MetaFile, self.Arch, self.BuildTarget, self.ToolChain]
self.OutputFile = Ma.Binaries
|