summaryrefslogtreecommitdiffstats
path: root/BaseTools/Source/Python/AutoGen/PlatformAutoGen.py
diff options
context:
space:
mode:
authorFeng, Bob C <bob.c.feng@intel.com>2019-08-16 13:52:46 +0800
committerFeng, Bob C <bob.c.feng@intel.com>2019-08-19 09:06:14 +0800
commit76e12fa33416f3133c41c6e396a69abbe32f2edb (patch)
tree3c2414bd1317922434e584700e1b3d8ec67bcb77 /BaseTools/Source/Python/AutoGen/PlatformAutoGen.py
parent5726bdd9a2dfd188a96129e8c00721f34cf3906e (diff)
downloadedk2-76e12fa33416f3133c41c6e396a69abbe32f2edb.tar.gz
edk2-76e12fa33416f3133c41c6e396a69abbe32f2edb.tar.bz2
edk2-76e12fa33416f3133c41c6e396a69abbe32f2edb.zip
BaseTools: Fixed issue of incorrect Module Unique Name
https://bugzilla.tianocore.org/show_bug.cgi?id=2088 If there are more than one override instance for a same module, the Module Unique Name is generated incorrectly. Cc: Liming Gao <liming.gao@intel.com> Cc: Steven Shi <steven.shi@intel.com> Signed-off-by: Bob Feng <bob.c.feng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
Diffstat (limited to 'BaseTools/Source/Python/AutoGen/PlatformAutoGen.py')
-rw-r--r--BaseTools/Source/Python/AutoGen/PlatformAutoGen.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/BaseTools/Source/Python/AutoGen/PlatformAutoGen.py b/BaseTools/Source/Python/AutoGen/PlatformAutoGen.py
index 4abfc6c29d..dd629ba2fa 100644
--- a/BaseTools/Source/Python/AutoGen/PlatformAutoGen.py
+++ b/BaseTools/Source/Python/AutoGen/PlatformAutoGen.py
@@ -1366,14 +1366,15 @@ class PlatformAutoGen(AutoGen):
UniqueName[Module.BaseName] = set()
UniqueName[Module.BaseName].add((self.ModuleGuid(Module),Module.MetaFile))
for module_paths in ModuleNameDict.values():
- if len(module_paths) > 1 and len(set(module_paths))>1:
+ if len(set(module_paths))>1:
samemodules = list(set(module_paths))
EdkLogger.error("build", FILE_DUPLICATED, 'Modules have same BaseName and FILE_GUID:\n'
' %s\n %s' % (samemodules[0], samemodules[1]))
for name in UniqueName:
Guid_Path = UniqueName[name]
if len(Guid_Path) > 1:
- retVal[name] = '%s_%s' % (name,Guid_Path.pop()[0])
+ for guid,mpath in Guid_Path:
+ retVal[(name,mpath)] = '%s_%s' % (name,guid)
return retVal
## Expand * in build option key
#