summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYonghong Zhu <yonghong.zhu@intel.com>2016-04-13 13:09:17 +0800
committerHao Wu <hao.a.wu@intel.com>2016-07-13 09:31:40 +0800
commit36e0e269805605fcad316ec50a6c0b77481bdef3 (patch)
tree7679acf052f8342f2f0ff44c33885f0c07b5e441
parentd6cbe6ae5d9aa71b0b8f7a27c548536ba6d18a90 (diff)
downloadedk2-platforms-36e0e269805605fcad316ec50a6c0b77481bdef3.tar.xz
BaseTools: fix PLATFORM_DIR variable value for multiple workspace
when enable the multiple workspace, the PLATFORM_DIR still is $(WORKSPACE)\AnyPkg, even though it is in a PACKAGES_PATH folder. this patch fix this issue to use the real path. 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 017fb1cd4c5e3c8b914eb217ac1760223687dad7)
-rw-r--r--BaseTools/Source/Python/AutoGen/GenMake.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/BaseTools/Source/Python/AutoGen/GenMake.py b/BaseTools/Source/Python/AutoGen/GenMake.py
index a4844bec73..287046a5a8 100644
--- a/BaseTools/Source/Python/AutoGen/GenMake.py
+++ b/BaseTools/Source/Python/AutoGen/GenMake.py
@@ -233,7 +233,7 @@ PLATFORM_NAME = ${platform_name}
PLATFORM_GUID = ${platform_guid}
PLATFORM_VERSION = ${platform_version}
PLATFORM_RELATIVE_DIR = ${platform_relative_directory}
-PLATFORM_DIR = $(WORKSPACE)${separator}${platform_relative_directory}
+PLATFORM_DIR = ${platform_dir}
PLATFORM_OUTPUT_DIR = ${platform_output_directory}
#
@@ -612,6 +612,7 @@ cleanlib:
"platform_version" : self.PlatformInfo.Version,
"platform_relative_directory": self.PlatformInfo.SourceDir,
"platform_output_directory" : self.PlatformInfo.OutputDir,
+ "platform_dir" : self._AutoGenObject.Macros["PLATFORM_DIR"],
"module_name" : self._AutoGenObject.Name,
"module_guid" : self._AutoGenObject.Guid,
@@ -989,7 +990,7 @@ PLATFORM_NAME = ${platform_name}
PLATFORM_GUID = ${platform_guid}
PLATFORM_VERSION = ${platform_version}
PLATFORM_RELATIVE_DIR = ${platform_relative_directory}
-PLATFORM_DIR = $(WORKSPACE)${separator}${platform_relative_directory}
+PLATFORM_DIR = $(platform_dir)
PLATFORM_OUTPUT_DIR = ${platform_output_directory}
#
@@ -1119,6 +1120,7 @@ ${BEGIN}\t-@${create_directory_command}\n${END}\
"platform_version" : self.PlatformInfo.Version,
"platform_relative_directory": self.PlatformInfo.SourceDir,
"platform_output_directory" : self.PlatformInfo.OutputDir,
+ "platform_dir" : self._AutoGenObject.Macros["PLATFORM_DIR"],
"module_name" : self._AutoGenObject.Name,
"module_guid" : self._AutoGenObject.Guid,
@@ -1171,7 +1173,7 @@ PLATFORM_NAME = ${platform_name}
PLATFORM_GUID = ${platform_guid}
PLATFORM_VERSION = ${platform_version}
PLATFORM_FILE = ${platform_file}
-PLATFORM_DIR = $(WORKSPACE)${separator}${platform_relative_directory}
+PLATFORM_DIR = $(platform_dir)
PLATFORM_OUTPUT_DIR = ${platform_output_directory}
#
@@ -1313,6 +1315,7 @@ cleanlib:
"platform_relative_directory": PlatformInfo.SourceDir,
"platform_output_directory" : PlatformInfo.OutputDir,
"platform_build_directory" : PlatformInfo.BuildDir,
+ "platform_dir" : self._AutoGenObject.Macros["PLATFORM_DIR"],
"toolchain_tag" : PlatformInfo.ToolChain,
"build_target" : PlatformInfo.BuildTarget,