]> git.proxmox.com Git - mirror_edk2.git/commitdiff
BaseTools: GlobalData.gConfDirectory is None when run GenFds
authorFeng, YunhuaX </o=Intel/ou=Exchange Administrative Group (FYDIBOHF23SPDLT)/cn=Recipients/cn=Feng, YunhuaX4e1>
Thu, 1 Mar 2018 02:23:14 +0000 (10:23 +0800)
committerYonghong Zhu <yonghong.zhu@intel.com>
Thu, 1 Mar 2018 23:59:22 +0000 (07:59 +0800)
When run GenFds,  GlobalData.gConfDirectory is None, On Linux
self._ToolChainFamily default Value is "MSFT", and then
generate the wrong PcdValueInit Makefile

Cc: Liming Gao <liming.gao@intel.com>
Cc: Yonghong Zhu <yonghong.zhu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Yunhua Feng <yunhuax.feng@intel.com>
Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
BaseTools/Source/Python/GenFds/GenFds.py

index cd705630a3b2b81966c4534b7b0298adda71d684..9ca7c8706a9a7c69d2c2a83a1b1cce04039d32a3 100644 (file)
@@ -1,7 +1,7 @@
 ## @file\r
 # generate flash image\r
 #\r
-#  Copyright (c) 2007 - 2017, Intel Corporation. All rights reserved.<BR>\r
+#  Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.<BR>\r
 #\r
 #  This program and the accompanying materials\r
 #  are licensed and made available under the terms and conditions of the BSD License\r
@@ -164,6 +164,8 @@ def main():
                 # Get standard WORKSPACE/Conf, use the absolute path to the WORKSPACE/Conf\r
                 ConfDirectoryPath = mws.join(GenFdsGlobalVariable.WorkSpaceDir, 'Conf')\r
         GenFdsGlobalVariable.ConfDir = ConfDirectoryPath\r
+        if not GlobalData.gConfDirectory:\r
+            GlobalData.gConfDirectory = GenFdsGlobalVariable.ConfDir\r
         BuildConfigurationFile = os.path.normpath(os.path.join(ConfDirectoryPath, "target.txt"))\r
         if os.path.isfile(BuildConfigurationFile) == True:\r
             TargetTxt = TargetTxtClassObject.TargetTxtClassObject()\r