BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1692

Change part of the hash error handling to invalidate hashes in the
cache destination not the cache source.

Signed-off-by: Christian Rodriguez <[email protected]>
Cc: Bob Feng <[email protected]>
Cc: Liming Gao <[email protected]>
Cc: Yonghong Zhu <[email protected]>
---
 BaseTools/Source/Python/build/build.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/BaseTools/Source/Python/build/build.py 
b/BaseTools/Source/Python/build/build.py
index 71478b7268..7271570d29 100644
--- a/BaseTools/Source/Python/build/build.py
+++ b/BaseTools/Source/Python/build/build.py
@@ -1165,8 +1165,8 @@ class Build():
                     os.remove(ModuleHashFile)
 
             # Remove .hash file from cache
-            if GlobalData.gBinCacheSource:
-                FileDir = path.join(GlobalData.gBinCacheSource, 
moduleAutoGenObj.Arch, moduleAutoGenObj.SourceDir, 
moduleAutoGenObj.MetaFile.BaseName)
+            if GlobalData.gBinCacheDest:
+                FileDir = path.join(GlobalData.gBinCacheDest, 
moduleAutoGenObj.Arch, moduleAutoGenObj.SourceDir, 
moduleAutoGenObj.MetaFile.BaseName)
                 HashFile = path.join(FileDir, moduleAutoGenObj.Name + '.hash')
                 if os.path.exists(HashFile):
                     os.remove(HashFile)
-- 
2.19.1.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#39189): https://edk2.groups.io/g/devel/message/39189
Mute This Topic: https://groups.io/mt/31204490/21656
Group Owner: [email protected]
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to