]> git.proxmox.com Git - mirror_edk2.git/commitdiff
BaseTools: Enhance binary file in [Binaries] section use relative path
authorYonghong Zhu <yonghong.zhu@intel.com>
Mon, 22 Jan 2018 09:55:17 +0000 (17:55 +0800)
committerYonghong Zhu <yonghong.zhu@intel.com>
Tue, 23 Jan 2018 08:19:41 +0000 (16:19 +0800)
Enhance the binary file in Asbuilt inf file [Binaries] section use
relative path.

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

index 157ecfb395fb8a1d3b4f4da24abb745f6360bc71..d4d90a902d083a4aeeebd5efddf769b838e4611a 100644 (file)
@@ -4153,6 +4153,8 @@ class ModuleAutoGen(AutoGen):
             File = Item.Target.Path.replace('\\', '/').strip('/').replace(DebugDir, '').strip('/')\r
             if File not in self.OutputFile:\r
                 self.OutputFile.append(File)\r
+            if os.path.isabs(File):\r
+                File = File.replace('\\', '/').strip('/').replace(OutputDir, '').strip('/')\r
             if Item.Target.Ext.lower() == '.aml':\r
                 AsBuiltInfDict['binary_item'] += ['ASL|' + File]\r
             elif Item.Target.Ext.lower() == '.acpi':\r