|
From: <yi...@us...> - 2012-01-13 05:52:29
|
Revision: 2479
http://edk2-buildtools.svn.sourceforge.net/edk2-buildtools/?rev=2479&view=rev
Author: yingke
Date: 2012-01-13 05:52:23 +0000 (Fri, 13 Jan 2012)
Log Message:
-----------
Add ARCH, FAMILY, TOOL_CHAIN_TAG, TARGET as highest priority macros which can be used in FDF and DSC file.
Signed-off-by: yingke
Reviewed-by: jsu1
Modified Paths:
--------------
trunk/BaseTools/Source/Python/build/build.py
Modified: trunk/BaseTools/Source/Python/build/build.py
===================================================================
--- trunk/BaseTools/Source/Python/build/build.py 2012-01-12 13:11:16 UTC (rev 2478)
+++ trunk/BaseTools/Source/Python/build/build.py 2012-01-13 05:52:23 UTC (rev 2479)
@@ -1809,6 +1809,19 @@
EdkLogger.error("build", OPTION_VALUE_INVALID, "UNI flag must be one of -c or -s")
MyBuild = Build(Target, Workspace, Option)
+ GlobalData.gCommandLineDefines['ARCH'] = ' '.join(MyBuild.ArchList)
+ GlobalData.gCommandLineDefines['TOOL_CHAIN_TAG'] = ' '.join(MyBuild.ToolChainList)
+ FamilyList = []
+ for ToolChain in MyBuild.ToolChainList:
+ Family = 'MSFT'
+ try:
+ Family = MyBuild.ToolDef.ToolsDefTxtDatabase[TAB_TOD_DEFINES_FAMILY][ToolChain]
+ except KeyError:
+ pass
+ if Family not in FamilyList:
+ FamilyList.append(Family)
+ GlobalData.gCommandLineDefines['FAMILY'] = ' '.join(FamilyList)
+ GlobalData.gCommandLineDefines['TARGET'] = ' '.join(MyBuild.BuildTargetList)
MyBuild.Launch()
#MyBuild.DumpBuildData()
except FatalError, X:
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|