]> git.proxmox.com Git - mirror_edk2.git/commitdiff
BaseTools: Copy "MODULE_UNI_FILE" file into OUTPUT directory
authorYonghong Zhu <yonghong.zhu@intel.com>
Thu, 13 Apr 2017 06:37:40 +0000 (14:37 +0800)
committerYonghong Zhu <yonghong.zhu@intel.com>
Sat, 24 Jun 2017 14:59:11 +0000 (22:59 +0800)
Current the "MODULE_UNI_FILE" item defined in the [Defines] section will
be copied into As Built INF file, but tool doesn't copy the real file into
same directory with the As Built INF file.

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>
BaseTools/Source/Python/AutoGen/AutoGen.py

index 356eb213100ac8bd170d855658a2a4b726b5b1af..e05bf479ff837d13916b22a86caed8a08a86ca0f 100644 (file)
@@ -3855,6 +3855,11 @@ class ModuleAutoGen(AutoGen):
           'libraryclasses_item'               : []\r
         }\r
 \r
+        if 'MODULE_UNI_FILE' in MDefs:\r
+            UNIFile = os.path.join(self.MetaFile.Dir, MDefs['MODULE_UNI_FILE'])\r
+            if os.path.isfile(UNIFile):\r
+                shutil.copy2(UNIFile, self.OutputDir)\r
+\r
         if self.AutoGenVersion > int(gInfSpecVersion, 0):\r
             AsBuiltInfDict['module_inf_version'] = '0x%08x' % self.AutoGenVersion\r
         else:\r