mirror of https://github.com/acidanthera/audk.git
For stand-alone build, generate Platform_build.xml and call prebuild firstly.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@1532 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
73d9b1c494
commit
2a9060e294
|
@ -155,7 +155,7 @@ public class GenBuildThread implements Runnable {
|
|||
genBuildTask.perform();
|
||||
} catch (BuildException be) {
|
||||
|
||||
EdkLog.log("GenBuild", EdkLog.EDK_ALWAYS, moduleId + " with Arch " + arch +" build error. \n" + be.getMessage());
|
||||
EdkLog.log("GenBuild", EdkLog.EDK_ALWAYS, fpdModuleId + " build error. \n" + be.getMessage());
|
||||
|
||||
if (FpdParserForThread.errorModule == null) {
|
||||
FpdParserForThread.errorModule = fpdModuleId;
|
||||
|
|
|
@ -296,6 +296,43 @@ public class FpdParserTask extends Task {
|
|||
public void parseFpdFile(File fpdFile) throws BuildException, EdkException {
|
||||
this.fpdFile = fpdFile;
|
||||
parseFpdFile();
|
||||
|
||||
//
|
||||
// Call Platform_build.xml prebuild firstly in stand-alone build
|
||||
// Prepare BUILD_DIR
|
||||
//
|
||||
isUnified = OutputManager.getInstance().prepareBuildDir(getProject());
|
||||
|
||||
String buildDir = getProject().getProperty("BUILD_DIR");
|
||||
//
|
||||
// For every Target and ToolChain
|
||||
//
|
||||
String[] targetList = GlobalData.getToolChainInfo().getTargets();
|
||||
for (int i = 0; i < targetList.length; i++) {
|
||||
String[] toolchainList = GlobalData.getToolChainInfo().getTagnames();
|
||||
for(int j = 0; j < toolchainList.length; j++) {
|
||||
//
|
||||
// Prepare FV_DIR
|
||||
//
|
||||
String ffsCommonDir = buildDir + File.separatorChar
|
||||
+ targetList[i] + "_"
|
||||
+ toolchainList[j];
|
||||
File fvDir = new File(ffsCommonDir + File.separatorChar + "FV");
|
||||
fvDir.mkdirs();
|
||||
}
|
||||
}
|
||||
|
||||
String platformBuildFile = buildDir + File.separatorChar + platformId.getName() + "_build.xml";
|
||||
PlatformBuildFileGenerator fileGenerator = new PlatformBuildFileGenerator(getProject(), outfiles, fvs, isUnified, saq, platformBuildFile);
|
||||
fileGenerator.genBuildFile();
|
||||
|
||||
Ant ant = new Ant();
|
||||
ant.setProject(getProject());
|
||||
ant.setAntfile(platformBuildFile);
|
||||
ant.setTarget("prebuild");
|
||||
ant.setInheritAll(true);
|
||||
ant.init();
|
||||
ant.execute();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue