summaryrefslogtreecommitdiffstats
path: root/BaseTools
diff options
context:
space:
mode:
authorYonghong Zhu <yonghong.zhu@intel.com>2016-05-11 13:46:44 +0800
committerHao Wu <hao.a.wu@intel.com>2016-07-13 09:33:00 +0800
commit50cfd879100c5c3b3b009f252b6b57f724014ec6 (patch)
treeb3a3a48772864a673bc9946041600ade8c680129 /BaseTools
parent5f6184c9617b079722771368d85c63b1721673e3 (diff)
downloadedk2-50cfd879100c5c3b3b009f252b6b57f724014ec6.tar.gz
edk2-50cfd879100c5c3b3b009f252b6b57f724014ec6.tar.bz2
edk2-50cfd879100c5c3b3b009f252b6b57f724014ec6.zip
BaseTools: Fix bug to not mix comment into Asbuilt inf Depex section
in the generated Asbuilt inf would include the driver's complete dependency expression, and it would be wrote as comment format. Original bug is mix the depex expression with real comment in the depex section. this patch is ignore the real comment, and list the depex expression. Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com> (cherry picked from commit 518aebe2f7ab2ca7376f450a07439b5741e65503)
Diffstat (limited to 'BaseTools')
-rw-r--r--BaseTools/Source/Python/AutoGen/AutoGen.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/BaseTools/Source/Python/AutoGen/AutoGen.py b/BaseTools/Source/Python/AutoGen/AutoGen.py
index ae0f8a6e7a..0664101008 100644
--- a/BaseTools/Source/Python/AutoGen/AutoGen.py
+++ b/BaseTools/Source/Python/AutoGen/AutoGen.py
@@ -2812,17 +2812,18 @@ class ModuleAutoGen(AutoGen):
for DepexExpresion in DepexExpresionList:
for key in DepexExpresion.keys():
Arch, ModuleType = key
+ DepexExpr = [x for x in DepexExpresion[key] if not str(x).startswith('#')]
# the type of build module is USER_DEFINED.
# All different DEPEX section tags would be copied into the As Built INF file
# and there would be separate DEPEX section tags
if self.ModuleType.upper() == SUP_MODULE_USER_DEFINED:
if (Arch.upper() == self.Arch.upper()) and (ModuleType.upper() != TAB_ARCH_COMMON):
- DepexList.append({(Arch, ModuleType): DepexExpresion[key][:]})
+ DepexList.append({(Arch, ModuleType): DepexExpr})
else:
if Arch.upper() == TAB_ARCH_COMMON or \
(Arch.upper() == self.Arch.upper() and \
ModuleType.upper() in [TAB_ARCH_COMMON, self.ModuleType.upper()]):
- DepexList.append({(Arch, ModuleType): DepexExpresion[key][:]})
+ DepexList.append({(Arch, ModuleType): DepexExpr})
#the type of build module is USER_DEFINED.
if self.ModuleType.upper() == SUP_MODULE_USER_DEFINED: