]> git.proxmox.com Git - mirror_edk2.git/commitdiff
moved exception and logger classes to org.tianocore.common package
authoryshi8 <yshi8@6f19259b-4bc3-4df7-8a09-765794883524>
Tue, 15 Aug 2006 06:27:57 +0000 (06:27 +0000)
committeryshi8 <yshi8@6f19259b-4bc3-4df7-8a09-765794883524>
Tue, 15 Aug 2006 06:27:57 +0000 (06:27 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@1269 6f19259b-4bc3-4df7-8a09-765794883524

34 files changed:
Tools/Source/Common/org/tianocore/common/definitions/EdkDefinitions.java
Tools/Source/Common/org/tianocore/common/definitions/ToolDefinitions.java
Tools/Source/Common/org/tianocore/common/exception/EdkException.java
Tools/Source/Common/org/tianocore/common/logger/DefaultLogger.java
Tools/Source/Common/org/tianocore/common/logger/EdkLog.java
Tools/Source/Common/org/tianocore/common/logger/LogMethod.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/CreateMtFileTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/EfiCompressTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/EfiRomTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/FlashMapTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/FrameworkLogger.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/FwImageTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/GenAcpiTableTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/GenCapsuleHdrTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/GenTeImageTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/MakeDeps.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/ModifyInfTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/PeiReBaseTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/SecApResetVectorFixupTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/SecFixupTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/SplitfileTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/StripTask.java
Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/ZeroDebugDataTask.java
Tools/Source/GenBuild/org/tianocore/build/GenBuildTask.java
Tools/Source/GenBuild/org/tianocore/build/autogen/AutoGen.java
Tools/Source/GenBuild/org/tianocore/build/exception/GenBuildException.java
Tools/Source/GenBuild/org/tianocore/build/exception/TianoToolsException.java
Tools/Source/GenBuild/org/tianocore/build/fpd/FpdParserTask.java
Tools/Source/GenBuild/org/tianocore/build/global/GenBuildLogger.java
Tools/Source/GenBuild/org/tianocore/build/global/GlobalData.java
Tools/Source/GenBuild/org/tianocore/build/global/SurfaceAreaQuery.java
Tools/Source/GenBuild/org/tianocore/build/toolchain/ConfigReader.java
Tools/Source/GenBuild/org/tianocore/build/toolchain/ToolChainConfig.java
Tools/Source/GenBuild/org/tianocore/build/toolchain/ToolChainKey.java

index c455581a99577961acead4e47a5a01ff8eea8f69..e5f510a19992f69db2a80453c4685035896f12d5 100644 (file)
@@ -15,7 +15,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 \r
 **/\r
 \r
-package org.tianocore.definitions;\r
+package org.tianocore.common.definitions;\r
 \r
 /**\r
   This class includes the common EDK definitions.\r
index cc95e1f66ad37b63e118ca7642e0fe209c156425..2b510c3b0217a6669d417f320f0c468252d60cc0 100644 (file)
@@ -14,7 +14,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 \r
 **/\r
 \r
-package org.tianocore.definitions;\r
+package org.tianocore.common.definitions;\r
 \r
 import java.io.File;\r
 \r
index bd143d860af6cc0e4f869bda171b4edfd66d9248..0b7f5787a36028d39d0e583c993f4f52fd5cde67 100644 (file)
@@ -15,7 +15,8 @@ Module Name:
 Abstract:\r
 \r
 --*/\r
-package org.tianocore.exception;\r
+\r
+package org.tianocore.common.exception;\r
 \r
 public class EdkException extends Exception {\r
     static final long serialVersionUID = -8494188017252114029L;\r
@@ -28,13 +29,13 @@ public class EdkException extends Exception {
 \r
     public EdkException(String message, boolean traceStack) {\r
         super(message);\r
-        \r
+\r
     }\r
-    \r
+\r
     public EdkException(){\r
         super();\r
     }\r
-    \r
+\r
     public EdkException(Exception e, String message){\r
         super("[EdkException]:" + message);\r
         if (isPrintStack){\r
index 4bec8e52b4983e58a0c68076ab5be9e6b98e4ddd..d0f9be4da80103dcd42a95a3968bae26b0b32142 100644 (file)
@@ -16,7 +16,8 @@ Abstract:
 \r
 --*/\r
 \r
-package org.tianocore.logger;\r
+package org.tianocore.common.logger;\r
+\r
 import java.util.logging.Level;\r
 import java.util.logging.Logger;\r
 \r
index b16d39c2b1a3b5f556191b46a55f4614b78855c7..220b9899f76386e49a710c971b299817e44d9653 100644 (file)
@@ -15,10 +15,10 @@ Module Name:
 Abstract:\r
 \r
 --*/\r
-package org.tianocore.logger;\r
 \r
-import org.tianocore.logger.LogMethod;\r
+package org.tianocore.common.logger;\r
 \r
+import org.tianocore.common.logger.LogMethod;\r
 \r
 public class EdkLog {\r
     private static final String error    = "ERROR";\r
@@ -26,7 +26,7 @@ public class EdkLog {
     private static final String info     = "INFO";\r
     private static final String verbose  = "VERBOSE";\r
     private static final String debug    = "DEBUG";\r
-    \r
+\r
     public static final int EDK_ERROR   = 0;\r
     public static final int EDK_WARNING = 1;\r
     public static final int EDK_INFO    = 2;\r
@@ -38,9 +38,9 @@ public class EdkLog {
 \r
     public static void log(int level, String message) {\r
         if (level <= logLevel){\r
-            logger.putMessage(null, logLevel, message);  \r
+            logger.putMessage(null, logLevel, message);\r
         }\r
-       \r
+\r
     }\r
 \r
     public static void log(int logLevel, String message, Exception cause) {\r
@@ -58,7 +58,7 @@ public class EdkLog {
     public static void setLogger(LogMethod l) {\r
         logger = l;\r
     }\r
-    \r
+\r
     public static void setLogLevel (int level){\r
         logLevel = level;\r
     }\r
@@ -72,16 +72,16 @@ public class EdkLog {
        }\r
        if (levelStr.equalsIgnoreCase(debug)){\r
            logLevel = EDK_DEBUG;\r
-       } \r
+       }\r
        if (levelStr.equalsIgnoreCase(info)){\r
            logLevel = EDK_INFO;\r
-       } \r
+       }\r
        if (levelStr.equalsIgnoreCase(verbose)){\r
            logLevel = EDK_VERBOSE;\r
-       } \r
+       }\r
        if (levelStr.equalsIgnoreCase(warning)){\r
            logLevel = EDK_WARNING;\r
-       } \r
+       }\r
     }\r
     public static int getLogLevel (){\r
         return logLevel;\r
index ab6024083a4b74bf9b961579aae81f9553f0cc3c..28d30020c35fe624a2a3ddae456c17224180aa34 100644 (file)
@@ -15,8 +15,8 @@ Module Name:
 Abstract:\r
 \r
 --*/\r
-package org.tianocore.logger;\r
 \r
+package org.tianocore.common.logger;\r
 \r
 public interface LogMethod {\r
     public void putMessage(Object msgSource, int msgLevel, String msg);\r
index bb7e3230ec6376307497c47fa5882c0329f934ee..d73ea6a9293d43d4b322d3885c66a82897e1ce3c 100644 (file)
@@ -2,14 +2,14 @@
  CreateMtFileTask class.\r
 \r
  CreateMtFileTask is used to call CreateMtFile.exe to create MT file.\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -24,7 +24,8 @@ import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
   CreateMtFileTask class.\r
@@ -53,10 +54,10 @@ public class CreateMtFileTask extends Task implements EfiDefine {
 \r
     /**\r
      * execute\r
-     * \r
+     *\r
      * StripTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -85,7 +86,7 @@ public class CreateMtFileTask extends Task implements EfiDefine {
         File file = new File(outputFile);\r
         if (!file.isAbsolute() && (!this.outputDir.equalsIgnoreCase(""))) {\r
             argument = outputDir + File.separatorChar +  outputFile + " " + this.fileSize;\r
-                   \r
+\r
         } else {\r
             argument = outputFile  + " " + this.fileSize;\r
         }\r
@@ -111,7 +112,7 @@ public class CreateMtFileTask extends Task implements EfiDefine {
             EdkLog.log(EdkLog.EDK_VERBOSE, Commandline.toString(cmdline.getCommandline()));\r
             EdkLog.log(EdkLog.EDK_INFO, (new File(this.outputFile)).getName());\r
             revl = runner.execute();\r
-            \r
+\r
             if (EFI_SUCCESS == revl) {\r
                 //\r
                 // command execution success\r
@@ -131,9 +132,9 @@ public class CreateMtFileTask extends Task implements EfiDefine {
 \r
     /**\r
      * getFileSize\r
-     * \r
+     *\r
      * This function is to get class member "fileSize".\r
-     * \r
+     *\r
      * @return fileSize       string of file size.\r
      */\r
     public String getFileSize() {\r
@@ -142,9 +143,9 @@ public class CreateMtFileTask extends Task implements EfiDefine {
 \r
     /**\r
      * setFileSize\r
-     * \r
+     *\r
      * This function is to set class member "fileSize".\r
-     * \r
+     *\r
      * @param fileSize\r
      *            string of file size value.\r
      */\r
@@ -154,9 +155,9 @@ public class CreateMtFileTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputFile\r
-     * \r
+     *\r
      * This function is to get class member "outputFile"\r
-     * \r
+     *\r
      * @return outputFile string of output file name.\r
      */\r
     public String getOutputFile() {\r
@@ -165,9 +166,9 @@ public class CreateMtFileTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputFile\r
-     * \r
+     *\r
      * This function is to set class member "outputFile"\r
-     * \r
+     *\r
      * @param outputFile\r
      *            string of output file name.\r
      */\r
@@ -177,9 +178,9 @@ public class CreateMtFileTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
+     *\r
      * @return outputDir string of output directory.\r
      */\r
     public String getOutputDir() {\r
@@ -188,9 +189,9 @@ public class CreateMtFileTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param outputDir\r
      *            string of output directory.\r
      */\r
index ef06e134bfdb3e787efa0fc900c6541dc473e462..8f8ea2eb25782cf83af082d9d9e8ca3fb2ce891b 100644 (file)
@@ -2,14 +2,14 @@
  EfiCompressTask class.\r
 \r
  EfiCompressTask is used to call EfiCompress.exe to strip input file.\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -24,7 +24,8 @@ import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
   EfiCompressTask class.\r
@@ -49,10 +50,10 @@ public class EfiCompressTask extends Task implements EfiDefine {
 \r
     /**\r
      * execute\r
-     * \r
+     *\r
      * EfiCompressTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -106,9 +107,9 @@ public class EfiCompressTask extends Task implements EfiDefine {
             //\r
             EdkLog.log(EdkLog.EDK_VERBOSE, Commandline.toString(cmdline.getCommandline()));\r
             EdkLog.log(EdkLog.EDK_INFO, (new File(this.inputFile)).getName());\r
-            \r
+\r
             revl = runner.execute();\r
-            \r
+\r
             if (EFI_SUCCESS == revl) {\r
                 //\r
                 // command execution success\r
@@ -129,9 +130,9 @@ public class EfiCompressTask extends Task implements EfiDefine {
 \r
     /**\r
      * getInputFile\r
-     * \r
+     *\r
      * This function is to get class member "inputFile".\r
-     * \r
+     *\r
      * @return string of input file name.\r
      */\r
     public String getInputFile() {\r
@@ -140,9 +141,9 @@ public class EfiCompressTask extends Task implements EfiDefine {
 \r
     /**\r
      * setComponentType\r
-     * \r
+     *\r
      * This function is to set class member "inputFile".\r
-     * \r
+     *\r
      * @param inputFile\r
      *            string of input file name.\r
      */\r
@@ -152,9 +153,9 @@ public class EfiCompressTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputFile\r
-     * \r
+     *\r
      * This function is to get class member "outputFile"\r
-     * \r
+     *\r
      * @return outputFile string of output file name.\r
      */\r
     public String getOutputFile() {\r
@@ -163,9 +164,9 @@ public class EfiCompressTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputFile\r
-     * \r
+     *\r
      * This function is to set class member "outputFile"\r
-     * \r
+     *\r
      * @param outputFile\r
      *            string of output file name.\r
      */\r
@@ -175,9 +176,9 @@ public class EfiCompressTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
+     *\r
      * @return outputDir string of output directory.\r
      */\r
     public String getOutputDir() {\r
@@ -186,9 +187,9 @@ public class EfiCompressTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param outputDir\r
      *            string of output directory.\r
      */\r
index ff2be738f7ddf70014606bf46cfce3017ed807e4..e54fd06d6797bfe6b2d380a407f66019d30f2114 100644 (file)
@@ -2,14 +2,14 @@
  EfiRomTask class.\r
 \r
  EfiRomTask is used to call FlashMap.exe to lay out the flash.\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -26,11 +26,12 @@ import java.util.List;
 import org.apache.tools.ant.Task;\r
 import org.apache.tools.ant.Project;\r
 import org.apache.tools.ant.BuildException;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
  * SecFixupTask class.\r
- * \r
+ *\r
  * SecFixupTask is used to call SecFixup.exe to fix up sec image.\r
  */\r
 public class EfiRomTask extends Task implements EfiDefine {\r
@@ -38,7 +39,7 @@ public class EfiRomTask extends Task implements EfiDefine {
     /// tool name\r
     ///\r
     private final String toolName = "EfiRom";\r
-    \r
+\r
     ///\r
     /// Flash default file\r
     ///\r
@@ -53,59 +54,59 @@ public class EfiRomTask extends Task implements EfiDefine {
     /// Flash device Image\r
     ///\r
     private String deviceId = "";\r
-    \r
+\r
     ///\r
     /// MCI file\r
     ///\r
     private String outputFile = "";\r
-    \r
+\r
     ///\r
     /// MCO file\r
     ///\r
     private List<Input> binaryFileList = new ArrayList<Input>();\r
-    \r
+\r
     ///\r
     /// Efi PE32 image file\r
     ///\r
     private List<Input> pe32FileList = new ArrayList<Input>();\r
-    \r
+\r
     ///\r
     /// Compress efi PE32 image file\r
     ///\r
     private List<Input> pe32ComprFileList = new ArrayList<Input>();\r
-    \r
+\r
     ///\r
     /// Hex class code in the PCI data strutor header\r
     ///\r
     private String classCode = "";\r
-    \r
+\r
     ///\r
     /// Hex revision in the PCI data header.\r
     ///\r
     private String revision = "";\r
-    \r
+\r
     ///\r
     /// Dump the headers of an existing option rom image.\r
     ///\r
     private String dump = "";\r
-    \r
-    \r
+\r
+\r
     ///\r
     /// output directory\r
     ///\r
     private String outputDir = ".";\r
\r
-    \r
+\r
+\r
     ///\r
     /// command and argument list\r
     ///\r
     LinkedList<String> argList = new LinkedList<String>();\r
     /**\r
      * execute\r
-     * \r
+     *\r
      * EfiRomTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -128,7 +129,7 @@ public class EfiRomTask extends Task implements EfiDefine {
             command = path + File.separatorChar + toolName;\r
         }\r
         argList.addFirst(command);\r
-                 \r
+\r
         //\r
         // add microcode binary files\r
         //\r
@@ -139,7 +140,7 @@ public class EfiRomTask extends Task implements EfiDefine {
                 argList.add(((Input)binList.next()).getFile());\r
             }\r
         }\r
-        \r
+\r
         //\r
         // add pe32 file\r
         //\r
@@ -150,7 +151,7 @@ public class EfiRomTask extends Task implements EfiDefine {
                 argList.add(((Input)pe32List.next()).getFile());\r
             }\r
         }\r
-        \r
+\r
         //\r
         // add compressed pe32 file\r
         //\r
@@ -191,48 +192,48 @@ public class EfiRomTask extends Task implements EfiDefine {
             }\r
         }\r
     }\r
-    \r
+\r
     /**\r
      * getVerbose\r
-     * \r
+     *\r
      * This function is to get class member "verbose"\r
-     * \r
+     *\r
      * @return verbose   for verbose output.\r
      */\r
     public String getVerbose() {\r
         return verbose;\r
     }\r
-    \r
+\r
     /**\r
      * setVerbose\r
-     * \r
+     *\r
      * This function is to set class member "verbose"\r
-     * \r
+     *\r
      * @param verbose    for verbose output.\r
      */\r
     public void setVerbose(boolean verbose) {\r
         if (verbose){\r
             this.verbose = "-p";\r
-            argList.add(this.verbose);  \r
+            argList.add(this.verbose);\r
         }\r
     }\r
-    \r
+\r
     /**\r
      * getVenderId\r
-     * \r
+     *\r
      * This function is to get class member "venderId"\r
-     * \r
+     *\r
      * @return venderId     String of venderId.\r
      */\r
     public String getVenderId() {\r
         return venderId;\r
     }\r
-    \r
+\r
     /**\r
      * setVenderId\r
-     * \r
+     *\r
      * This function is to set class member "venderId"\r
-     * \r
+     *\r
      * @param venderId      String of venderId.\r
      */\r
     public void setVenderId(String VenderId) {\r
@@ -240,23 +241,23 @@ public class EfiRomTask extends Task implements EfiDefine {
         argList.add("-v");\r
         argList.add(this.venderId);\r
     }\r
-    \r
+\r
     /**\r
      * getDeviceId\r
-     * \r
+     *\r
      * This function is to get class member "deviceId"\r
-     * \r
+     *\r
      * @return deviceId   String of device ID.\r
      */\r
     public String getDeviceId() {\r
         return this.deviceId;\r
     }\r
-    \r
+\r
     /**\r
      * setDeviceId\r
-     * \r
+     *\r
      * This function is to set class member "deviceId"\r
-     * \r
+     *\r
      * @param deviceId   String of device ID.\r
      */\r
     public void setDeviceId(String deviceId) {\r
@@ -265,46 +266,46 @@ public class EfiRomTask extends Task implements EfiDefine {
         argList.add(this.deviceId);\r
     }\r
 \r
-    \r
+\r
     /**\r
      * getOutputFile\r
-     * \r
+     *\r
      * This function is to get class member "outputFile"\r
-     * \r
+     *\r
      * @return outputFile     name of output directory.\r
      */\r
     public String getOutputFile() {\r
         return outputFile;\r
     }\r
-    \r
+\r
     /**\r
      * setOutputFile\r
-     * \r
+     *\r
      * This function is to set class member "dscFile"\r
-     * \r
+     *\r
      * @param outputFile      name of DSC file\r
      */\r
     public void setOutputFile(String outputFile) {\r
         this.outputFile = outputFile;\r
-        \r
+\r
     }\r
-    \r
+\r
     /**\r
      * getClassCode\r
-     * \r
+     *\r
      * This function is to get class member "classCode"\r
-     * \r
+     *\r
      * @return fdImage       name of class code file.\r
      */\r
     public String getClassCode() {\r
         return classCode;\r
     }\r
-    \r
+\r
     /**\r
      * setclassCode\r
-     * \r
+     *\r
      * This function is to set class member "classCode"\r
-     * \r
+     *\r
      * @param fdImage        name of class code file.\r
      */\r
     public void setclassCode(String classCode) {\r
@@ -312,23 +313,23 @@ public class EfiRomTask extends Task implements EfiDefine {
         argList.add("-cc");\r
         argList.add(this.classCode);\r
     }\r
-    \r
+\r
     /**\r
      * getRevision\r
-     * \r
+     *\r
      * This function is to get class member "revision".\r
-     * \r
+     *\r
      * @return revision     hex revision in the PDI data header.\r
      */\r
     public String getRevision() {\r
         return revision;\r
     }\r
-    \r
+\r
     /**\r
      * setRevision\r
-     * \r
+     *\r
      * This function is to set class member "revision"\r
-     * \r
+     *\r
      * @param revision     hex revision in the PDI data header.\r
      */\r
     public void setRevision(String revision) {\r
@@ -336,23 +337,23 @@ public class EfiRomTask extends Task implements EfiDefine {
         argList.add("-rev");\r
         argList.add(this.revision);\r
     }\r
-    \r
+\r
     /**\r
      * getFlashDeviceImage\r
-     * \r
+     *\r
      * This function is to get class member "dump"\r
-     * \r
+     *\r
      * @return flashDeviceImage      name of flash device image\r
      */\r
     public String getDump() {\r
         return dump;\r
     }\r
-    \r
+\r
     /**\r
      * setFlashDeviceImage\r
-     * \r
+     *\r
      * This function is to set class member "dump"\r
-     * \r
+     *\r
      * @param flashDeviceImage        name of flash device image\r
      */\r
     public void setDump(boolean dump) {\r
@@ -364,20 +365,20 @@ public class EfiRomTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
-     * @return outputDir       string of output directory \r
+     *\r
+     * @return outputDir       string of output directory\r
      */\r
     public String getOutputDir() {\r
         return outputDir;\r
     }\r
-    \r
+\r
     /**\r
      * setOutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param outputDir         string of output directory\r
      */\r
     public void setOutputDir(String outputDir) {\r
@@ -385,31 +386,31 @@ public class EfiRomTask extends Task implements EfiDefine {
     }\r
     /**\r
      * addBinaryFile\r
-     * \r
+     *\r
      * This function is to add binary file to binaryFile list.\r
-     * \r
+     *\r
      * @param binaryFile         name of binary file.\r
      */\r
     public void addBinaryFile(Input binaryFile){\r
         this.binaryFileList.add(binaryFile);\r
     }\r
-    \r
+\r
     /**\r
      * addPe32File\r
-     * \r
-     * This function is to add pe32 file to pe32File list. \r
-     * \r
+     *\r
+     * This function is to add pe32 file to pe32File list.\r
+     *\r
      * @param pe32File            name of pe32 file.\r
      */\r
     public void addPe32File(Input pe32File){\r
         this.pe32FileList.add(pe32File);\r
     }\r
-    \r
+\r
     /**\r
      * addPe32ComprFile\r
-     * \r
+     *\r
      * This function os to add compressed pe32 file to pe32ComprFile list.\r
-     * \r
+     *\r
      * @param pe32ComprFile        name of compressed pe32 file.\r
      */\r
     public void addPe32ComprFile(Input pe32ComprFile){\r
index e494e564c835f94094a8e58948cf629dd241c48f..9b6268903d59d0d3bc6e585f976f1d9f0b1c7734 100644 (file)
@@ -2,14 +2,14 @@
  FlashMapTask class.\r
 \r
  FlashMapTask is used to call FlashMap.exe to lay out the flash.\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -26,11 +26,12 @@ import java.util.List;
 import org.apache.tools.ant.Task;\r
 import org.apache.tools.ant.Project;\r
 import org.apache.tools.ant.BuildException;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
  * FlashMapTask class.\r
- * \r
+ *\r
  * FlashMapTask is used to call FlashMap.exe to generate flash map defition files and fd files.\r
  */\r
 public class FlashMapTask extends Task implements EfiDefine {\r
@@ -131,10 +132,10 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * execute\r
-     * \r
+     *\r
      * FlashMapTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -168,8 +169,8 @@ public class FlashMapTask extends Task implements EfiDefine {
             argList.add(this.inStrFile);\r
             argList.add(this.outStrFile);\r
         }\r
-    \r
-       \r
+\r
+\r
         //\r
         // add microcode binary files\r
         //\r
@@ -216,9 +217,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getFlashDefFile\r
-     * \r
+     *\r
      * This function is to get class member "flashDefFile"\r
-     * \r
+     *\r
      * @return flashDeFile Name of flash definition file.\r
      */\r
     public String getFlashDefFile() {\r
@@ -227,9 +228,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setFlashDefFile\r
-     * \r
+     *\r
      * This function is to set class member "flashDefFile"\r
-     * \r
+     *\r
      * @param flashDefFile\r
      *            Name of flash definition file.\r
      */\r
@@ -241,9 +242,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getAligment\r
-     * \r
+     *\r
      * This function is to get class member "aligment"\r
-     * \r
+     *\r
      * @return aligment String of aligment value.\r
      */\r
     public String getAligment() {\r
@@ -252,9 +253,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setAligment\r
-     * \r
+     *\r
      * This function is to set class member "aligment"\r
-     * \r
+     *\r
      * @param aligment\r
      *            String of aligment value.\r
      */\r
@@ -266,9 +267,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getAsmIncFile\r
-     * \r
+     *\r
      * This function is to get class member "asmIncFile"\r
-     * \r
+     *\r
      * @return asmIncFile String of ASM include file.\r
      */\r
     public String getAsmIncFile() {\r
@@ -277,9 +278,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setAsmIncFile\r
-     * \r
+     *\r
      * This function is to set class member "asmIncFile"\r
-     * \r
+     *\r
      * @param asmIncFile\r
      *            String of ASM include file.\r
      */\r
@@ -291,9 +292,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getBaseAddr\r
-     * \r
+     *\r
      * This function is to get class member "baseAddr"\r
-     * \r
+     *\r
      * @return baseAddr String of base address value.\r
      */\r
     public String getBaseAddr() {\r
@@ -302,9 +303,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setBaseAddr\r
-     * \r
+     *\r
      * This function is to set class member "baseAddr"\r
-     * \r
+     *\r
      * @param baseAddr\r
      *            String of base address value.\r
      */\r
@@ -316,9 +317,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getDscFile\r
-     * \r
+     *\r
      * This function is to get class member "dscFile"\r
-     * \r
+     *\r
      * @return dscFile name of DSC file\r
      */\r
     public String getDscFile() {\r
@@ -327,9 +328,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setDscFile\r
-     * \r
+     *\r
      * This function is to set class member "dscFile"\r
-     * \r
+     *\r
      * @param dscFile\r
      *            name of DSC file\r
      */\r
@@ -341,9 +342,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getFdImage\r
-     * \r
+     *\r
      * This function is to get class member "fdImage"\r
-     * \r
+     *\r
      * @return fdImage name of input FDI image file.\r
      */\r
     public String getFdImage() {\r
@@ -352,9 +353,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setFdImage\r
-     * \r
+     *\r
      * This function is to set class member "fdImage"\r
-     * \r
+     *\r
      * @param fdImage\r
      *            name of input FDI image file.\r
      */\r
@@ -366,9 +367,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getFlashDevice\r
-     * \r
+     *\r
      * This function is to get class member "flashDevice".\r
-     * \r
+     *\r
      * @return flashDevice name of flash device.\r
      */\r
     public String getFlashDevice() {\r
@@ -377,9 +378,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setFlashDevice\r
-     * \r
+     *\r
      * This function is to set class member "flashDevice"\r
-     * \r
+     *\r
      * @param flashDevice\r
      *            name of flash device.\r
      */\r
@@ -391,9 +392,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getFlashDeviceImage\r
-     * \r
+     *\r
      * This function is to get class member "flashDeviceImage"\r
-     * \r
+     *\r
      * @return flashDeviceImage name of flash device image\r
      */\r
     public String getFlashDeviceImage() {\r
@@ -402,9 +403,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setFlashDeviceImage\r
-     * \r
+     *\r
      * This function is to set class member "flashDeviceImage"\r
-     * \r
+     *\r
      * @param flashDeviceImage\r
      *            name of flash device image\r
      */\r
@@ -417,9 +418,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getHeaderFile\r
-     * \r
+     *\r
      * This function is to get class member "headerFile"\r
-     * \r
+     *\r
      * @return headerFile name of include file\r
      */\r
     public String getHeaderFile() {\r
@@ -428,9 +429,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setHeaderFile\r
-     * \r
+     *\r
      * This function is to set class member "headerFile"\r
-     * \r
+     *\r
      * @param headerFile\r
      *            name of include file\r
      */\r
@@ -442,9 +443,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getImageOutFile\r
-     * \r
+     *\r
      * This function is to get class member "imageOutFile"\r
-     * \r
+     *\r
      * @return imageOutFile name of output image file\r
      */\r
     public String getImageOutFile() {\r
@@ -453,9 +454,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setImageOutFile\r
-     * \r
+     *\r
      * This function is to set class member "ImageOutFile"\r
-     * \r
+     *\r
      * @param imageOutFile\r
      *            name of output image file\r
      */\r
@@ -467,9 +468,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getInStrFile\r
-     * \r
+     *\r
      * This function is to get class member "inStrFile"\r
-     * \r
+     *\r
      * @return inStrFile name of input file which used to replace symbol names.\r
      */\r
     public String getInStrFile() {\r
@@ -478,9 +479,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setInStrFile\r
-     * \r
+     *\r
      * This function is to set class member "inStrFile"\r
-     * \r
+     *\r
      * @param inStrFile\r
      *            name of input file which used to replace symbol names.\r
      */\r
@@ -490,9 +491,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getMciFile\r
-     * \r
+     *\r
      * This function is to get class member "mciFile"\r
-     * \r
+     *\r
      * @return mciFile name of input microcode file\r
      */\r
     public String getMciFile() {\r
@@ -501,9 +502,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setMciFile\r
-     * \r
+     *\r
      * This function is to set class member "mciFile"\r
-     * \r
+     *\r
      * @param mciFile\r
      *            name of input microcode file\r
      */\r
@@ -515,9 +516,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getMcoFile\r
-     * \r
+     *\r
      * This function is to get class member "mcoFile"\r
-     * \r
+     *\r
      * @return mcoFile name of output binary microcode image\r
      */\r
     public String getMcoFile() {\r
@@ -526,9 +527,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setMcoFile\r
-     * \r
+     *\r
      * This function is to set class member "mcoFile"\r
-     * \r
+     *\r
      * @param mcoFile\r
      *            name of output binary microcode image\r
      */\r
@@ -540,9 +541,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutStrFile\r
-     * \r
+     *\r
      * This function is to get class member "outStrFile"\r
-     * \r
+     *\r
      * @return outStrFile name of output string substitution file\r
      */\r
     public String getOutStrFile() {\r
@@ -551,9 +552,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutStrFile\r
-     * \r
+     *\r
      * This function is to set class member "outStrFile"\r
-     * \r
+     *\r
      * @param outStrFile\r
      *            name of output string substitution file\r
      */\r
@@ -563,9 +564,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getPadValue\r
-     * \r
+     *\r
      * This function is to get class member "padValue"\r
-     * \r
+     *\r
      * @return padValue string of byte value to use as padding\r
      */\r
     public String getPadValue() {\r
@@ -574,9 +575,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setPadValue\r
-     * \r
+     *\r
      * This function is to set class member "padValue"\r
-     * \r
+     *\r
      * @param padValue\r
      *            string of byte value to use as padding\r
      */\r
@@ -588,9 +589,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * addMciFile\r
-     * \r
+     *\r
      * This function is to add Microcode binary file\r
-     * \r
+     *\r
      * @param mciFile\r
      *            instance of input class\r
      */\r
@@ -600,9 +601,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
+     *\r
      * @return outputDir string of output directory\r
      */\r
     public String getOutputDir() {\r
@@ -611,9 +612,9 @@ public class FlashMapTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param outputDir\r
      *            string of output directory\r
      */\r
index 26d38bb6d2b0af6ed467b67550a913ac5dfbb350..39197ecbb7905ee2fc23e60e9de6d47a5dbbc478 100644 (file)
@@ -17,18 +17,20 @@ Abstract:
 --*/\r
 \r
 package org.tianocore.framework.tasks;\r
+\r
 import org.apache.tools.ant.Project;\r
-import org.tianocore.logger.LogMethod;\r
+\r
+import org.tianocore.common.logger.LogMethod;\r
 \r
 class FrameworkLogger implements LogMethod {\r
     private Project project;\r
     private String  titleName;\r
     public FrameworkLogger(Project project, String taskName) {\r
         this.project = project;\r
-        this.titleName = taskName;        \r
+        this.titleName = taskName;\r
     }\r
 \r
-    public void putMessage(Object msgSource, int msgLevel, String msg) {        \r
+    public void putMessage(Object msgSource, int msgLevel, String msg) {\r
         String frameworkMsg = " [" + this.titleName + "] " + msg;\r
         this.project.log(frameworkMsg, Project.MSG_INFO);\r
     }\r
index 6612a0330d2b5d72b510c167d02eca9f62f38030..b84ea4759517faa6c115783bfc20e4736eee119c 100644 (file)
@@ -2,14 +2,14 @@
  FwImageTask class.\r
 \r
  FwImageTask is used to call FwImage.ext to generate the FwImage.\r
-  \r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -24,7 +24,8 @@ import org.apache.tools.ant.Task;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 \r
 /**\r
@@ -34,17 +35,17 @@ import org.tianocore.logger.EdkLog;
 **/\r
 public class FwImageTask extends Task implements EfiDefine{\r
     ///\r
-    /// time&data \r
+    /// time&data\r
     ///\r
     private String time = "";\r
     ///\r
     /// input PE image\r
-    /// \r
+    ///\r
     private String peImage = "";\r
     private String peImageName = "";\r
     ///\r
     /// output EFI image\r
-    /// \r
+    ///\r
     private String outImage = "";\r
     ///\r
     /// component type\r
@@ -53,15 +54,15 @@ public class FwImageTask extends Task implements EfiDefine{
 \r
     /**\r
      * assemble tool command line & execute tool command line\r
-     * \r
+     *\r
      * @throws BuildException\r
      */\r
     /**\r
-      execute \r
-      \r
+      execute\r
+\r
       FwimageTask execute function is to assemble tool command line & execute\r
       tool command line\r
-      \r
+\r
       @throws BuidException\r
     **/\r
     public void execute() throws BuildException {\r
@@ -117,9 +118,9 @@ public class FwImageTask extends Task implements EfiDefine{
 \r
     /**\r
       setTime\r
-      \r
+\r
       This function is to set operation of class member "time".\r
-      \r
+\r
       @param time            string of time\r
     **/\r
     public void setTime(String time) {\r
@@ -128,7 +129,7 @@ public class FwImageTask extends Task implements EfiDefine{
 \r
     /**\r
       getTime\r
-      \r
+\r
       This function is to get class member "time"\r
       @return time          string of time\r
     **/\r
@@ -138,7 +139,7 @@ public class FwImageTask extends Task implements EfiDefine{
 \r
     /**\r
       getPeImage\r
-      \r
+\r
       This function is to get class member "peImage".\r
       @return                name of PE image\r
     **/\r
@@ -148,7 +149,7 @@ public class FwImageTask extends Task implements EfiDefine{
 \r
     /**\r
       setPeImage\r
-      \r
+\r
       This function is to set class member "peImage"\r
       @param  peImage        name of PE image\r
     **/\r
@@ -159,7 +160,7 @@ public class FwImageTask extends Task implements EfiDefine{
 \r
     /**\r
       getOutImage\r
-      \r
+\r
       This function is to get class member "outImage".\r
       @return                 name of output EFI image\r
     **/\r
@@ -169,7 +170,7 @@ public class FwImageTask extends Task implements EfiDefine{
 \r
     /**\r
       setOutImage\r
-      \r
+\r
       This function is to set class member "outImage".\r
       @param outImage         name of output EFI image\r
     **/\r
@@ -179,9 +180,9 @@ public class FwImageTask extends Task implements EfiDefine{
 \r
     /**\r
       getComponentType\r
-      \r
+\r
       This function is to get class member "componentType".\r
-      \r
+\r
       @return                 string of componentType\r
     **/\r
     public String getComponentType() {\r
@@ -190,7 +191,7 @@ public class FwImageTask extends Task implements EfiDefine{
 \r
     /**\r
       setComponentType\r
-      \r
+\r
       This function is to set class member "componentType".\r
       @param  componentType   string of component type\r
     **/\r
index 0b17b10dfb4c823b2a65d45620451b4359e2cf8c..5ccf53570ab034323fc85193685fc0204a0f0d3b 100644 (file)
@@ -2,14 +2,14 @@
  GenAcpiTable class.\r
 \r
  GenAcpiTable is used to call GenAcpiTable.exe to generate ACPI Table image .\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -24,7 +24,8 @@ import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
   GenAcpiTable class.\r
@@ -49,10 +50,10 @@ public class GenAcpiTableTask extends Task implements EfiDefine {
 \r
     /**\r
      * execute\r
-     * \r
+     *\r
      * StripTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -107,7 +108,7 @@ public class GenAcpiTableTask extends Task implements EfiDefine {
             EdkLog.log(EdkLog.EDK_VERBOSE, Commandline.toString(cmdline.getCommandline()));\r
             EdkLog.log(EdkLog.EDK_INFO, (new File(this.inputFile)).getName());\r
             revl = runner.execute();\r
-            \r
+\r
             if (EFI_SUCCESS == revl) {\r
                 //\r
                 // command execution success\r
@@ -127,9 +128,9 @@ public class GenAcpiTableTask extends Task implements EfiDefine {
 \r
     /**\r
      * getInputFile\r
-     * \r
+     *\r
      * This function is to get class member "inputFile".\r
-     * \r
+     *\r
      * @return string of input file name.\r
      */\r
     public String getInputFile() {\r
@@ -138,9 +139,9 @@ public class GenAcpiTableTask extends Task implements EfiDefine {
 \r
     /**\r
      * setComponentType\r
-     * \r
+     *\r
      * This function is to set class member "inputFile".\r
-     * \r
+     *\r
      * @param inputFile\r
      *            string of input file name.\r
      */\r
@@ -150,9 +151,9 @@ public class GenAcpiTableTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputFile\r
-     * \r
+     *\r
      * This function is to get class member "outputFile"\r
-     * \r
+     *\r
      * @return outputFile string of output file name.\r
      */\r
     public String getOutputFile() {\r
@@ -161,9 +162,9 @@ public class GenAcpiTableTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputFile\r
-     * \r
+     *\r
      * This function is to set class member "outputFile"\r
-     * \r
+     *\r
      * @param outputFile\r
      *            string of output file name.\r
      */\r
@@ -173,9 +174,9 @@ public class GenAcpiTableTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
+     *\r
      * @return outputDir string of output directory.\r
      */\r
     public String getOutputDir() {\r
@@ -184,9 +185,9 @@ public class GenAcpiTableTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param outputDir\r
      *            string of output directory.\r
      */\r
index c532113d452fc181cbac7c3f2c465d07c6088db8..591ec032f580a966a1e43956e16c36c7e351cc5f 100644 (file)
@@ -2,14 +2,14 @@
  GenCapsuleHdrTask class.\r
 \r
  GenCapsuleHdrTask is used to call GenCapsuleHdr.exe to generate capsule.\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -24,7 +24,8 @@ import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
   GenCapsuleHdrTask class.\r
@@ -36,7 +37,7 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
     /// tool name\r
     ///\r
     private String toolName = "GenCapsuleHdr";\r
-    \r
+\r
     ///\r
     /// script file\r
     ///\r
@@ -61,17 +62,17 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
     /// Dump flag\r
     ///\r
     private String dump = "";\r
-    \r
+\r
     ///\r
     /// Split size\r
     ///\r
     private String size = "";\r
-    \r
+\r
     ///\r
     /// capsule into one image flag\r
     ///\r
     private String joinFlag = "";\r
-    \r
+\r
     ///\r
     /// capsule file\r
     ///\r
@@ -80,10 +81,10 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * execute\r
-     * \r
+     *\r
      * GenCapsuleHdrTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -160,9 +161,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * getInputFile\r
-     * \r
+     *\r
      * This function is to get class member "scriptFile".\r
-     * \r
+     *\r
      * @return string of input file name.\r
      */\r
     public String getScriptFile() {\r
@@ -171,9 +172,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * setComponentType\r
-     * \r
+     *\r
      * This function is to set class member "inputFile".\r
-     * \r
+     *\r
      * @param inputFile\r
      *            string of input file name.\r
      */\r
@@ -183,9 +184,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputFile\r
-     * \r
+     *\r
      * This function is to get class member "outputFile"\r
-     * \r
+     *\r
      * @return outputFile string of output file name.\r
      */\r
     public String getOutputFile() {\r
@@ -194,9 +195,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputFile\r
-     * \r
+     *\r
      * This function is to set class member "outputFile"\r
-     * \r
+     *\r
      * @param outputFile\r
      *            string of output file name.\r
      */\r
@@ -206,9 +207,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
+     *\r
      * @return outputDir string of output directory.\r
      */\r
     public String getOutputDir() {\r
@@ -217,9 +218,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param outputDir\r
      *            string of output directory.\r
      */\r
@@ -229,9 +230,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * getVerbose\r
-     * \r
+     *\r
      * This function is to get class member "verbose"\r
-     * \r
+     *\r
      * @return verbose the flag of verbose.\r
      */\r
     public String getVerbose() {\r
@@ -240,9 +241,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * setVerbose\r
-     * \r
+     *\r
      * This function is to set class member "verbose"\r
-     * \r
+     *\r
      * @param verbose\r
      *            True or False.\r
      */\r
@@ -254,9 +255,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * getDump\r
-     * \r
+     *\r
      * This function is to get class member "dump"\r
-     * \r
+     *\r
      * @return verbose the flag of dump.\r
      */\r
     public String getDump() {\r
@@ -265,9 +266,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * setDump\r
-     * \r
+     *\r
      * This function is to set class member "dump".\r
-     * \r
+     *\r
      * @param dump\r
      *            True or False.\r
      */\r
@@ -279,9 +280,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * getSize\r
-     * \r
+     *\r
      * This function is to set class member "size".\r
-     * \r
+     *\r
      * @return size   string of size value\r
      */\r
     public String getSize() {\r
@@ -290,9 +291,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * setSize\r
-     * \r
+     *\r
      * This function is to set class member "size".\r
-     * \r
+     *\r
      * @param size  string of size value.\r
      */\r
     public void setSize(String size) {\r
@@ -301,9 +302,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * getCapsuleFile\r
-     * \r
+     *\r
      * This function is to get class member "capsuleFile"\r
-     * \r
+     *\r
      * @return capsuleFile   capsule file name\r
      */\r
     public String getCapsuleFile() {\r
@@ -312,9 +313,9 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * setCapsuleFile\r
-     * \r
+     *\r
      * This function is to set class member "capsuleFile"\r
-     * \r
+     *\r
      * @param capsuleFile   capsule file name\r
      */\r
     public void setCapsuleFile(String capsuleFile) {\r
@@ -323,10 +324,10 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * isJoinFlag\r
-     * \r
+     *\r
      * This function is to get class member "joinFlag"\r
-     * \r
-     * @return joinFlag    flag of if need to join split capsule  images into \r
+     *\r
+     * @return joinFlag    flag of if need to join split capsule  images into\r
      *                     a single image.\r
      */\r
     public String getJoinFlag() {\r
@@ -335,16 +336,16 @@ public class GenCapsuleHdrTask extends Task implements EfiDefine {
 \r
     /**\r
      * setJoinFlag\r
-     * \r
+     *\r
      * This function is to set class member "joinFlag"\r
-     * \r
-     * @param joinFlag     flag of if need to join split capsule  images into \r
-     *                     a single image.       \r
+     *\r
+     * @param joinFlag     flag of if need to join split capsule  images into\r
+     *                     a single image.\r
      */\r
     public void setJoinFlag(boolean joinFlag) {\r
         if (joinFlag){\r
-            this.joinFlag = "-j ";  \r
+            this.joinFlag = "-j ";\r
         }\r
-        \r
+\r
     }\r
 }\r
index 9717c6806c4777410492ca08fb9b0cb0c5feee11..a0743c6307909c3c20e2c12e12b051751170ae1c 100644 (file)
@@ -2,14 +2,14 @@
  GenTeImageTask class.\r
 \r
  GenTeImageTask is used to call GenTEImage.exe to generate TE image .\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -24,11 +24,12 @@ import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
  * GenTeImageTask class.\r
- * \r
+ *\r
  * GenTeImageTask is used to call GenAcpiTable.exe to generate ACPI Table image .\r
  */\r
 public class GenTeImageTask extends Task implements EfiDefine {\r
@@ -63,15 +64,15 @@ public class GenTeImageTask extends Task implements EfiDefine {
 \r
     /**\r
      * assemble tool command line & execute tool command line\r
-     * \r
+     *\r
      * @throws BuildException\r
      */\r
     /**\r
      * execute\r
-     * \r
+     *\r
      * GenTeImgaeTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -149,9 +150,9 @@ public class GenTeImageTask extends Task implements EfiDefine {
 \r
     /**\r
      * getInputFile\r
-     * \r
+     *\r
      * This function is to get class member "inputFile".\r
-     * \r
+     *\r
      * @return string of input file name.\r
      */\r
     public String getInputFile() {\r
@@ -160,9 +161,9 @@ public class GenTeImageTask extends Task implements EfiDefine {
 \r
     /**\r
      * setComponentType\r
-     * \r
+     *\r
      * This function is to set class member "inputFile".\r
-     * \r
+     *\r
      * @param inputFile\r
      *            string of input file name.\r
      */\r
@@ -172,9 +173,9 @@ public class GenTeImageTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputFile\r
-     * \r
+     *\r
      * This function is to get class member "outputFile"\r
-     * \r
+     *\r
      * @return outputFile string of output file name.\r
      */\r
     public String getOutputFile() {\r
@@ -183,9 +184,9 @@ public class GenTeImageTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputFile\r
-     * \r
+     *\r
      * This function is to set class member "outputFile"\r
-     * \r
+     *\r
      * @param outputFile\r
      *            string of output file name.\r
      */\r
@@ -195,9 +196,9 @@ public class GenTeImageTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
+     *\r
      * @return outputDir string of output directory.\r
      */\r
     public String getOutputDir() {\r
@@ -206,9 +207,9 @@ public class GenTeImageTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param outputDir\r
      *            string of output directory.\r
      */\r
@@ -218,9 +219,9 @@ public class GenTeImageTask extends Task implements EfiDefine {
 \r
     /**\r
      * getVerbose\r
-     * \r
+     *\r
      * This function is to get class member "verbose"\r
-     * \r
+     *\r
      * @return verbose the flag of verbose.\r
      */\r
     public String getVerbose() {\r
@@ -229,9 +230,9 @@ public class GenTeImageTask extends Task implements EfiDefine {
 \r
     /**\r
      * setVerbose\r
-     * \r
+     *\r
      * This function is to set class member "verbose"\r
-     * \r
+     *\r
      * @param verbose\r
      *            True or False.\r
      */\r
@@ -243,9 +244,9 @@ public class GenTeImageTask extends Task implements EfiDefine {
 \r
     /**\r
      * getDump\r
-     * \r
+     *\r
      * This function is to get class member "dump"\r
-     * \r
+     *\r
      * @return verbose the flag of dump.\r
      */\r
     public String getDump() {\r
@@ -254,9 +255,9 @@ public class GenTeImageTask extends Task implements EfiDefine {
 \r
     /**\r
      * setDump\r
-     * \r
+     *\r
      * This function is to set class member "dump"\r
-     * \r
+     *\r
      * @param dump\r
      *            True or False.\r
      */\r
index 231a37161b424af474a955bd4cae3143bdf8a347..5c4de1a78ef232edfb92b151195f64d845a381ef 100644 (file)
@@ -35,7 +35,8 @@ import org.apache.tools.ant.taskdefs.Execute;
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
 import org.apache.tools.ant.types.Path;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
  Class MakeDeps is used to wrap MakeDeps.exe as an ANT task.\r
@@ -112,7 +113,7 @@ public class MakeDeps extends Task {
 \r
         ///\r
         /// if there's no source files, we can do nothing about dependency\r
-        /// \r
+        ///\r
         if (inputFileList.size() == 0) {\r
             throw new BuildException("No source files specified to scan");\r
         }\r
@@ -375,7 +376,7 @@ public class MakeDeps extends Task {
 \r
             ///\r
             /// compose the final file content\r
-            /// \r
+            ///\r
             StringBuffer cleanedLines = new StringBuffer(40960);\r
             Iterator<String> it = lineSet.iterator();\r
             while (it.hasNext()) {\r
index 7e67fdabc865d25ced839ce05c9b8bbd0b93c320..a65b4b82cfe65cc72228532e9bc76ba24c25317e 100644 (file)
@@ -2,14 +2,14 @@
  ModifyInfTask class.\r
 \r
  ModifyInfTask is used to call Modify.exe to generate inf file.\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -24,7 +24,8 @@ import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
   ModifyInfTask class.\r
@@ -36,7 +37,7 @@ public class ModifyInfTask extends Task implements EfiDefine {
     /// tool name\r
     ///\r
     private String toolName = "ModifyInf";\r
-    \r
+\r
     ///\r
     /// input FV inf file\r
     ///\r
@@ -54,15 +55,15 @@ public class ModifyInfTask extends Task implements EfiDefine {
 \r
        ///\r
        ///  Output dir\r
-       /// \r
+       ///\r
        private String outputDir = "";\r
-   \r
+\r
     /**\r
      * execute\r
-     * \r
+     *\r
      * ModifyInfTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -91,12 +92,12 @@ public class ModifyInfTask extends Task implements EfiDefine {
                File file = new File(outputFVInfFileName);\r
         if (!file.isAbsolute() && (!this.outputDir.equalsIgnoreCase(""))) {\r
                        argument = this.inputFVInfFileName +\r
-                                      this.outputDir + \r
+                                      this.outputDir +\r
                                           File.separatorChar +\r
                                           this.outputFVInfFileName +\r
                                           this.patternStr;\r
                } else {\r
-                       argument = this.inputFVInfFileName + \r
+                       argument = this.inputFVInfFileName +\r
                                       this.outputFVInfFileName +\r
                                       this.patternStr;\r
                }\r
@@ -142,9 +143,9 @@ public class ModifyInfTask extends Task implements EfiDefine {
 \r
     /**\r
      * getinputFVInfFileName\r
-     * \r
+     *\r
      * This function is to get class member "inputFVInfFileName".\r
-     * \r
+     *\r
      * @return string of input inf file name.\r
      */\r
     public String getinputFVInfFileName() {\r
@@ -153,9 +154,9 @@ public class ModifyInfTask extends Task implements EfiDefine {
 \r
     /**\r
      * setinputFVInfFileName\r
-     * \r
+     *\r
      * This function is to set class member "inputFVInfFileName".\r
-     * \r
+     *\r
      * @param inputFile\r
      *            string of input inf file name.\r
      */\r
@@ -165,9 +166,9 @@ public class ModifyInfTask extends Task implements EfiDefine {
 \r
     /**\r
      * getoutputFVInfFileName\r
-     * \r
+     *\r
      * This function is to get class member "outputFVInfFileName"\r
-     * \r
+     *\r
      * @return outputFVInfFileName string of output inf file name.\r
      */\r
     public String getoutputFVInfFileName() {\r
@@ -176,9 +177,9 @@ public class ModifyInfTask extends Task implements EfiDefine {
 \r
     /**\r
      * setoutputFVInfFileName\r
-     * \r
+     *\r
      * This function is to set class member "outputFVInfFileName"\r
-     * \r
+     *\r
      * @param outputFVInfFileName\r
      *            string of output  inf file name.\r
      */\r
@@ -188,9 +189,9 @@ public class ModifyInfTask extends Task implements EfiDefine {
 \r
     /**\r
      * getpatternStr\r
-     * \r
+     *\r
      * This function is to get class member "patternStr"\r
-     * \r
+     *\r
      * @return patternStr string of pattern.\r
      */\r
     public String getpatternStr() {\r
@@ -199,9 +200,9 @@ public class ModifyInfTask extends Task implements EfiDefine {
 \r
     /**\r
      * setpatternStr\r
-     * \r
+     *\r
      * This function is to set class member "patternStr"\r
-     * \r
+     *\r
      * @param patternStr\r
      *            string of patternStr.\r
      */\r
@@ -211,9 +212,9 @@ public class ModifyInfTask extends Task implements EfiDefine {
 \r
        /**\r
      * getoutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
+     *\r
      * @return outputDir string of output directory.\r
      */\r
     public String getoutputDir() {\r
@@ -222,9 +223,9 @@ public class ModifyInfTask extends Task implements EfiDefine {
 \r
     /**\r
      * setoutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param patternStr\r
      *            string of output directory.\r
      */\r
index c479e0d3344198c81dd91cd5b6d107b908abd769..4e545e0012ec0ac658e887c5fcf5223fcd727ea7 100644 (file)
@@ -2,14 +2,14 @@
  PeiReBaseTask class.\r
 \r
  PeiReBaseTask is used to call PeiReBase.exe to rebase efi fv file.\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -24,7 +24,8 @@ import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
   PeiReBaseTask class.\r
@@ -50,23 +51,23 @@ public class PeiReBaseTask extends Task implements EfiDefine {
     // / Output directory, this variable is added by jave wrap\r
     // /\r
     private String outputDir = "";\r
-    \r
+\r
     ///\r
     /// Base address\r
     ///\r
     private String baseAddr = "";\r
-    \r
+\r
     ///\r
-    /// Architecture \r
+    /// Architecture\r
     ///\r
     private String arch = "";\r
-    \r
+\r
     /**\r
      * execute\r
-     * \r
+     *\r
      * PeiReBaseTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -78,7 +79,7 @@ public class PeiReBaseTask extends Task implements EfiDefine {
         FrameworkLogger logger = new FrameworkLogger(project, toolName.toLowerCase());\r
         EdkLog.setLogLevel(project.getProperty("env.LOGLEVEL"));\r
         EdkLog.setLogger(logger);\r
-        \r
+\r
         //\r
         // absolute path of efi tools\r
         //\r
@@ -97,7 +98,7 @@ public class PeiReBaseTask extends Task implements EfiDefine {
         if (path != null) {\r
             command = path + File.separatorChar + command;\r
         }\r
-        \r
+\r
         //\r
         // argument of tools\r
         //\r
@@ -109,7 +110,7 @@ public class PeiReBaseTask extends Task implements EfiDefine {
         } else {\r
             argument = inputFile + " " + "-O " + outputFile + " " + this.baseAddr+ " " + "-M " + outputFile + ".map";\r
         }\r
-        \r
+\r
         //\r
         // return value of fwimage execution\r
         //\r
@@ -131,9 +132,9 @@ public class PeiReBaseTask extends Task implements EfiDefine {
             //\r
             EdkLog.log(EdkLog.EDK_VERBOSE, Commandline.toString(cmdline.getCommandline()));\r
             EdkLog.log(EdkLog.EDK_INFO, this.inputFileName);\r
-            \r
+\r
             revl = runner.execute();\r
-            \r
+\r
             if (EFI_SUCCESS == revl) {\r
                 //\r
                 // command execution success\r
@@ -153,9 +154,9 @@ public class PeiReBaseTask extends Task implements EfiDefine {
 \r
     /**\r
      * getInputFile\r
-     * \r
+     *\r
      * This function is to get class member "inputFile".\r
-     * \r
+     *\r
      * @return string of input file name.\r
      */\r
     public String getInputFile() {\r
@@ -164,9 +165,9 @@ public class PeiReBaseTask extends Task implements EfiDefine {
 \r
     /**\r
      * setComponentType\r
-     * \r
+     *\r
      * This function is to set class member "inputFile".\r
-     * \r
+     *\r
      * @param inputFile\r
      *            string of input file name.\r
      */\r
@@ -177,9 +178,9 @@ public class PeiReBaseTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputFile\r
-     * \r
+     *\r
      * This function is to get class member "outputFile"\r
-     * \r
+     *\r
      * @return outputFile string of output file name.\r
      */\r
     public String getOutputFile() {\r
@@ -188,9 +189,9 @@ public class PeiReBaseTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputFile\r
-     * \r
+     *\r
      * This function is to set class member "outputFile"\r
-     * \r
+     *\r
      * @param outputFile\r
      *            string of output file name.\r
      */\r
@@ -200,9 +201,9 @@ public class PeiReBaseTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
+     *\r
      * @return outputDir string of output directory.\r
      */\r
     public String getOutputDir() {\r
@@ -211,9 +212,9 @@ public class PeiReBaseTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param outputDir\r
      *            string of output directory.\r
      */\r
@@ -223,9 +224,9 @@ public class PeiReBaseTask extends Task implements EfiDefine {
 \r
     /**\r
      * getBaseAddr\r
-     * \r
+     *\r
      * This function is to get class member "baseAddr"\r
-     * \r
+     *\r
      * @return baseAddr   string of base address.\r
      */\r
     public String getBaseAddr() {\r
@@ -234,9 +235,9 @@ public class PeiReBaseTask extends Task implements EfiDefine {
 \r
     /**\r
      * setBaseAddr\r
-     * \r
+     *\r
      * This function is to set class member "baseAddr"\r
-     * \r
+     *\r
      * @param baseAddr    string of base address\r
      */\r
     public void setBaseAddr(String baseAddr) {\r
@@ -245,9 +246,9 @@ public class PeiReBaseTask extends Task implements EfiDefine {
 \r
     /**\r
      * getArch\r
-     * \r
+     *\r
      * This function is to get class member "arch".\r
-     * \r
+     *\r
      * @return arch       Architecture\r
      */\r
     public String getArch() {\r
@@ -256,9 +257,9 @@ public class PeiReBaseTask extends Task implements EfiDefine {
 \r
     /**\r
      * setArch\r
-     * \r
-     * This function is to set class member "arch" \r
-     * \r
+     *\r
+     * This function is to set class member "arch"\r
+     *\r
      * @param arch         Architecture\r
      */\r
     public void setArch(String arch) {\r
index e1b9bd1b63735c1dabd3dbd11011e2fe466a39a5..28d5e87acdf157a66322fdfb95e6a9751d54ab0f 100644 (file)
@@ -3,14 +3,14 @@
 \r
  SecApResetVectorFixupTask is used to call SecApResetVectorFixup.exe to place\r
  Ap reset vector.\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -25,7 +25,8 @@ import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
   SecApResetVectorFixupTask class.\r
@@ -56,10 +57,10 @@ public class SecApResetVectorFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * execute\r
-     * \r
+     *\r
      * SecApResetVectorFixupTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -113,9 +114,9 @@ public class SecApResetVectorFixupTask extends Task implements EfiDefine {
             //\r
             EdkLog.log(EdkLog.EDK_VERBOSE, Commandline.toString(cmdline.getCommandline()));\r
             EdkLog.log(EdkLog.EDK_INFO, (new File(this.fvInputFile)).getName());\r
-            \r
+\r
             revl = runner.execute();\r
-            \r
+\r
             if (EFI_SUCCESS == revl) {\r
                 //\r
                 // command execution success\r
@@ -135,9 +136,9 @@ public class SecApResetVectorFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * getInputFile\r
-     * \r
+     *\r
      * This function is to get class member "fvInputFile".\r
-     * \r
+     *\r
      * @return string of input file name.\r
      */\r
     public String getfvInputFile() {\r
@@ -146,9 +147,9 @@ public class SecApResetVectorFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * setComponentType\r
-     * \r
+     *\r
      * This function is to set class member "fvInputFile".\r
-     * \r
+     *\r
      * @param inputFile\r
      *            string of input file name.\r
      */\r
@@ -158,9 +159,9 @@ public class SecApResetVectorFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputFile\r
-     * \r
+     *\r
      * This function is to get class member "fvOutputFile"\r
-     * \r
+     *\r
      * @return outputFile string of output file name.\r
      */\r
     public String getOutputFile() {\r
@@ -169,9 +170,9 @@ public class SecApResetVectorFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputFile\r
-     * \r
+     *\r
      * This function is to set class member "fvOutputFile"\r
-     * \r
+     *\r
      * @param outputFile\r
      *            string of output file name.\r
      */\r
@@ -181,9 +182,9 @@ public class SecApResetVectorFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
+     *\r
      * @return outputDir string of output directory.\r
      */\r
     public String getOutputDir() {\r
@@ -192,9 +193,9 @@ public class SecApResetVectorFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param outputDir\r
      *            string of output directory.\r
      */\r
index 38c6d1e0a1dd9df76de9e4dc51ca8a6400d2a6bb..8f46ff916f68806fb09dc2339a0cca55d542b353 100644 (file)
@@ -2,14 +2,14 @@
  SecFixupTask class.\r
 \r
  SecFixupTask is used to call SecFixup.exe to fix up sec image.\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -24,11 +24,12 @@ import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
  * SecFixupTask class.\r
- * \r
+ *\r
  * SecFixupTask is used to call SecFixup.exe to fix up sec image.\r
  */\r
 public class SecFixupTask extends Task implements EfiDefine {\r
@@ -59,10 +60,10 @@ public class SecFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * execute\r
-     * \r
+     *\r
      * SecFixupTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -139,9 +140,9 @@ public class SecFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * getSecExeFile\r
-     * \r
+     *\r
      * This function is to get class member "secExeFile".\r
-     * \r
+     *\r
      * @return string of sectExe file name.\r
      */\r
     public String getSecExeFile() {\r
@@ -150,9 +151,9 @@ public class SecFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * setSecExeFile\r
-     * \r
+     *\r
      * This function is to set class member "secExeFile".\r
-     * \r
+     *\r
      * @param secExeFile\r
      *            string of secExe file name.\r
      */\r
@@ -162,9 +163,9 @@ public class SecFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * getResetVectorDataFile\r
-     * \r
+     *\r
      * This function is to get class member "resetVectorDataFile"\r
-     * \r
+     *\r
      * @return resetVectorDataFile string of resetVectorData file name.\r
      */\r
     public String getResetVectorDataFile() {\r
@@ -173,9 +174,9 @@ public class SecFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * setResetVectorDataFile\r
-     * \r
+     *\r
      * This function is to set class member "resetVectorDataFile"\r
-     * \r
+     *\r
      * @param resetVectorDataFile\r
      *            string of resetVectorData file name.\r
      */\r
@@ -185,9 +186,9 @@ public class SecFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputFile\r
-     * \r
+     *\r
      * This function is to get class member "outputFile"\r
-     * \r
+     *\r
      * @return outputFile string of output file name.\r
      */\r
     public String getOutputFile() {\r
@@ -196,9 +197,9 @@ public class SecFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputFile\r
-     * \r
+     *\r
      * This function is to set class member "outputFile"\r
-     * \r
+     *\r
      * @param outputFile\r
      *            string of output file name.\r
      */\r
@@ -208,9 +209,9 @@ public class SecFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
+     *\r
      * @return outputDir name of output directory\r
      */\r
     public String getOutputDir() {\r
@@ -219,9 +220,9 @@ public class SecFixupTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param outputDir\r
      *            name of output directory\r
      */\r
index 8dbb94b46ec7f03324a0e057d22930361c49496f..a71eb013239fd4002f0a67b6646daf1d61b087b5 100644 (file)
@@ -1,16 +1,16 @@
 /** @file\r
  SplitfileTask class.\r
 \r
- SplitfileTask is used to call splitfile.exe to split input file to 2 output \r
+ SplitfileTask is used to call splitfile.exe to split input file to 2 output\r
  file.\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -25,12 +25,13 @@ import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
   SplitfileTask class.\r
 \r
-  SplitfileTask is used to call splitfile.exe to split input file to 2 output \r
+  SplitfileTask is used to call splitfile.exe to split input file to 2 output\r
   file.\r
 **/\r
 public class SplitfileTask extends Task implements EfiDefine {\r
@@ -44,26 +45,26 @@ public class SplitfileTask extends Task implements EfiDefine {
     ///\r
     private String offset = "";\r
 \r
-  \r
+\r
     /**\r
      * execute\r
-     * \r
+     *\r
      * SplitfleTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
 \r
         Project project = this.getOwningTarget().getProject();\r
-        \r
+\r
         //\r
         // set Logger\r
         //\r
         FrameworkLogger logger = new FrameworkLogger(project, "splitfile");\r
         EdkLog.setLogLevel(project.getProperty("env.LOGLEVEL"));\r
         EdkLog.setLogger(logger);\r
-        \r
+\r
         //\r
         // absolute path of efi tools\r
         //\r
@@ -75,12 +76,12 @@ public class SplitfileTask extends Task implements EfiDefine {
         } else {\r
             command = path + File.separatorChar + "SplitFile";\r
         }\r
-        \r
+\r
         //\r
         // argument of tools\r
         //\r
         argument = inputFile + " " + offset;\r
-        \r
+\r
         //\r
         // return value of fwimage execution\r
         //\r
@@ -97,7 +98,7 @@ public class SplitfileTask extends Task implements EfiDefine {
 \r
             runner.setAntRun(project);\r
             runner.setCommandline(cmdline.getCommandline());\r
-            \r
+\r
             EdkLog.log(EdkLog.EDK_VERBOSE, Commandline.toString(cmdline.getCommandline()));\r
             EdkLog.log(EdkLog.EDK_INFO, (new File(this.inputFile)).getName());\r
             revl = runner.execute();\r
@@ -120,9 +121,9 @@ public class SplitfileTask extends Task implements EfiDefine {
 \r
     /**\r
      * getInputFile\r
-     * \r
+     *\r
      * This function is to get class member "inputFile".\r
-     * \r
+     *\r
      * @return string of input file name.\r
      */\r
     public String getInputFile() {\r
@@ -131,9 +132,9 @@ public class SplitfileTask extends Task implements EfiDefine {
 \r
     /**\r
      * setComponentType\r
-     * \r
+     *\r
      * This function is to set class member "inputFile".\r
-     * \r
+     *\r
      * @param inputFile\r
      *            string of input file name.\r
      */\r
@@ -143,9 +144,9 @@ public class SplitfileTask extends Task implements EfiDefine {
 \r
     /**\r
       getOffset\r
-      \r
+\r
       This function is to get class member "offset"\r
-      \r
+\r
       @return offset value of string.\r
     **/\r
     public String getOffset() {\r
@@ -154,14 +155,14 @@ public class SplitfileTask extends Task implements EfiDefine {
 \r
     /**\r
       setOffset\r
-      \r
+\r
       This function is to set class member "offset"\r
-      \r
+\r
       @param offset\r
                  string of offset value.\r
     **/\r
     public void setOffset(String offset) {\r
         this.offset = offset;\r
     }\r
-    \r
+\r
 }\r
index d6e9bedf06e2f4b0182ecc0a20ace3f655f6c26d..107575c839829d8c6ca3e7fb12f589d1c4d6032f 100644 (file)
@@ -2,14 +2,14 @@
  StripTask class.\r
 \r
  StripTask is used to call Strip.exe to strip input file.\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -24,7 +24,8 @@ import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
   StripTask class.\r
@@ -47,13 +48,13 @@ public class StripTask extends Task implements EfiDefine {
     // /\r
     private String outputDir = "";\r
 \r
-    \r
+\r
     /**\r
      * execute\r
-     * \r
+     *\r
      * StripTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -107,9 +108,9 @@ public class StripTask extends Task implements EfiDefine {
             //\r
             EdkLog.log(EdkLog.EDK_VERBOSE, Commandline.toString(cmdline.getCommandline()));\r
             EdkLog.log(EdkLog.EDK_INFO, (new File(this.inputFile)).getName());\r
-            \r
+\r
             revl = runner.execute();\r
-            \r
+\r
             if (EFI_SUCCESS == revl) {\r
                 //\r
                 // command execution success\r
@@ -129,9 +130,9 @@ public class StripTask extends Task implements EfiDefine {
 \r
     /**\r
      * getInputFile\r
-     * \r
+     *\r
      * This function is to get class member "inputFile".\r
-     * \r
+     *\r
      * @return string of input file name.\r
      */\r
     public String getInputFile() {\r
@@ -140,9 +141,9 @@ public class StripTask extends Task implements EfiDefine {
 \r
     /**\r
      * setComponentType\r
-     * \r
+     *\r
      * This function is to set class member "inputFile".\r
-     * \r
+     *\r
      * @param inputFile\r
      *            string of input file name.\r
      */\r
@@ -152,9 +153,9 @@ public class StripTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputFile\r
-     * \r
+     *\r
      * This function is to get class member "outputFile"\r
-     * \r
+     *\r
      * @return outputFile string of output file name.\r
      */\r
     public String getOutputFile() {\r
@@ -163,9 +164,9 @@ public class StripTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputFile\r
-     * \r
+     *\r
      * This function is to set class member "outputFile"\r
-     * \r
+     *\r
      * @param outputFile\r
      *            string of output file name.\r
      */\r
@@ -175,9 +176,9 @@ public class StripTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
+     *\r
      * @return outputDir string of output directory.\r
      */\r
     public String getOutputDir() {\r
@@ -186,9 +187,9 @@ public class StripTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param outputDir\r
      *            string of output directory.\r
      */\r
index eb9707afe1bad4fe1c0f6677d70e59871e3fd497..ccba47d4a60b8f06cdb966dd56b974e094a10375 100644 (file)
@@ -2,14 +2,14 @@
  ZeroDebugDataTask class.\r
 \r
  ZeroDebugDataTask is used to call ZeroDebugData.exe to remove debug data.\r
\r
\r
+\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -24,7 +24,8 @@ import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.taskdefs.Execute;\r
 import org.apache.tools.ant.taskdefs.LogStreamHandler;\r
 import org.apache.tools.ant.types.Commandline;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
   ZeroDebugDataTask class.\r
@@ -50,10 +51,10 @@ public class ZeroDebugDataTask extends Task implements EfiDefine {
 \r
     /**\r
      * execute\r
-     * \r
+     *\r
      * ZeroDebugDataTask execute function is to assemble tool command line & execute\r
      * tool command line\r
-     * \r
+     *\r
      * @throws BuidException\r
      */\r
     public void execute() throws BuildException {\r
@@ -109,7 +110,7 @@ public class ZeroDebugDataTask extends Task implements EfiDefine {
             EdkLog.log(EdkLog.EDK_INFO, (new File(this.peFile)).getName());\r
 \r
             revl = runner.execute();\r
-            \r
+\r
             if (EFI_SUCCESS == revl) {\r
                 //\r
                 // command execution success\r
@@ -130,9 +131,9 @@ public class ZeroDebugDataTask extends Task implements EfiDefine {
 \r
     /**\r
      * getPeFile\r
-     * \r
+     *\r
      * This function is to get class member "inputFile".\r
-     * \r
+     *\r
      * @return string of input file name.\r
      */\r
     public String getPeFile() {\r
@@ -141,9 +142,9 @@ public class ZeroDebugDataTask extends Task implements EfiDefine {
 \r
     /**\r
      * setPeFile\r
-     * \r
+     *\r
      * This function is to set class member "peFile".\r
-     * \r
+     *\r
      * @param peFile\r
      *            string of input file name.\r
      */\r
@@ -153,9 +154,9 @@ public class ZeroDebugDataTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputFile\r
-     * \r
+     *\r
      * This function is to get class member "outputFile"\r
-     * \r
+     *\r
      * @return outputFile string of output file name.\r
      */\r
     public String getOutputFile() {\r
@@ -164,9 +165,9 @@ public class ZeroDebugDataTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputFile\r
-     * \r
+     *\r
      * This function is to set class member "outputFile"\r
-     * \r
+     *\r
      * @param outputFile\r
      *            string of output file name.\r
      */\r
@@ -176,9 +177,9 @@ public class ZeroDebugDataTask extends Task implements EfiDefine {
 \r
     /**\r
      * getOutputDir\r
-     * \r
+     *\r
      * This function is to get class member "outputDir"\r
-     * \r
+     *\r
      * @return outputDir string of output directory.\r
      */\r
     public String getOutputDir() {\r
@@ -187,9 +188,9 @@ public class ZeroDebugDataTask extends Task implements EfiDefine {
 \r
     /**\r
      * setOutputDir\r
-     * \r
+     *\r
      * This function is to set class member "outputDir"\r
-     * \r
+     *\r
      * @param outputDir\r
      *            string of output directory.\r
      */\r
index cdccfa5c096ed929bb11f4f4bf1cda36db1ce8a6..f7deb19e8fc548774408d0a89255f525509544d2 100644 (file)
@@ -1,9 +1,9 @@
 /** @file\r
-  This file is ANT task GenBuild. \r
\r
-  The file is used to parse a specified Module, and generate its build time \r
+  This file is ANT task GenBuild.\r
+\r
+  The file is used to parse a specified Module, and generate its build time\r
   ANT script build.xml, then call the the ANT script to build the module.\r
\r
+\r
 Copyright (c) 2006, Intel Corporation\r
 All rights reserved. This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
@@ -32,6 +32,8 @@ import org.apache.tools.ant.taskdefs.Ant;
 import org.apache.tools.ant.taskdefs.Property;\r
 import org.apache.xmlbeans.XmlObject;\r
 \r
+import org.tianocore.common.exception.EdkException;\r
+import org.tianocore.common.logger.EdkLog;\r
 import org.tianocore.build.autogen.AutoGen;\r
 import org.tianocore.build.fpd.FpdParserTask;\r
 import org.tianocore.build.global.GenBuildLogger;\r
@@ -43,8 +45,6 @@ import org.tianocore.build.id.ModuleIdentification;
 import org.tianocore.build.id.PackageIdentification;\r
 import org.tianocore.build.id.PlatformIdentification;\r
 import org.tianocore.build.tools.ModuleItem;\r
-import org.tianocore.exception.EdkException;\r
-import org.tianocore.logger.EdkLog;\r
 \r
 /**\r
   <p>\r
@@ -52,48 +52,48 @@ import org.tianocore.logger.EdkLog;
   system. The main function of this task is to parse module's surface area,\r
   then generate the corresponding <em>BaseName_build.xml</em> (the real ANT\r
   build script) and call this to build the module. The whole process including:\r
-  1. generate AutoGen.c and AutoGen.h; 2. build all dependent library instances; \r
+  1. generate AutoGen.c and AutoGen.h; 2. build all dependent library instances;\r
   3. build all source files inlcude AutoGen.c; 4. generate sections;\r
-  5. generate FFS file if it is driver module while LIB file if it is Library module. \r
+  5. generate FFS file if it is driver module while LIB file if it is Library module.\r
   </p>\r
-  \r
+\r
   <p>\r
   The usage is (take module <em>HelloWorld</em> for example):\r
   </p>\r
-  \r
+\r
   <pre>\r
-   &lt;GenBuild  \r
-             msaFilename=&quot;HelloWorld.msa&quot;/&gt; \r
+   &lt;GenBuild\r
+             msaFilename=&quot;HelloWorld.msa&quot;/&gt;\r
              processTo=&quot;ALL&quot;/&gt;\r
   </pre>\r
-  \r
-  <p><code>processTo</code> provides a way to customize the whole build process. \r
-  processTo can be one value of ALL, AUTOGEN, FILES, LIBRARYINSTANCES, SECTIONS, NONE. \r
-  Default is ALL, means whole \r
+\r
+  <p><code>processTo</code> provides a way to customize the whole build process.\r
+  processTo can be one value of ALL, AUTOGEN, FILES, LIBRARYINSTANCES, SECTIONS, NONE.\r
+  Default is ALL, means whole\r
   </p>\r
-  \r
+\r
   <p>\r
   This task calls <code>AutoGen</code> to generate <em>AutoGen.c</em> and\r
   <em>AutoGen.h</em>. The task also parses the development environment\r
   configuration files, such as collecting package information, setting compiler\r
   flags and so on.\r
   </p>\r
-  \r
-  \r
+\r
+\r
   @since GenBuild 1.0\r
 **/\r
 public class GenBuildTask extends Ant {\r
-    \r
+\r
     ///\r
     /// Module surface area file.\r
     ///\r
     File msaFile;\r
 \r
     ///\r
-    /// \r
+    ///\r
     ///\r
     private String type = "all"; // = "build";\r
-    \r
+\r
     ///\r
     /// Module's Identification.\r
     ///\r
@@ -102,9 +102,9 @@ public class GenBuildTask extends Ant {
     private Vector<Property> properties = new Vector<Property>();\r
 \r
     private static Stack<Hashtable> backupPropertiesStack = new Stack<Hashtable>();\r
-    \r
+\r
     private boolean isSingleModuleBuild = false;\r
-    \r
+\r
     /**\r
       Public construct method. It is necessary for ANT task.\r
     **/\r
@@ -112,7 +112,7 @@ public class GenBuildTask extends Ant {
     }\r
 \r
     /**\r
-  \r
+\r
       @throws BuildException\r
               From module build, exception from module surface area invalid.\r
     **/\r
@@ -134,7 +134,7 @@ public class GenBuildTask extends Ant {
             Property item = iter.next();\r
             getProject().setProperty(item.getName(), item.getValue());\r
         }\r
-        \r
+\r
         //\r
         // GenBuild should specify either msaFile or moduleGuid & packageGuid\r
         //\r
@@ -165,7 +165,7 @@ public class GenBuildTask extends Ant {
         else {\r
             moduleId.setLibrary(true);\r
         }\r
-        \r
+\r
         //\r
         // Judge whether it is single module build or not\r
         //\r
@@ -183,29 +183,29 @@ public class GenBuildTask extends Ant {
             PlatformIdentification platformId = GlobalData.getPlatform(filename);\r
             getProject().setProperty("PLATFORM_DIR", platformId.getFpdFile().getParent().replaceAll("(\\\\)", "/"));\r
             getProject().setProperty("PLATFORM_RELATIVE_DIR", platformId.getPlatformRelativeDir().replaceAll("(\\\\)", "/"));\r
-            \r
+\r
             String packageGuid = getProject().getProperty("PACKAGE_GUID");\r
             String packageVersion = getProject().getProperty("PACKAGE_VERSION");\r
             PackageIdentification packageId = new PackageIdentification(packageGuid, packageVersion);\r
             moduleId.setPackage(packageId);\r
         }\r
-        \r
+\r
         //\r
         // If single module : intersection MSA supported ARCHs and tools def!!\r
         // else, get arch from pass down\r
         //\r
-        Set<String> archListSupByToolChain = new LinkedHashSet<String>(); \r
-        String[] archs = GlobalData.getToolChainInfo().getArchs(); \r
-        \r
+        Set<String> archListSupByToolChain = new LinkedHashSet<String>();\r
+        String[] archs = GlobalData.getToolChainInfo().getArchs();\r
+\r
         for (int i = 0; i < archs.length; i ++) {\r
             archListSupByToolChain.add(archs[i]);\r
         }\r
-        \r
+\r
         Set<String> archSet = new LinkedHashSet<String>();\r
-        \r
+\r
         if ( getProject().getProperty("ARCH") != null) {\r
             String[] fpdArchList = getProject().getProperty("ARCH").split(" ");\r
-            \r
+\r
             for (int i = 0; i < fpdArchList.length; i++) {\r
                 if (archListSupByToolChain.contains(fpdArchList[i])) {\r
                     archSet.add(fpdArchList[i]);\r
@@ -213,11 +213,11 @@ public class GenBuildTask extends Ant {
             }\r
         }\r
         else {\r
-            archSet = archListSupByToolChain; \r
+            archSet = archListSupByToolChain;\r
         }\r
-  \r
+\r
         String[] archList = archSet.toArray(new String[archSet.size()]);\r
-        \r
+\r
         //\r
         // Judge if arch is all supported by current module. If not, throw Exception.\r
         //\r
@@ -229,13 +229,13 @@ public class GenBuildTask extends Ant {
                 }\r
             }\r
         }\r
-        \r
+\r
         for (int k = 0; k < archList.length; k++) {\r
-            \r
+\r
             getProject().setProperty("ARCH", archList[k]);\r
-            \r
+\r
             FpdModuleIdentification fpdModuleId = new FpdModuleIdentification(moduleId, archList[k]);\r
-            \r
+\r
             //\r
             // Whether the module is built before\r
             //\r
@@ -247,7 +247,7 @@ public class GenBuildTask extends Ant {
             } else {\r
                 GlobalData.registerBuiltModule(fpdModuleId);\r
             }\r
-            \r
+\r
             //\r
             // For Every TOOLCHAIN, TARGET\r
             //\r
@@ -263,7 +263,7 @@ public class GenBuildTask extends Ant {
                     //\r
                     // check if any tool is defined for current target + toolchain + arch\r
                     // don't do anything if no tools found\r
-                    // \r
+                    //\r
                     if (GlobalData.isCommandSet(targetList[i], toolchainList[j], archList[k]) == false) {\r
                         System.out.println("Warning: No build issued.  No tools were found for [target=" + targetList[i] + " toolchain=" + toolchainList[j] + " arch=" + archList[k] + "]\n");\r
                         continue;\r
@@ -278,7 +278,7 @@ public class GenBuildTask extends Ant {
                     System.out.println("Build " + moduleId + " start >>>");\r
                     System.out.println("Target: " + targetList[i] + " Tagname: " + toolchainList[j] + " Arch: " + archList[k]);\r
                     SurfaceAreaQuery.setDoc(GlobalData.getDoc(fpdModuleId));\r
-                    \r
+\r
                     //\r
                     // Prepare for all other common properties\r
                     // PACKAGE, PACKAGE_GUID, PACKAGE_VERSION, PACKAGE_DIR, PACKAGE_RELATIVE_DIR\r
@@ -287,13 +287,13 @@ public class GenBuildTask extends Ant {
                     // SUBSYSTEM, ENTRYPOINT, EBC_TOOL_LIB_PATH\r
                     //\r
                     setModuleCommonProperties(archList[k]);\r
-                    \r
+\r
                     //\r
-                    // OutputManage prepare for \r
+                    // OutputManage prepare for\r
                     // BIN_DIR, DEST_DIR_DEBUG, DEST_DIR_OUTPUT, BUILD_DIR, FV_DIR\r
                     //\r
                     OutputManager.getInstance().update(getProject());\r
-                    \r
+\r
                     if (type.equalsIgnoreCase("all") || type.equalsIgnoreCase("build")) {\r
                         applyBuild(targetList[i], toolchainList[j], fpdModuleId);\r
                     }\r
@@ -313,13 +313,13 @@ public class GenBuildTask extends Ant {
     }\r
 \r
     /**\r
-      This method is used to prepare Platform-related information. \r
-      \r
+      This method is used to prepare Platform-related information.\r
+\r
       <p>In Single Module Build mode, platform-related information is not ready.\r
-      The method read the system environment variable <code>ACTIVE_PLATFORM</code> \r
+      The method read the system environment variable <code>ACTIVE_PLATFORM</code>\r
       and search in the Framework Database. Note that platform name in the Framework\r
       Database must be unique. </p>\r
-     \r
+\r
     **/\r
     private void prepareSingleModuleBuild(){\r
         //\r
@@ -327,27 +327,27 @@ public class GenBuildTask extends Ant {
         // TBD: Enhance it!!!!\r
         //\r
         PackageIdentification packageId = GlobalData.getPackageForModule(moduleId);\r
-        \r
+\r
         moduleId.setPackage(packageId);\r
-        \r
+\r
         //\r
         // Read ACTIVE_PLATFORM's FPD file (Call FpdParserTask's method)\r
         //\r
         String filename = getProject().getProperty("PLATFORM_FILE");\r
-        \r
+\r
         if (filename == null){\r
             throw new BuildException("Please set ACTIVE_PLATFORM in the file: Tools/Conf/target.txt if you want to build a single module!");\r
         }\r
-        \r
+\r
         PlatformIdentification platformId = GlobalData.getPlatform(filename);\r
-        \r
+\r
         //\r
         // Read FPD file\r
         //\r
         FpdParserTask fpdParser = new FpdParserTask();\r
         fpdParser.setProject(getProject());\r
         fpdParser.parseFpdFile(platformId.getFpdFile());\r
-        \r
+\r
         //\r
         // Prepare for Platform related common properties\r
         // PLATFORM, PLATFORM_DIR, PLATFORM_RELATIVE_DIR\r
@@ -372,7 +372,7 @@ public class GenBuildTask extends Ant {
         getProject().setProperty("PACKAGE_VERSION", packageId.getVersion());\r
         getProject().setProperty("PACKAGE_DIR", packageId.getPackageDir().replaceAll("(\\\\)", "/"));\r
         getProject().setProperty("PACKAGE_RELATIVE_DIR", packageId.getPackageRelativeDir().replaceAll("(\\\\)", "/"));\r
-        \r
+\r
         //\r
         // MODULE or BASE_NAME, GUID or FILE_GUID, VERSION, MODULE_TYPE\r
         // MODULE_DIR, MODULE_RELATIVE_DIR\r
@@ -391,24 +391,24 @@ public class GenBuildTask extends Ant {
         getProject().setProperty("MODULE_TYPE", moduleId.getModuleType());\r
         getProject().setProperty("MODULE_DIR", moduleId.getMsaFile().getParent().replaceAll("(\\\\)", "/"));\r
         getProject().setProperty("MODULE_RELATIVE_DIR", moduleId.getModuleRelativePath().replaceAll("(\\\\)", "/"));\r
-        \r
+\r
         //\r
         // SUBSYSTEM\r
         //\r
         String[][] subsystemMap = { { "BASE", "EFI_BOOT_SERVICE_DRIVER"},\r
-                                    { "SEC", "EFI_BOOT_SERVICE_DRIVER" }, \r
-                                    { "PEI_CORE", "EFI_BOOT_SERVICE_DRIVER" }, \r
-                                    { "PEIM", "EFI_BOOT_SERVICE_DRIVER" }, \r
+                                    { "SEC", "EFI_BOOT_SERVICE_DRIVER" },\r
+                                    { "PEI_CORE", "EFI_BOOT_SERVICE_DRIVER" },\r
+                                    { "PEIM", "EFI_BOOT_SERVICE_DRIVER" },\r
                                     { "DXE_CORE", "EFI_BOOT_SERVICE_DRIVER" },\r
-                                    { "DXE_DRIVER", "EFI_BOOT_SERVICE_DRIVER" }, \r
-                                    { "DXE_RUNTIME_DRIVER", "EFI_RUNTIME_DRIVER" }, \r
-                                    { "DXE_SAL_DRIVER", "EFI_BOOT_SERVICE_DRIVER" }, \r
-                                    { "DXE_SMM_DRIVER", "EFI_BOOT_SERVICE_DRIVER" }, \r
-                                    { "TOOL", "EFI_BOOT_SERVICE_DRIVER" }, \r
+                                    { "DXE_DRIVER", "EFI_BOOT_SERVICE_DRIVER" },\r
+                                    { "DXE_RUNTIME_DRIVER", "EFI_RUNTIME_DRIVER" },\r
+                                    { "DXE_SAL_DRIVER", "EFI_BOOT_SERVICE_DRIVER" },\r
+                                    { "DXE_SMM_DRIVER", "EFI_BOOT_SERVICE_DRIVER" },\r
+                                    { "TOOL", "EFI_BOOT_SERVICE_DRIVER" },\r
                                     { "UEFI_DRIVER", "EFI_BOOT_SERVICE_DRIVER" },\r
-                                    { "UEFI_APPLICATION", "EFI_APPLICATION" }, \r
-                                    { "USER_DEFINED", "EFI_BOOT_SERVICE_DRIVER"} }; \r
-        \r
+                                    { "UEFI_APPLICATION", "EFI_APPLICATION" },\r
+                                    { "USER_DEFINED", "EFI_BOOT_SERVICE_DRIVER"} };\r
+\r
         String subsystem = "EFI_BOOT_SERVICE_DRIVER";\r
         for (int i = 0; i < subsystemMap.length; i++) {\r
             if (moduleId.getModuleType().equalsIgnoreCase(subsystemMap[i][0])) {\r
@@ -417,7 +417,7 @@ public class GenBuildTask extends Ant {
             }\r
         }\r
         getProject().setProperty("SUBSYSTEM", subsystem);\r
-        \r
+\r
         //\r
         // ENTRYPOINT\r
         //\r
@@ -427,7 +427,7 @@ public class GenBuildTask extends Ant {
         else {\r
             getProject().setProperty("ENTRYPOINT", "_ModuleEntryPoint");\r
         }\r
-        \r
+\r
         getProject().setProperty("OBJECTS", "");\r
     }\r
 \r
@@ -444,7 +444,7 @@ public class GenBuildTask extends Ant {
             String cmdName = GlobalData.getCommandSetting(key, fpdModuleId);\r
             File cmdFile = new File(cmdPath + File.separatorChar + cmdName);\r
             getProject().setProperty(cmd[m], cmdFile.getPath().replaceAll("(\\\\)", "/"));\r
-            \r
+\r
             //\r
             // set CC_FLAGS\r
             //\r
@@ -454,7 +454,7 @@ public class GenBuildTask extends Ant {
             Set<String> subset = new LinkedHashSet<String>();\r
             putFlagsToSet(addset, cmdFlags);\r
             getProject().setProperty(cmd[m] + "_FLAGS", getProject().replaceProperties(getFlags(addset, subset)));\r
-            \r
+\r
             //\r
             // Set CC_EXT\r
             //\r
@@ -466,7 +466,7 @@ public class GenBuildTask extends Ant {
             else {\r
                 getProject().setProperty(cmd[m] + "_EXT", "");\r
             }\r
-            \r
+\r
             //\r
             // set CC_FAMILY\r
             //\r
@@ -475,7 +475,7 @@ public class GenBuildTask extends Ant {
             if (toolChainFamily != null) {\r
                 getProject().setProperty(cmd[m] + "_FAMILY", toolChainFamily);\r
             }\r
-            \r
+\r
             //\r
             // set CC_SPATH\r
             //\r
@@ -487,7 +487,7 @@ public class GenBuildTask extends Ant {
             else {\r
                 getProject().setProperty(cmd[m] + "_SPATH", "");\r
             }\r
-            \r
+\r
             //\r
             // set CC_DPATH\r
             //\r
@@ -501,19 +501,19 @@ public class GenBuildTask extends Ant {
             }\r
         }\r
     }\r
-    \r
+\r
     public void setMsaFile(File msaFile) {\r
         this.msaFile = msaFile;\r
     }\r
 \r
     /**\r
-      Method is for ANT to initialize MSA file. \r
-      \r
+      Method is for ANT to initialize MSA file.\r
+\r
       @param msaFilename MSA file name\r
     **/\r
     public void setMsaFile(String msaFilename) {\r
         String moduleDir = getProject().getProperty("MODULE_DIR");\r
-        \r
+\r
         //\r
         // If is Single Module Build, then use the Base Dir defined in build.xml\r
         //\r
@@ -522,17 +522,17 @@ public class GenBuildTask extends Ant {
         }\r
         msaFile = new File(moduleDir + File.separatorChar + msaFilename);\r
     }\r
-    \r
+\r
     public void addConfiguredModuleItem(ModuleItem moduleItem) {\r
         PackageIdentification packageId = new PackageIdentification(moduleItem.getPackageGuid(), moduleItem.getPackageVersion());\r
         ModuleIdentification moduleId = new ModuleIdentification(moduleItem.getModuleGuid(), moduleItem.getModuleVersion());\r
         moduleId.setPackage(packageId);\r
         this.moduleId = moduleId;\r
     }\r
-    \r
+\r
     /**\r
-      Add a property. \r
-    \r
+      Add a property.\r
+\r
       @param p property\r
     **/\r
     public void addProperty(Property p) {\r
@@ -542,21 +542,21 @@ public class GenBuildTask extends Ant {
     public void setType(String type) {\r
         this.type = type;\r
     }\r
-    \r
+\r
     private void applyBuild(String buildTarget, String buildTagname, FpdModuleIdentification fpdModuleId) throws EdkException{\r
         //\r
         // AutoGen\r
         //\r
-        \r
+\r
         AutoGen autogen = new AutoGen(getProject().getProperty("FV_DIR"), getProject().getProperty("DEST_DIR_DEBUG"), fpdModuleId.getModule(),fpdModuleId.getArch());\r
         autogen.genAutogen();\r
-        \r
-        \r
+\r
+\r
         //\r
         // Get compiler flags\r
         //\r
         getCompilerFlags(buildTarget, buildTagname, fpdModuleId);\r
-        \r
+\r
         //\r
         // Prepare LIBS\r
         //\r
@@ -566,7 +566,7 @@ public class GenBuildTask extends Ant {
             propertyLibs += " " + getProject().getProperty("BIN_DIR") + File.separatorChar + libinstances[i].getName() + ".lib";\r
         }\r
         getProject().setProperty("LIBS", propertyLibs.replaceAll("(\\\\)", "/"));\r
-        \r
+\r
         //\r
         // if it is CUSTOM_BUILD\r
         // then call the exist BaseName_build.xml directly.\r
@@ -581,7 +581,7 @@ public class GenBuildTask extends Ant {
             ant.execute();\r
             return ;\r
         }\r
-        \r
+\r
         //\r
         // Generate ${BASE_NAME}_build.xml\r
         // TBD\r
@@ -590,7 +590,7 @@ public class GenBuildTask extends Ant {
         ModuleBuildFileGenerator fileGenerator = new ModuleBuildFileGenerator(getProject(), ffsKeyword, fpdModuleId);\r
         String buildFilename = getProject().getProperty("DEST_DIR_OUTPUT") + File.separatorChar + moduleId.getName() + "_build.xml";\r
         fileGenerator.genBuildFile(buildFilename);\r
-        \r
+\r
         //\r
         // Ant call ${BASE_NAME}_build.xml\r
         //\r
@@ -601,7 +601,7 @@ public class GenBuildTask extends Ant {
         ant.init();\r
         ant.execute();\r
     }\r
-    \r
+\r
     private void applyClean(FpdModuleIdentification fpdModuleId){\r
         //\r
         // if it is CUSTOM_BUILD\r
@@ -618,7 +618,7 @@ public class GenBuildTask extends Ant {
             ant.execute();\r
             return ;\r
         }\r
-        \r
+\r
         Ant ant = new Ant();\r
         ant.setProject(getProject());\r
         ant.setAntfile(getProject().getProperty("DEST_DIR_OUTPUT") + File.separatorChar + moduleId.getName() + "_build.xml");\r
@@ -626,12 +626,12 @@ public class GenBuildTask extends Ant {
         ant.setInheritAll(true);\r
         ant.init();\r
         ant.execute();\r
-        \r
+\r
         //\r
         // Delete current module's DEST_DIR_OUTPUT\r
         // TBD\r
     }\r
-    \r
+\r
     private void applyCleanall(FpdModuleIdentification fpdModuleId){\r
         //\r
         // if it is CUSTOM_BUILD\r
@@ -648,7 +648,7 @@ public class GenBuildTask extends Ant {
             ant.execute();\r
             return ;\r
         }\r
-        \r
+\r
         Ant ant = new Ant();\r
         ant.setProject(getProject());\r
         ant.setAntfile(getProject().getProperty("DEST_DIR_OUTPUT") + File.separatorChar + moduleId.getName() + "_build.xml");\r
@@ -656,7 +656,7 @@ public class GenBuildTask extends Ant {
         ant.setInheritAll(true);\r
         ant.init();\r
         ant.execute();\r
-        \r
+\r
         //\r
         // Delete current module's DEST_DIR_OUTPUT\r
         // TBD\r
@@ -667,17 +667,17 @@ public class GenBuildTask extends Ant {
 \r
     /**\r
       Separate the string and instore in set.\r
-       \r
-      <p> String is separated by Java Regulation Expression \r
+\r
+      <p> String is separated by Java Regulation Expression\r
       "[^\\\\]?(\".*?[^\\\\]\")[ \t,]+". </p>\r
-      \r
+\r
       <p>For example: </p>\r
-      \r
+\r
       <pre>\r
         "/nologo", "/W3", "/WX"\r
         "/C", "/DSTRING_DEFINES_FILE=\"BdsStrDefs.h\""\r
       </pre>\r
-      \r
+\r
       @param set store the separated string\r
       @param str string to separate\r
     **/\r
@@ -693,10 +693,10 @@ public class GenBuildTask extends Ant {
             set.add(item);\r
         }\r
     }\r
-    \r
+\r
     /**\r
-      Generate the final flags string will be used by compile command. \r
-      \r
+      Generate the final flags string will be used by compile command.\r
+\r
       @param add the add flags set\r
       @param sub the sub flags set\r
       @return final flags after add set substract sub set\r
@@ -715,7 +715,7 @@ public class GenBuildTask extends Ant {
     private void pushProperties() {\r
         backupPropertiesStack.push(getProject().getProperties());\r
     }\r
-    \r
+\r
     private void popProperties() {\r
         Hashtable backupProperties = backupPropertiesStack.pop();\r
         Set keys = backupProperties.keySet();\r
index 0704bf44119b1bec734773634e8d9b1f923f1037..c3d371e33991dd9caa4e37f7209bc06d26913aef 100644 (file)
@@ -3,13 +3,13 @@
 \r
  This class is to generate Autogen.h and Autogen.c according to module surface area\r
  or library surface area.\r
\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
  which accompanies this distribution.  The full text of the license may be found at\r
  http://opensource.org/licenses/bsd-license.php\r
\r
+\r
  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
@@ -44,7 +44,8 @@ import org.tianocore.build.global.SurfaceAreaQuery;
 import org.tianocore.build.id.ModuleIdentification;\r
 import org.tianocore.build.id.PackageIdentification;\r
 import org.tianocore.build.pcd.action.PCDAutoGenAction;\r
-import org.tianocore.logger.EdkLog;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 \r
 /**\r
  * This class is to generate Autogen.h and Autogen.c according to module surface\r
@@ -55,9 +56,9 @@ public class AutoGen {
        // / The output path of Autogen.h and Autogen.c\r
        // /\r
        private String outputPath;\r
-    /// \r
-    /// The name of FV directory \r
-    /// \r
+    ///\r
+    /// The name of FV directory\r
+    ///\r
     private String fvDir;\r
        // /\r
        // / The base name of module or library.\r
@@ -92,7 +93,7 @@ public class AutoGen {
        // / dependence on library instance surface area.\r
        // /\r
        private Set<String> mGuidList = new HashSet<String>();\r
-    \r
+\r
     //\r
     // The dependence package list which recoreded in module or library surface\r
     // area and it's dependence on library instance surface are.\r
@@ -100,24 +101,24 @@ public class AutoGen {
     private List<PackageIdentification> mDepPkgList = new LinkedList<PackageIdentification>();\r
 \r
        //\r
-       //  For non library module, add its library instance's construct and destructor to \r
+       //  For non library module, add its library instance's construct and destructor to\r
        //  list.\r
-       //  \r
+       //\r
        private List<String> libConstructList = new ArrayList<String>();\r
        private List<String> libDestructList = new ArrayList<String>();\r
 \r
        //\r
-       // List to store SetVirtalAddressMapCallBack, ExitBootServiceCallBack  \r
-       // \r
+       // List to store SetVirtalAddressMapCallBack, ExitBootServiceCallBack\r
+       //\r
        private List<String> setVirtalAddList = new ArrayList<String>();\r
        private List<String> exitBootServiceList = new ArrayList<String>();\r
 \r
-       \r
+\r
        /**\r
         * Construct function\r
-        * \r
+        *\r
         * This function mainly initialize some member variable.\r
-        * \r
+        *\r
         * @param outputPath\r
         *            Output path of AutoGen file.\r
         * @param baseName\r
@@ -135,9 +136,9 @@ public class AutoGen {
 \r
        /**\r
         * saveFile function\r
-        * \r
+        *\r
         * This function save the content in stringBuffer to file.\r
-        * \r
+        *\r
         * @param fileName\r
         *            The name of file.\r
         * @param fileBuffer\r
@@ -176,10 +177,10 @@ public class AutoGen {
 \r
        /**\r
         * genAutogen function\r
-        * \r
+        *\r
         * This function call libGenAutoGen or moduleGenAutogen function, which\r
         * dependence on generate library autogen or module autogen.\r
-        * \r
+        *\r
         * @throws BuildException\r
         *             Failed to creat AutoGen.c & AutoGen.h.\r
         */\r
@@ -210,9 +211,9 @@ public class AutoGen {
 \r
        /**\r
         * moduleGenAutogen function\r
-        * \r
+        *\r
         * This function generates AutoGen.c & AutoGen.h for module.\r
-        * \r
+        *\r
         * @throws BuildException\r
         *             Faile to create module AutoGen.c & AutoGen.h.\r
         */\r
@@ -231,9 +232,9 @@ public class AutoGen {
 \r
        /**\r
         * libGenAutogen function\r
-        * \r
+        *\r
         * This function generates AutoGen.c & AutoGen.h for library.\r
-        * \r
+        *\r
         * @throws BuildException\r
         *             Faile to create library AutoGen.c & AutoGen.h\r
         */\r
@@ -250,9 +251,9 @@ public class AutoGen {
 \r
        /**\r
         * moduleGenAutogenH\r
-        * \r
+        *\r
         * This function generates AutoGen.h for module.\r
-        * \r
+        *\r
         * @throws BuildException\r
         *             Failed to generate AutoGen.h.\r
         */\r
@@ -340,9 +341,9 @@ public class AutoGen {
                fileBuffer.append("\r\n");\r
 \r
         //\r
-        //  If is TianoR8FlashMap, copy {Fv_DIR}/FlashMap.h to \r
+        //  If is TianoR8FlashMap, copy {Fv_DIR}/FlashMap.h to\r
         // {DEST_DIR_DRBUG}/FlashMap.h\r
-        // \r
+        //\r
         if (SurfaceAreaQuery.isHaveTianoR8FlashMap()) {\r
             fileBuffer.append(CommonDefinition.include);\r
             fileBuffer.append("  <");\r
@@ -372,9 +373,9 @@ public class AutoGen {
 \r
        /**\r
         * moduleGenAutogenC\r
-        * \r
+        *\r
         * This function generates AutoGen.c for module.\r
-        * \r
+        *\r
         * @throws BuildException\r
         *             Failed to generate AutoGen.c.\r
         */\r
@@ -452,7 +453,7 @@ public class AutoGen {
                // autogen.c\r
                //\r
         LibInstanceToAutogenC(fileBuffer);\r
-        \r
+\r
         //\r
         // Get module dependent Package identification.\r
         //\r
@@ -461,9 +462,9 @@ public class AutoGen {
             if (!this.mDepPkgList.contains(packages[i])){\r
                 this.mDepPkgList.add(packages[i]);\r
             }\r
-            \r
+\r
         }\r
-      \r
+\r
                //\r
                // Write consumed ppi, guid, protocol to autogen.c\r
                //\r
@@ -472,7 +473,7 @@ public class AutoGen {
                GuidGuidToAutogenC(fileBuffer);\r
 \r
                //\r
-               // Call pcd autogen. \r
+               // Call pcd autogen.\r
                //\r
                 this.myPcdAutogen = new PCDAutoGenAction(moduleId, this.arch, false, null);\r
                 try {\r
@@ -480,7 +481,7 @@ public class AutoGen {
                 } catch (Exception exp) {\r
                     throw new PcdAutogenException (exp.getMessage());\r
                 }\r
-               \r
+\r
                if (this.myPcdAutogen != null) {\r
                     fileBuffer.append("\r\n");\r
                     fileBuffer.append(this.myPcdAutogen.OutputC());\r
@@ -494,9 +495,9 @@ public class AutoGen {
 \r
        /**\r
         * libGenAutogenH\r
-        * \r
+        *\r
         * This function generates AutoGen.h for library.\r
-        * \r
+        *\r
         * @throws BuildException\r
         *             Failed to generate AutoGen.c.\r
         */\r
@@ -537,7 +538,7 @@ public class AutoGen {
 \r
                //\r
                // Write consumed package's mdouleInfo related *.h file to autogen.h.\r
-               // \r
+               //\r
                moduleType = SurfaceAreaQuery.getModuleType();\r
                PackageIdentification[] cosumedPkglist = SurfaceAreaQuery\r
                                .getDependencePkg(this.arch);\r
@@ -571,9 +572,9 @@ public class AutoGen {
                fileBuffer.append("\r\n");\r
 \r
         //\r
-        //  If is TianoR8FlashMap, copy {Fv_DIR}/FlashMap.h to \r
+        //  If is TianoR8FlashMap, copy {Fv_DIR}/FlashMap.h to\r
         // {DEST_DIR_DRBUG}/FlashMap.h\r
-        // \r
+        //\r
         if (SurfaceAreaQuery.isHaveTianoR8FlashMap()) {\r
             fileBuffer.append(CommonDefinition.include);\r
             fileBuffer.append("  <");\r
@@ -604,9 +605,9 @@ public class AutoGen {
 \r
        /**\r
         * libGenAutogenC\r
-        * \r
+        *\r
         * This function generates AutoGen.h for library.\r
-        * \r
+        *\r
         * @throws BuildException\r
         *             Failed to generate AutoGen.c.\r
         */\r
@@ -622,11 +623,11 @@ public class AutoGen {
                fileBuffer.append("\r\n");\r
 \r
                //\r
-               // Call pcd autogen. \r
+               // Call pcd autogen.\r
                //\r
                 this.myPcdAutogen = new PCDAutoGenAction(this.moduleId,\r
                                                          this.arch,\r
-                                                         true, \r
+                                                         true,\r
                                                          SurfaceAreaQuery.getModulePcdEntryNameArray());\r
                try {\r
                     this.myPcdAutogen.execute();\r
@@ -646,10 +647,10 @@ public class AutoGen {
 \r
        /**\r
         * LibraryClassToAutogenH\r
-        * \r
+        *\r
         * This function returns *.h files declared by library classes which are\r
         * consumed or produced by current build module or library.\r
-        * \r
+        *\r
         * @param libClassList\r
         *            List of library class which consumed or produce by current\r
         *            build module or library.\r
@@ -689,9 +690,9 @@ public class AutoGen {
 \r
        /**\r
         * IncludesToAutogenH\r
-        * \r
+        *\r
         * This function add include file in AutoGen.h file.\r
-        * \r
+        *\r
         * @param packageNameList\r
         *            List of module depended package.\r
         * @param moduleType\r
@@ -727,10 +728,10 @@ public class AutoGen {
 \r
        /**\r
         * EntryPointToAutoGen\r
-        * \r
+        *\r
         * This function convert <ModuleEntryPoint> & <ModuleUnloadImage>\r
         * information in mas to AutoGen.c\r
-        * \r
+        *\r
         * @param entryPointList\r
         *            List of entry point.\r
         * @param fileBuffer\r
@@ -833,7 +834,7 @@ public class AutoGen {
                                                        .append("  IN EFI_PEI_SERVICES     **PeiServices\r\n");\r
                                        fileBuffer.append("  );\r\n");\r
                                        entryPointCount++;\r
-                       \r
+\r
                        }\r
 \r
                        fileBuffer.append("EFI_STATUS\r\n");\r
@@ -918,7 +919,7 @@ public class AutoGen {
                 fileBuffer.append("  )\r\n\r\n");\r
                 fileBuffer.append("{\r\n");\r
 \r
-                \r
+\r
                 for (int i = 0; i < entryPointList.length; i++) {\r
                     fileBuffer\r
                             .append("  if (SetJump (&mJumpContext) == 0) {\r\n");\r
@@ -927,7 +928,7 @@ public class AutoGen {
                     fileBuffer.append(" (ImageHandle, SystemTable));\r\n");\r
                     fileBuffer.append("    ASSERT (FALSE);\r\n");\r
                     fileBuffer.append("  }\r\n");\r
-                \r
+\r
                 }\r
                 fileBuffer.append("  return mDriverEntryPointStatus;\r\n");\r
                 fileBuffer.append("}\r\n\r\n");\r
@@ -945,10 +946,10 @@ public class AutoGen {
                 fileBuffer.append("  LongJump (&mJumpContext, (UINTN)-1);\r\n");\r
                 fileBuffer.append("  ASSERT (FALSE);\r\n");\r
                 fileBuffer.append("}\r\n\r\n");\r
-    \r
+\r
             }\r
-                \r
-                       \r
+\r
+\r
                        //\r
                        // Add "ModuleUnloadImage" for DxeSmmDriver module type;\r
                        //\r
@@ -1034,10 +1035,10 @@ public class AutoGen {
                                fileBuffer.append("{\r\n");\r
                                fileBuffer.append("  return EFI_SUCCESS;\r\n");\r
                                fileBuffer.append("}\r\n");\r
-                               \r
+\r
                        }else {\r
                 for (int i = 0; i < entryPointList.length; i++) {\r
-                    \r
+\r
                     fileBuffer.append("EFI_STATUS\r\n");\r
                     fileBuffer.append("EFIAPI\r\n");\r
                     fileBuffer.append(entryPointList[i]);\r
@@ -1114,7 +1115,7 @@ public class AutoGen {
                 fileBuffer.append("}\r\n\r\n");\r
 \r
             }\r
-                       \r
+\r
                        //\r
                        // Add ModuleUnloadImage for DxeDriver and UefiDriver module type.\r
                        //\r
@@ -1184,10 +1185,10 @@ public class AutoGen {
 \r
        /**\r
         * PpiGuidToAutogenc\r
-        * \r
+        *\r
         * This function gets GUIDs from SPD file accrodeing to <PPIs> information\r
         * and write those GUIDs to AutoGen.c.\r
-        * \r
+        *\r
         * @param fileBuffer\r
         *            String Buffer for Autogen.c file.\r
         * @throws BuildException\r
@@ -1200,7 +1201,7 @@ public class AutoGen {
                // Get the all PPI adn PPI Notify from MSA file,\r
                // then add those PPI ,and PPI Notify name to list.\r
                //\r
-               \r
+\r
                String[] ppiList = SurfaceAreaQuery.getPpiArray(this.arch);\r
                for (int i = 0; i < ppiList.length; i++) {\r
                        this.mPpiList.add(ppiList[i]);\r
@@ -1238,10 +1239,10 @@ public class AutoGen {
 \r
        /**\r
         * ProtocolGuidToAutogenc\r
-        * \r
+        *\r
         * This function gets GUIDs from SPD file accrodeing to <Protocol>\r
         * information and write those GUIDs to AutoGen.c.\r
-        * \r
+        *\r
         * @param fileBuffer\r
         *            String Buffer for Autogen.c file.\r
         * @throws BuildException\r
@@ -1271,8 +1272,8 @@ public class AutoGen {
                //\r
                Iterator protocolIterator = this.mProtocolList.iterator();\r
                String protocolKeyWord = null;\r
-               \r
-      \r
+\r
+\r
                while (protocolIterator.hasNext()) {\r
                        protocolKeyWord = protocolIterator.next().toString();\r
                        cNameGuid = GlobalData.getProtocolGuid(this.mDepPkgList, protocolKeyWord);\r
@@ -1295,13 +1296,13 @@ public class AutoGen {
 \r
        /**\r
         * GuidGuidToAutogenc\r
-        * \r
+        *\r
         * This function gets GUIDs from SPD file accrodeing to <Guids> information\r
         * and write those GUIDs to AutoGen.c.\r
-        * \r
+        *\r
         * @param fileBuffer\r
         *            String Buffer for Autogen.c file.\r
-        * \r
+        *\r
         */\r
        void GuidGuidToAutogenC(StringBuffer fileBuffer) throws AutoGenException {\r
                String[] cNameGuid = null;\r
@@ -1339,11 +1340,11 @@ public class AutoGen {
 \r
        /**\r
         * LibInstanceToAutogenC\r
-        * \r
+        *\r
         * This function adds dependent library instance to autogen.c,which\r
         * includeing library's constructor, destructor, and library dependent ppi,\r
         * protocol, guid, pcd information.\r
-        * \r
+        *\r
         * @param fileBuffer\r
         *            String buffer for AutoGen.c\r
         * @throws BuildException\r
@@ -1367,10 +1368,10 @@ public class AutoGen {
 \r
        /**\r
         * LibConstructorToAutogenc\r
-        * \r
+        *\r
         * This function writes library constructor list to AutoGen.c. The library\r
         * constructor's parameter and return value depend on module type.\r
-        * \r
+        *\r
         * @param libInstanceList\r
         *            List of library construct name.\r
         * @param moduleType\r
@@ -1508,10 +1509,10 @@ public class AutoGen {
 \r
        /**\r
         * LibDestructorToAutogenc\r
-        * \r
+        *\r
         * This function writes library destructor list to AutoGen.c. The library\r
         * destructor's parameter and return value depend on module type.\r
-        * \r
+        *\r
         * @param libInstanceList\r
         *            List of library destructor name.\r
         * @param moduleType\r
@@ -1588,7 +1589,7 @@ public class AutoGen {
             //\r
             // If no library destructor function, return EFI_SUCCESS.\r
             //\r
-            \r
+\r
                        for (int i = 0; i < libInstanceList.size(); i++) {\r
                                if (isFirst) {\r
                                        fileBuffer.append("  EFI_STATUS  Status;\r\n");\r
@@ -1608,10 +1609,10 @@ public class AutoGen {
 \r
        /**\r
         * ExternsDriverBindingToAutoGenC\r
-        * \r
+        *\r
         * This function is to write DRIVER_BINDING, COMPONENT_NAME,\r
         * DRIVER_CONFIGURATION, DRIVER_DIAGNOSTIC in AutoGen.c.\r
-        * \r
+        *\r
         * @param fileBuffer\r
         *            String buffer for AutoGen.c\r
         */\r
@@ -1762,10 +1763,10 @@ public class AutoGen {
 \r
        /**\r
         * ExternCallBackToAutoGenC\r
-        * \r
+        *\r
         * This function adds <SetVirtualAddressMapCallBack> and\r
         * <ExitBootServicesCallBack> infomation to AutoGen.c\r
-        * \r
+        *\r
         * @param fileBuffer\r
         *            String buffer for AutoGen.c\r
         * @throws BuildException\r
@@ -1773,10 +1774,10 @@ public class AutoGen {
        void ExternCallBackToAutoGenC(StringBuffer fileBuffer)\r
                        throws BuildException {\r
                //\r
-               // Collect module's <SetVirtualAddressMapCallBack> and \r
-               // <ExitBootServiceCallBack> and add to setVirtualAddList \r
+               // Collect module's <SetVirtualAddressMapCallBack> and\r
+               // <ExitBootServiceCallBack> and add to setVirtualAddList\r
                //  exitBootServiceList.\r
-               // \r
+               //\r
         String[] setVirtuals = SurfaceAreaQuery.getSetVirtualAddressMapCallBackArray();\r
         String[] exitBoots = SurfaceAreaQuery.getExitBootServicesCallBackArray();\r
         if (setVirtuals != null) {\r
@@ -1791,8 +1792,8 @@ public class AutoGen {
                }\r
                //\r
                //  Add c code in autogen.c which relate to <SetVirtualAddressMapCallBack>\r
-               //  and <ExitBootServicesCallBack> \r
-               // \r
+               //  and <ExitBootServicesCallBack>\r
+               //\r
                String moduleType = this.moduleId.getModuleType();\r
                boolean UefiOrDxeModule = false;\r
                int Count = 0;\r
@@ -1879,8 +1880,8 @@ public class AutoGen {
                        }\r
                        //\r
                        //  If module is not DXE_DRIVER, DXE_RUNTIME_DIRVER, UEFI_DRIVER\r
-                       //  UEFI_APPLICATION and DXE_SAL_DRIVER add the NULL at the end of \r
-                       //  _gDriverSetVirtualAddressMapEvent list. \r
+                       //  UEFI_APPLICATION and DXE_SAL_DRIVER add the NULL at the end of\r
+                       //  _gDriverSetVirtualAddressMapEvent list.\r
                        //\r
                        if (!UefiOrDxeModule) {\r
                                fileBuffer.append(",\r\n  NULL");\r
@@ -1966,15 +1967,15 @@ public class AutoGen {
        }\r
 \r
     private void copyFlashMapHToDebugDir() throws  AutoGenException{\r
-        \r
+\r
         File inFile = new File(fvDir + File.separatorChar + CommonDefinition.flashMapH);\r
         int size = (int)inFile.length();\r
         byte[] buffer = new byte[size];\r
         File outFile = new File (this.outputPath + File.separatorChar + CommonDefinition.tianoR8FlashMapH);\r
                //\r
-               //  If TianoR8FlashMap.h existed and the flashMap.h don't change, \r
+               //  If TianoR8FlashMap.h existed and the flashMap.h don't change,\r
                //  do nothing.\r
-               // \r
+               //\r
         if ((!outFile.exists()) ||(inFile.lastModified() - outFile.lastModified()) >= 0) {\r
                    try{\r
                 if (inFile.exists()) {\r
@@ -1992,7 +1993,7 @@ public class AutoGen {
             }\r
                }\r
     }\r
-    \r
+\r
     /**\r
     *This function first order the library instances, then collect\r
     *library instance 's PPI, Protocol, GUID,\r
@@ -2094,9 +2095,9 @@ public class AutoGen {
                                                                .getLibDestructorName();\r
 \r
                                                //\r
-                                               // Collect SetVirtualAddressMapCallBack and \r
+                                               // Collect SetVirtualAddressMapCallBack and\r
                                                // ExitBootServiceCallBack.\r
-                                               // \r
+                                               //\r
                         setVirtuals = SurfaceAreaQuery.getSetVirtualAddressMapCallBackArray();\r
                         exitBoots = SurfaceAreaQuery.getExitBootServicesCallBackArray();\r
                         if (setVirtuals != null) {\r
index 51e0bd1f89ec117faec46029af8ca6a411c68970..c1d77444f159577a28298a3a845e5d2ae1aaa57a 100644 (file)
@@ -2,20 +2,20 @@
   GenBuildException class.\r
 \r
   The class handle the exception throwed by entity class.\r
\r
+\r
 Copyright (c) 2006, Intel Corporation\r
 All rights reserved. This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
 which accompanies this distribution.  The full text of the license may be found at\r
 http://opensource.org/licenses/bsd-license.php\r
\r
+\r
 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
-**/   \r
+**/\r
 package org.tianocore.build.exception;\r
 \r
-import org.tianocore.exception.EdkException;\r
+import org.tianocore.common.exception.EdkException;\r
 \r
 /**\r
   The class handle the exception throwed by entity class.\r
@@ -24,13 +24,13 @@ public class GenBuildException extends EdkException {
     static final long serialVersionUID = -8034897190740066937L;\r
     /**\r
       Constructure function\r
-        \r
+\r
       @param expStr exception message string.\r
     **/\r
     public GenBuildException(String expStr) {\r
         super("[GenBuildException]:" + expStr);\r
     }\r
-    \r
+\r
     public GenBuildException() {\r
         super();\r
     }\r
index 87505e49b1ca676fd9647e8f3b87d57272502f10..077905a8e86e22461ab066a5968853bd42731b42 100644 (file)
@@ -2,20 +2,20 @@
   TianoToolsException class.\r
 \r
   The class handle the exception throwed by entity class.\r
\r
+\r
 Copyright (c) 2006, Intel Corporation\r
 All rights reserved. This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
 which accompanies this distribution.  The full text of the license may be found at\r
 http://opensource.org/licenses/bsd-license.php\r
\r
+\r
 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
-**/   \r
+**/\r
 package org.tianocore.build.exception;\r
 \r
-import org.tianocore.exception.EdkException;\r
+import org.tianocore.common.exception.EdkException;\r
 \r
 /**\r
   The class handle the exception throwed by entity class.\r
@@ -24,17 +24,17 @@ public class TianoToolsException extends EdkException {
     static final long serialVersionUID = -8034897190740066935L;\r
     /**\r
       Constructure function\r
-        \r
+\r
       @param expStr exception message string.\r
     **/\r
     public TianoToolsException(String expStr) {\r
         super("[TianoToolsException]:" + expStr);\r
     }\r
-    \r
+\r
     public TianoToolsException() {\r
         super();\r
     }\r
-    \r
+\r
     public TianoToolsException (Exception e, String message){\r
         super(e, message);\r
     }\r
index 1aaf6608f6a6d96fd35abf257b739f3f87067b28..80682b2e4661fb25cb281d93ea9661b6158abe76 100644 (file)
@@ -1,9 +1,9 @@
 /** @file\r
- This file is ANT task FpdParserTask. \r
\r
+ This file is ANT task FpdParserTask.\r
+\r
  FpdParserTask is used to parse FPD (Framework Platform Description) and generate\r
- build.out.xml. It is for Package or Platform build use. \r
\r
+ build.out.xml. It is for Package or Platform build use.\r
+\r
  Copyright (c) 2006, Intel Corporation\r
  All rights reserved. This program and the accompanying materials\r
  are licensed and made available under the terms and conditions of the BSD License\r
@@ -32,61 +32,61 @@ import org.apache.tools.ant.taskdefs.Ant;
 import org.apache.tools.ant.taskdefs.Property;\r
 import org.apache.xmlbeans.XmlObject;\r
 \r
+import org.tianocore.common.exception.EdkException;\r
+import org.tianocore.pcd.action.ActionMessage;\r
 import org.tianocore.build.global.GlobalData;\r
 import org.tianocore.build.global.OutputManager;\r
 import org.tianocore.build.global.SurfaceAreaQuery;\r
 import org.tianocore.build.id.FpdModuleIdentification;\r
 import org.tianocore.build.id.ModuleIdentification;\r
 import org.tianocore.build.id.PlatformIdentification;\r
-import org.tianocore.pcd.action.ActionMessage;\r
 import org.tianocore.build.pcd.action.PlatformPcdPreprocessActionForBuilding;\r
 import org.tianocore.build.toolchain.ToolChainAttribute;\r
 import org.tianocore.build.toolchain.ToolChainElement;\r
 import org.tianocore.build.toolchain.ToolChainMap;\r
-import org.tianocore.exception.EdkException;\r
 \r
 /**\r
   <code>FpdParserTask</code> is an ANT task. The main function is parsing Framework\r
-  Platform Descritpion (FPD) XML file and generating its ANT build script for \r
-  corresponding platform.  \r
+  Platform Descritpion (FPD) XML file and generating its ANT build script for\r
+  corresponding platform.\r
 \r
   <p>The task sets global properties PLATFORM, PLATFORM_DIR, PLATFORM_RELATIVE_DIR\r
   and BUILD_DIR. </p>\r
-  \r
+\r
   <p>The task generates ${PLATFORM}_build.xml file which will be called by top level\r
-  build.xml. The task also generate Fv.inf files (File is for Tool GenFvImage) \r
+  build.xml. The task also generate Fv.inf files (File is for Tool GenFvImage)\r
   and flash definition file (File is for Tool FlashMap) if necessary. </p>\r
-  \r
+\r
   <p>FpdParserTask task stores all FPD information to GlobalData. And parse\r
   tools definition file to set up compiler options for different Target and\r
   different ToolChainTag. </p>\r
-  \r
+\r
   <p>The method parseFpdFile is also prepared for single module build. </p>\r
-  \r
+\r
   <p>The usage is (take NT32 Platform for example):</p>\r
 \r
   <pre>\r
   &lt;FPDParser platformName="Nt32" /&gt;\r
   </pre>\r
 \r
-  <p>The task will initialize all information through parsing Framework Database, \r
+  <p>The task will initialize all information through parsing Framework Database,\r
   SPD, Tool chain configuration files. </p>\r
 \r
   @since GenBuild 1.0\r
 **/\r
 public class FpdParserTask extends Task {\r
-    \r
+\r
     private String platformName;\r
 \r
     private File fpdFile = null;\r
-    \r
+\r
     private PlatformIdentification platformId;\r
-    \r
+\r
+    ///\r
     ///\r
-    /// \r
     ///\r
     private String type;\r
-    \r
+\r
     ///\r
     /// Mapping from modules identification to out put file name\r
     ///\r
@@ -98,10 +98,10 @@ public class FpdParserTask extends Task {
     private Map<String, Set<FpdModuleIdentification>> fvs = new HashMap<String, Set<FpdModuleIdentification>>();\r
 \r
     ///\r
-    /// FpdParserTask can specify some ANT properties. \r
+    /// FpdParserTask can specify some ANT properties.\r
     ///\r
     private Vector<Property> properties = new Vector<Property>();\r
-    \r
+\r
     private boolean isUnified = true;\r
 \r
 \r
@@ -112,19 +112,19 @@ public class FpdParserTask extends Task {
     }\r
 \r
     /**\r
-     ANT task's entry method. The main steps is described as following: \r
-     \r
+     ANT task's entry method. The main steps is described as following:\r
+\r
      <ul>\r
-     <li>Initialize global information (Framework DB, SPD files and all MSA files \r
+     <li>Initialize global information (Framework DB, SPD files and all MSA files\r
      listed in SPD). This step will execute only once in whole build process;</li>\r
      <li>Parse specified FPD file; </li>\r
      <li>Generate FV.inf files; </li>\r
      <li>Generate PlatformName_build.xml file for Flatform build; </li>\r
      <li>Collect PCD information. </li>\r
      </ul>\r
-     \r
+\r
      @throws BuildException\r
-     Surface area is not valid. \r
+     Surface area is not valid.\r
     **/\r
     public void execute() throws BuildException {\r
         // Remove !!\r
@@ -135,17 +135,17 @@ public class FpdParserTask extends Task {
             platformId = GlobalData.getPlatformByName(platformName);\r
             fpdFile = platformId.getFpdFile();\r
         }\r
-        \r
+\r
         //\r
         // Parse FPD file\r
         //\r
         parseFpdFile();\r
-        \r
+\r
         //\r
         // Prepare BUILD_DIR\r
         //\r
         isUnified = OutputManager.getInstance().prepareBuildDir(getProject());\r
-        \r
+\r
         //\r
         // For every Target and ToolChain\r
         //\r
@@ -156,13 +156,13 @@ public class FpdParserTask extends Task {
                 //\r
                 // Prepare FV_DIR\r
                 //\r
-                String ffsCommonDir = getProject().getProperty("BUILD_DIR") + File.separatorChar \r
-                                + targetList[i] + File.separatorChar \r
+                String ffsCommonDir = getProject().getProperty("BUILD_DIR") + File.separatorChar\r
+                                + targetList[i] + File.separatorChar\r
                                 + toolchainList[j];\r
                 File fvDir = new File(ffsCommonDir + File.separatorChar + "FV");\r
                 fvDir.mkdirs();\r
                 getProject().setProperty("FV_DIR", fvDir.getPath().replaceAll("(\\\\)", "/"));\r
-                \r
+\r
                 //\r
                 // Gen Fv.inf files\r
                 //\r
@@ -175,11 +175,11 @@ public class FpdParserTask extends Task {
         //\r
         PlatformBuildFileGenerator fileGenerator = new PlatformBuildFileGenerator(getProject(), outfiles, isUnified);\r
         fileGenerator.genBuildFile();\r
-        \r
+\r
         //\r
         // Ant call ${PLATFORM}_build.xml\r
         //\r
-        \r
+\r
         Ant ant = new Ant();\r
         ant.setProject(getProject());\r
         ant.setAntfile(platformId.getFpdFile().getParent() + File.separatorChar + platformId.getName() + "_build.xml");\r
@@ -187,17 +187,17 @@ public class FpdParserTask extends Task {
         ant.setInheritAll(true);\r
         ant.init();\r
         ant.execute();\r
-        \r
+\r
 //        GlobalData.log.info("Fpd build end. ");\r
     }\r
 \r
     /**\r
-      Generate Fv.inf files. The Fv.inf file is composed with four \r
-      parts: Options, Attributes, Components and Files. The Fv.inf files \r
+      Generate Fv.inf files. The Fv.inf file is composed with four\r
+      parts: Options, Attributes, Components and Files. The Fv.inf files\r
       will be under FV_DIR.\r
-     \r
+\r
       @throws BuildException\r
-                  File write FV.inf files error. \r
+                  File write FV.inf files error.\r
     **/\r
     private void genFvInfFiles(String ffsCommonDir) throws BuildException {\r
         String[] validFv = SurfaceAreaQuery.getFpdValidImageNames();\r
@@ -211,14 +211,14 @@ public class FpdParserTask extends Task {
             }\r
 \r
             getProject().setProperty("FV_FILENAME", validFv[i]);\r
-            \r
+\r
             File fvFile = new File(getProject().replaceProperties( getProject().getProperty("FV_DIR") + File.separatorChar + validFv[i] + ".inf"));\r
             fvFile.getParentFile().mkdirs();\r
 \r
             try {\r
                 FileWriter fw = new FileWriter(fvFile);\r
                 BufferedWriter bw = new BufferedWriter(fw);\r
-                \r
+\r
                 //\r
                 // Options\r
                 //\r
@@ -239,7 +239,7 @@ public class FpdParserTask extends Task {
                     }\r
                     bw.newLine();\r
                 }\r
-                \r
+\r
                 //\r
                 // Attributes;\r
                 //\r
@@ -260,7 +260,7 @@ public class FpdParserTask extends Task {
                     }\r
                     bw.newLine();\r
                 }\r
-                \r
+\r
                 //\r
                 // Components\r
                 //\r
@@ -281,7 +281,7 @@ public class FpdParserTask extends Task {
                     }\r
                     bw.newLine();\r
                 }\r
-                \r
+\r
                 //\r
                 // Files\r
                 //\r
@@ -306,10 +306,10 @@ public class FpdParserTask extends Task {
     }\r
     /**\r
       This method is used for Single Module Build.\r
-      \r
-      \r
+\r
+\r
       @throws BuildException\r
-                  FPD file is not valid. \r
+                  FPD file is not valid.\r
     **/\r
     public void parseFpdFile(File fpdFile) throws BuildException {\r
         this.fpdFile = fpdFile;\r
@@ -317,19 +317,19 @@ public class FpdParserTask extends Task {
     }\r
 \r
     /**\r
-      Parse FPD file. \r
-     \r
+      Parse FPD file.\r
+\r
       @throws BuildException\r
-                  FPD file is not valid. \r
+                  FPD file is not valid.\r
      **/\r
     private void parseFpdFile() throws BuildException {\r
         try {\r
             XmlObject doc = XmlObject.Factory.parse(fpdFile);\r
-            \r
+\r
             if (!doc.validate()) {\r
                 throw new BuildException("Platform Surface Area file [" + fpdFile.getPath() + "] format is invalid!");\r
             }\r
-            \r
+\r
             Map<String, XmlObject> map = new HashMap<String, XmlObject>();\r
             map.put("PlatformSurfaceArea", doc);\r
             SurfaceAreaQuery.setDoc(map);\r
@@ -345,7 +345,7 @@ public class FpdParserTask extends Task {
             getProject().setProperty("PLATFORM_RELATIVE_DIR", platformId.getPlatformRelativeDir().replaceAll("(\\\\)", "/"));\r
 \r
             //\r
-            // Build mode. User-defined output dir. \r
+            // Build mode. User-defined output dir.\r
             //\r
             String buildMode = SurfaceAreaQuery.getFpdIntermediateDirectories();\r
             String userDefinedOutputDir = SurfaceAreaQuery.getFpdOutputDirectory();\r
@@ -356,9 +356,9 @@ public class FpdParserTask extends Task {
             // TBD. Deal PCD and BuildOption related Info\r
             //\r
             GlobalData.setFpdBuildOptions(SurfaceAreaQuery.getFpdBuildOptions());\r
-            \r
+\r
             GlobalData.setToolChainPlatformInfo(SurfaceAreaQuery.getFpdToolChainInfo());\r
-            \r
+\r
             //\r
             // Parse all list modules SA\r
             //\r
@@ -371,7 +371,7 @@ public class FpdParserTask extends Task {
             parseToolChainOptions();\r
 \r
             SurfaceAreaQuery.setDoc(map);\r
-            \r
+\r
             //\r
             // Pcd Collection. Call CollectPCDAction to collect pcd info.\r
             //\r
@@ -383,9 +383,9 @@ public class FpdParserTask extends Task {
     }\r
 \r
 \r
-    \r
+\r
     /**\r
-      Parse all modules listed in FPD file. \r
+      Parse all modules listed in FPD file.\r
     **/\r
     private void parseModuleSAFiles() throws EdkException{\r
         Map<FpdModuleIdentification, Map<String, XmlObject>> moduleSAs = SurfaceAreaQuery.getFpdModules();\r
@@ -397,11 +397,11 @@ public class FpdParserTask extends Task {
         Iterator iter = keys.iterator();\r
         while (iter.hasNext()) {\r
             FpdModuleIdentification fpdModuleId = (FpdModuleIdentification) iter.next();\r
-            \r
+\r
             //\r
-            // Judge if Module is existed? \r
+            // Judge if Module is existed?\r
             // TBD\r
-            \r
+\r
             GlobalData.registerFpdModuleSA(fpdModuleId, moduleSAs.get(fpdModuleId));\r
 \r
             //\r
@@ -413,7 +413,7 @@ public class FpdParserTask extends Task {
 \r
             fpdModuleId.setFvBinding(fvBinding);\r
             updateFvs(fvBinding, fpdModuleId);\r
-            \r
+\r
             //\r
             // Prepare for out put file name\r
             //\r
@@ -424,13 +424,13 @@ public class FpdParserTask extends Task {
             if (baseName == null) {\r
                 baseName = moduleId.getName();\r
             }\r
-            outfiles.put(fpdModuleId, fpdModuleId.getArch() + File.separatorChar \r
-                         + moduleId.getGuid() + "-" + baseName \r
+            outfiles.put(fpdModuleId, fpdModuleId.getArch() + File.separatorChar\r
+                         + moduleId.getGuid() + "-" + baseName\r
                          + getSuffix(moduleId.getModuleType()));\r
 \r
             //\r
             // parse module build options, if any\r
-            // \r
+            //\r
             SurfaceAreaQuery.push(GlobalData.getDoc(fpdModuleId));\r
             GlobalData.addModuleToolChainOption(fpdModuleId, parseModuleBuildOptions(false));\r
             GlobalData.addModuleToolChainFamilyOption(fpdModuleId, parseModuleBuildOptions(true));\r
@@ -445,7 +445,7 @@ public class FpdParserTask extends Task {
         }\r
         return parseOptions(options);\r
     }\r
-    \r
+\r
     private ToolChainMap parsePlatformBuildOptions(boolean toolChainFamilyFlag) throws EdkException {\r
         String[][] options = SurfaceAreaQuery.getPlatformBuildOptions(toolChainFamilyFlag);\r
         if (options == null || options.length == 0) {\r
@@ -469,7 +469,7 @@ public class FpdParserTask extends Task {
 \r
         return map;\r
     }\r
-    \r
+\r
     private void parseToolChainFamilyOptions() throws EdkException {\r
         GlobalData.setPlatformToolChainFamilyOption(parsePlatformBuildOptions(true));\r
     }\r
@@ -479,8 +479,8 @@ public class FpdParserTask extends Task {
     }\r
 \r
     /**\r
-      Add the current module to corresponding FV. \r
-     \r
+      Add the current module to corresponding FV.\r
+\r
       @param fvName current FV name\r
       @param moduleName current module identification\r
     **/\r
@@ -506,8 +506,8 @@ public class FpdParserTask extends Task {
     }\r
 \r
     /**\r
-      Get the suffix based on module type. Current relationship are listed:  \r
-      \r
+      Get the suffix based on module type. Current relationship are listed:\r
+\r
       <pre>\r
       <b>ModuleType</b>     <b>Suffix</b>\r
       BASE                 .FFS\r
@@ -524,7 +524,7 @@ public class FpdParserTask extends Task {
       UEFI_APPLICATION     .APP\r
       USER_DEFINED         .FFS\r
       </pre>\r
-     \r
+\r
       @param moduleType module type\r
       @return\r
       @throws BuildException\r
@@ -536,13 +536,13 @@ public class FpdParserTask extends Task {
         }\r
 \r
         String[][] suffix = { { "BASE", ".FFS"},\r
-                              { "SEC", ".SEC" }, { "PEI_CORE", ".PEI" }, \r
+                              { "SEC", ".SEC" }, { "PEI_CORE", ".PEI" },\r
                               { "PEIM", ".PEI" }, { "DXE_CORE", ".DXE" },\r
-                              { "DXE_DRIVER", ".DXE" }, { "DXE_RUNTIME_DRIVER", ".DXE" }, \r
-                              { "DXE_SAL_DRIVER", ".DXE" }, { "DXE_SMM_DRIVER", ".DXE" }, \r
+                              { "DXE_DRIVER", ".DXE" }, { "DXE_RUNTIME_DRIVER", ".DXE" },\r
+                              { "DXE_SAL_DRIVER", ".DXE" }, { "DXE_SMM_DRIVER", ".DXE" },\r
                               { "TOOL", ".FFS" }, { "UEFI_DRIVER", ".DXE" },\r
                               { "UEFI_APPLICATION", ".APP" }, { "USER_DEFINED", ".FFS" } };\r
-        \r
+\r
         for (int i = 0; i < suffix.length; i++) {\r
             if (suffix[i][0].equalsIgnoreCase(moduleType)) {\r
                 return suffix[i][1];\r
@@ -554,8 +554,8 @@ public class FpdParserTask extends Task {
         return ".FFS";\r
     }\r
     /**\r
-     Add a property. \r
-     \r
+     Add a property.\r
+\r
      @param p property\r
      **/\r
     public void addProperty(Property p) {\r
@@ -573,6 +573,6 @@ public class FpdParserTask extends Task {
     public void setType(String type) {\r
         this.type = type;\r
     }\r
-    \r
+\r
 \r
 }\r
index 4c179b8fd3727afac269e321e1d0dff6dc301065..e1bafd668a778476c8c90670f84cbf6c7b8aa9a6 100644 (file)
@@ -17,20 +17,22 @@ Abstract:
 --*/\r
 \r
 package org.tianocore.build.global;\r
+\r
 import org.apache.tools.ant.Project;\r
-import org.tianocore.logger.LogMethod;\r
+\r
+import org.tianocore.common.logger.LogMethod;\r
 \r
 public class GenBuildLogger implements LogMethod {\r
     private Project project;\r
     public GenBuildLogger(Project project) {\r
         this.project = project;\r
-        \r
+\r
     }\r
 \r
     public void putMessage(Object msgSource, int msgLevel, String msg) {\r
         if (this.project != null){\r
             this.project.log(msg, Project.MSG_INFO);\r
         }\r
-        \r
+\r
     }\r
 }
\ No newline at end of file
index 1e7568757af2ef77e978d26a8e0c2a0193134334..89c85ed8c26d54d28b1eec37975c4bb37321e756 100644 (file)
@@ -1,10 +1,10 @@
 /** @file\r
-  GlobalData class. \r
-  \r
+  GlobalData class.\r
+\r
   GlobalData provide initializing, instoring, querying and update global data.\r
   It is a bridge to intercommunicate between multiple component, such as AutoGen,\r
-  PCD and so on.   \r
\r
+  PCD and so on.\r
+\r
 Copyright (c) 2006, Intel Corporation\r
 All rights reserved. This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
@@ -27,6 +27,10 @@ import java.util.logging.Logger;
 \r
 import org.apache.tools.ant.BuildException;\r
 import org.apache.xmlbeans.XmlObject;\r
+\r
+import org.tianocore.common.exception.EdkException;\r
+import org.tianocore.common.logger.EdkLog;\r
+import org.tianocore.pcd.entity.MemoryDatabaseManager;\r
 import org.tianocore.DbPathAndFilename;\r
 import org.tianocore.FrameworkDatabaseDocument;\r
 import org.tianocore.ModuleSurfaceAreaDocument;\r
@@ -35,44 +39,41 @@ import org.tianocore.build.id.FpdModuleIdentification;
 import org.tianocore.build.id.ModuleIdentification;\r
 import org.tianocore.build.id.PackageIdentification;\r
 import org.tianocore.build.id.PlatformIdentification;\r
-import org.tianocore.pcd.entity.MemoryDatabaseManager;\r
 import org.tianocore.build.toolchain.ToolChainAttribute;\r
 import org.tianocore.build.toolchain.ToolChainConfig;\r
 import org.tianocore.build.toolchain.ToolChainElement;\r
 import org.tianocore.build.toolchain.ToolChainInfo;\r
 import org.tianocore.build.toolchain.ToolChainKey;\r
 import org.tianocore.build.toolchain.ToolChainMap;\r
-import org.tianocore.exception.EdkException;\r
-import org.tianocore.logger.EdkLog;\r
 \r
 /**\r
   GlobalData provide initializing, instoring, querying and update global data.\r
   It is a bridge to intercommunicate between multiple component, such as AutoGen,\r
-  PCD and so on. \r
-  \r
-  <p>Note that all global information are initialized incrementally. All data will \r
+  PCD and so on.\r
+\r
+  <p>Note that all global information are initialized incrementally. All data will\r
   parse and record only of necessary during build time. </p>\r
-  \r
+\r
   @since GenBuild 1.0\r
 **/\r
 public class GlobalData {\r
 \r
     public static Logger log = Logger.getAnonymousLogger();\r
-    \r
+\r
     ///\r
     /// Record current WORKSPACE Directory\r
     ///\r
     private static String workspaceDir = "";\r
-    \r
+\r
     ///\r
     /// Be used to ensure Global data will be initialized only once.\r
     ///\r
     private static boolean globalFlag = false;\r
-    \r
+\r
     ///\r
     /// Framework Database information: package list and platform list\r
     ///\r
-    private static Set<PackageIdentification> packageList = new HashSet<PackageIdentification>();  \r
+    private static Set<PackageIdentification> packageList = new HashSet<PackageIdentification>();\r
 \r
     private static Set<PlatformIdentification> platformList = new HashSet<PlatformIdentification>();\r
 \r
@@ -93,17 +94,17 @@ public class GlobalData {
     private static XmlObject fpdBuildOptions;\r
 \r
     private static XmlObject fpdDynamicPcds;\r
-    \r
+\r
     ///\r
     /// Parsed modules list\r
     ///\r
     private static Map<FpdModuleIdentification, Map<String, XmlObject>> parsedModules = new HashMap<FpdModuleIdentification, Map<String, XmlObject>>();\r
-    \r
+\r
     ///\r
     /// built modules list with ARCH, TARGET, TOOLCHAIN\r
     ///\r
     private static Set<FpdModuleIdentification> builtModules = new HashSet<FpdModuleIdentification>();\r
-    \r
+\r
     ///\r
     /// PCD memory database stored all PCD information which collected from FPD,MSA and SPD.\r
     ///\r
@@ -117,7 +118,7 @@ public class GlobalData {
     /// toolsDef - build tool program information\r
     /// fpdBuildOption - all modules's build options for tool tag or tool chain families\r
     /// moduleSaBuildOption - build options for a specific module\r
-    /// \r
+    ///\r
     private static ToolChainConfig toolsDef;\r
 \r
     private static ToolChainInfo toolChainInfo;\r
@@ -133,8 +134,8 @@ public class GlobalData {
     /**\r
       Parse framework database (DB) and all SPD files listed in DB to initialize\r
       the environment for next build. This method will only be executed only once\r
-      in the whole build process.  \r
-    \r
+      in the whole build process.\r
+\r
       @param workspaceDatabaseFile the file name of framework database\r
       @param workspaceDir current workspace directory path\r
       @throws BuildException\r
@@ -149,11 +150,11 @@ public class GlobalData {
         }\r
         globalFlag = true;\r
 \r
-               // \r
+               //\r
         // Backup workspace directory. It will be used by other method\r
         //\r
         GlobalData.workspaceDir = workspaceDir.replaceAll("(\\\\)", "/");\r
-        \r
+\r
         //\r
         // Parse tools definition file\r
         //\r
@@ -164,7 +165,7 @@ public class GlobalData {
         File toolsDefFile = new File(workspaceDir + File.separatorChar + toolsDefFilename);\r
         System.out.println("Using tool definiton file [" + toolsDefFile.getPath() + "].");\r
         toolsDef = new ToolChainConfig(toolsDefFile);\r
-        \r
+\r
         //\r
         // Parse Framework Database\r
         //\r
@@ -228,10 +229,10 @@ public class GlobalData {
             throw new BuildException("Parse WORKSPACE Database file [" + dbFile.getPath() + "] Error.\n" + e.getMessage());\r
         }\r
     }\r
-    \r
+\r
     /**\r
-      Get the current WORKSPACE Directory. \r
-      \r
+      Get the current WORKSPACE Directory.\r
+\r
       @return current workspace directory\r
     **/\r
     public synchronized static String getWorkspacePath() {\r
@@ -245,7 +246,7 @@ public class GlobalData {
     public synchronized static File getMsaFile(ModuleIdentification moduleId) throws BuildException {\r
         File msaFile = null;\r
         //\r
-        // TBD. Do only when package is null. \r
+        // TBD. Do only when package is null.\r
         //\r
         Iterator iter = packageList.iterator();\r
         while (iter.hasNext()) {\r
@@ -271,7 +272,7 @@ public class GlobalData {
         if (moduleId.getPackage() != null) {\r
             return moduleId.getPackage();\r
         }\r
-        \r
+\r
         PackageIdentification packageId = null;\r
         Iterator iter = packageList.iterator();\r
         while (iter.hasNext()) {\r
@@ -289,19 +290,19 @@ public class GlobalData {
             return packageId;\r
         }\r
     }\r
-    \r
+\r
     /**\r
       Difference between build and parse: ToolChain and Target\r
     **/\r
     public synchronized static boolean isModuleBuilt(FpdModuleIdentification moduleId) {\r
         return builtModules.contains(moduleId);\r
     }\r
-    \r
+\r
     public synchronized static void registerBuiltModule(FpdModuleIdentification fpdModuleId) {\r
         builtModules.add(fpdModuleId);\r
     }\r
 \r
-    \r
+\r
     public synchronized static void registerFpdModuleSA(FpdModuleIdentification fpdModuleId, Map<String, XmlObject> doc) {\r
         Map<String, XmlObject> result = new HashMap<String, XmlObject>();\r
         Set keySet = doc.keySet();\r
@@ -320,11 +321,11 @@ public class GlobalData {
 \r
     /**\r
       Query overrided module surface area information. If current is Package\r
-      or Platform build, also include the information from FPD file. \r
-      \r
-      <p>Note that surface area parsing is incremental. That means the method will \r
+      or Platform build, also include the information from FPD file.\r
+\r
+      <p>Note that surface area parsing is incremental. That means the method will\r
       only parse the MSA and MBD files if necessary. </p>\r
-    \r
+\r
       @param moduleName the base name of the module\r
       @return the overrided module surface area information\r
       @throws BuildException\r
@@ -340,12 +341,12 @@ public class GlobalData {
         // First part: get the MSA files info\r
         //\r
         doc.putAll(getNativeMsa(moduleId));\r
-        \r
+\r
         //\r
         // Second part: put build options\r
         //\r
         doc.put("BuildOptions", fpdBuildOptions);\r
-        \r
+\r
         //\r
         // Third part: get Module info from FPD, such as Library instances, PCDs\r
         //\r
@@ -365,11 +366,11 @@ public class GlobalData {
         return getDoc(fpdModuleId);\r
     }\r
     /**\r
-      Query the native MSA information with module base name. \r
-      \r
-      <p>Note that MSA parsing is incremental. That means the method will \r
+      Query the native MSA information with module base name.\r
+\r
+      <p>Note that MSA parsing is incremental. That means the method will\r
       only to parse the MSA files when never parsed before. </p>\r
-      \r
+\r
       @param moduleName the base name of the module\r
       @return the native MSA information\r
       @throws BuildException\r
@@ -384,7 +385,7 @@ public class GlobalData {
         nativeMsa.put(moduleId, msaMap);\r
         return msaMap;\r
     }\r
-    \r
+\r
     public synchronized static Map<String, XmlObject> getNativeMsa(File msaFile) throws BuildException {\r
         if (! msaFile.exists()) {\r
             throw new BuildException("Module Surface Area file [" + msaFile.getPath() + "] can't be found!");\r
@@ -418,13 +419,13 @@ public class GlobalData {
             throw new BuildException(ex.getMessage());\r
         }\r
     }\r
-    \r
+\r
     public static Map<String, XmlObject> getFpdBuildOptions() {\r
         Map<String, XmlObject> map = new HashMap<String, XmlObject>();\r
         map.put("BuildOptions", fpdBuildOptions);\r
         return map;\r
     }\r
-    \r
+\r
     public static void setFpdBuildOptions(XmlObject fpdBuildOptions) {\r
         GlobalData.fpdBuildOptions = cloneXmlObject(fpdBuildOptions, true);\r
     }\r
@@ -439,7 +440,7 @@ public class GlobalData {
 \r
     //////////////////////////////////////////////\r
     //////////////////////////////////////////////\r
-    \r
+\r
     public static Set<ModuleIdentification> getModules(PackageIdentification packageId){\r
         Spd spd = spdTable.get(packageId);\r
         if (spd == null ) {\r
@@ -572,7 +573,7 @@ public class GlobalData {
         return null;\r
 \r
     }\r
-    \r
+\r
     public synchronized static PlatformIdentification getPlatformByName(String name) throws BuildException {\r
         Iterator iter = platformList.iterator();\r
         while(iter.hasNext()){\r
@@ -583,7 +584,7 @@ public class GlobalData {
         }\r
         throw new BuildException("Can't find platform [" + name + "] in the current WORKSPACE database!");\r
     }\r
-    \r
+\r
     public synchronized static PlatformIdentification getPlatform(String filename) throws BuildException {\r
         File file = new File(workspaceDir + File.separatorChar + filename);\r
         Iterator iter = platformList.iterator();\r
@@ -595,7 +596,7 @@ public class GlobalData {
         }\r
         throw new BuildException("Can't find platform file [" + filename + "] in the current WORKSPACE database!");\r
     }\r
-    \r
+\r
     public synchronized static PackageIdentification refreshPackageIdentification(PackageIdentification packageId) throws BuildException {\r
         Iterator iter = packageList.iterator();\r
         while(iter.hasNext()){\r
@@ -608,7 +609,7 @@ public class GlobalData {
         }\r
         throw new BuildException("Can't find package GUID value " + packageId.getGuid() + " in the current workspace!");\r
     }\r
-    \r
+\r
     public synchronized static ModuleIdentification refreshModuleIdentification(ModuleIdentification moduleId) throws BuildException {\r
 //        System.out.println("1");\r
 //        System.out.println("##" + moduleId.getGuid());\r
@@ -632,7 +633,7 @@ public class GlobalData {
         }\r
         throw new BuildException("Can't find module GUID value " + moduleId.getGuid() + " in package, " + packageId + ", in the current workspace!");\r
     }\r
-    \r
+\r
     public synchronized static Set<PackageIdentification> getPackageList(){\r
         return packageList;\r
     }\r
@@ -702,7 +703,7 @@ public class GlobalData {
 \r
     public static String getCommandSetting(String[] commandDescription, FpdModuleIdentification fpdModuleId) throws EdkException {\r
         ToolChainKey toolChainKey = new ToolChainKey(commandDescription);\r
-        ToolChainMap toolChainConfig = toolsDef.getConfig(); \r
+        ToolChainMap toolChainConfig = toolsDef.getConfig();\r
         String setting = null;\r
 \r
         if (!commandDescription[ToolChainElement.ATTRIBUTE.value].equals(ToolChainAttribute.FLAGS.toString())) {\r
@@ -731,7 +732,7 @@ public class GlobalData {
             toolChainFamilyKey.setKey(ToolChainAttribute.FLAGS.toString(), ToolChainElement.ATTRIBUTE.value);\r
 \r
             option = moduleToolChainFamilyOption.get(fpdModuleId);\r
-            if (option != null) {                \r
+            if (option != null) {\r
                 setting = option.get(toolChainFamilyKey);\r
             }\r
         }\r
@@ -761,7 +762,7 @@ public class GlobalData {
 \r
         return setting;\r
     }\r
-    \r
+\r
     public static void setToolChainEnvInfo(ToolChainInfo envInfo) {\r
         toolChainEnvInfo = envInfo;\r
     }\r
@@ -803,17 +804,17 @@ public class GlobalData {
     //\r
     // For PCD\r
     //\r
-    public synchronized static Map<FpdModuleIdentification, XmlObject> \r
+    public synchronized static Map<FpdModuleIdentification, XmlObject>\r
                                getFpdModuleSaXmlObject(String xmlObjectName) {\r
         Set<FpdModuleIdentification> fpdModuleSASet = fpdModuleSA.keySet();\r
         Iterator item = fpdModuleSASet.iterator();\r
-        \r
+\r
 \r
         Map<FpdModuleIdentification, XmlObject> SAPcdBuildDef = new HashMap<FpdModuleIdentification, XmlObject>();\r
         Map<String, XmlObject> SANode = new HashMap<String, XmlObject>();\r
         FpdModuleIdentification moduleId;\r
         while (item.hasNext()) {\r
-            \r
+\r
             moduleId = (FpdModuleIdentification) item.next();\r
             SANode = fpdModuleSA.get(moduleId);\r
             try{\r
index dbcc12772ceb16e566076a44bcd214bacb6a3c1c..93727dbfc432c0e1b64d8cfd9ee85c89b93dec2e 100644 (file)
@@ -23,8 +23,11 @@ import java.util.Stack;
 import java.util.regex.Matcher;\r
 import java.util.regex.Pattern;\r
 \r
+import org.w3c.dom.Node;\r
+\r
 import org.apache.xmlbeans.XmlObject;\r
 import org.apache.xmlbeans.XmlString;\r
+\r
 import org.tianocore.BuildOptionsDocument;\r
 import org.tianocore.CNameType;\r
 import org.tianocore.ExternsDocument;\r
@@ -57,20 +60,20 @@ import org.tianocore.FilenameDocument.Filename;
 import org.tianocore.MsaHeaderDocument.MsaHeader;\r
 import org.tianocore.ProtocolsDocument.Protocols.Protocol;\r
 import org.tianocore.ProtocolsDocument.Protocols.ProtocolNotify;\r
+\r
+import org.tianocore.common.logger.EdkLog;\r
 import org.tianocore.build.id.FpdModuleIdentification;\r
 import org.tianocore.build.id.ModuleIdentification;\r
 import org.tianocore.build.id.PackageIdentification;\r
 import org.tianocore.build.id.PlatformIdentification;\r
 import org.tianocore.build.toolchain.ToolChainInfo;\r
-import org.tianocore.logger.EdkLog;\r
-import org.w3c.dom.Node;\r
 \r
 /**\r
  * SurfaceAreaQuery class is used to query Surface Area information from msa,\r
  * mbd, spd and fpd files.\r
- * \r
+ *\r
  * This class should not instantiated. All the public interfaces is static.\r
- * \r
+ *\r
  * @since GenBuild 1.0\r
  */\r
 public class SurfaceAreaQuery {\r
@@ -105,7 +108,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Set a Surface Area document for query later\r
-     * \r
+     *\r
      * @param map\r
      *            A Surface Area document in TopLevelElementName/XmlObject\r
      *            format.\r
@@ -120,7 +123,7 @@ public class SurfaceAreaQuery {
      * Push current used Surface Area document into query stack. The given new\r
      * document will be used for any immediately followed getXXX() callings,\r
      * untill pop() is called.\r
-     * \r
+     *\r
      * @param newMap\r
      *            The TopLevelElementName/XmlObject format of a Surface Area\r
      *            document.\r
@@ -180,7 +183,7 @@ public class SurfaceAreaQuery {
     /**\r
      * Search all XML documents stored in "map" for the specified xPath, using\r
      * relative path (starting with '$this')\r
-     * \r
+     *\r
      * @param xPath\r
      *            xpath query string array\r
      * @returns An array of XmlObject if elements are found at the specified\r
@@ -219,7 +222,7 @@ public class SurfaceAreaQuery {
     /**\r
      * Search XML documents named by "rootName" for the given xPath, using\r
      * relative path (starting with '$this')\r
-     * \r
+     *\r
      * @param rootName\r
      *            The top level element name\r
      * @param xPath\r
@@ -255,7 +258,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve SourceFiles/Filename for specified ARCH type\r
-     * \r
+     *\r
      * @param arch\r
      *            architecture name\r
      * @returns An 2 dimension string array if elements are found at the known\r
@@ -282,7 +285,7 @@ public class SurfaceAreaQuery {
                 outputList.add(new String[] {sourceFileNames[i].getToolCode(),sourceFileNames[i].getStringValue()});\r
             }\r
         }\r
-           \r
+\r
         String[][] outputString = new String[outputList.size()][2];\r
         for (int index = 0; index < outputList.size(); index++) {\r
             outputString[index][0] = outputList.get(index)[0];\r
@@ -293,7 +296,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve /PlatformDefinitions/OutputDirectory from FPD\r
-     * \r
+     *\r
      * @returns Directory names array if elements are found at the known xpath\r
      * @returns Empty if nothing is found at the known xpath\r
      */\r
@@ -317,7 +320,7 @@ public class SurfaceAreaQuery {
         }\r
         PlatformDefinitionsDocument.PlatformDefinitions item = (PlatformDefinitionsDocument.PlatformDefinitions)returns[0];\r
         if(item.getIntermediateDirectories() == null) {\r
-            return null;     \r
+            return null;\r
         }\r
         else {\r
             return item.getIntermediateDirectories().toString();\r
@@ -334,7 +337,7 @@ public class SurfaceAreaQuery {
         ModuleSaBuildOptionsDocument.ModuleSaBuildOptions item = (ModuleSaBuildOptionsDocument.ModuleSaBuildOptions)returns[0];\r
         return item.getFfsFormatKey();\r
     }\r
-    \r
+\r
     public static String getModuleFvBindingKeyword() {\r
         String[] xPath = new String[] { "/" };\r
 \r
@@ -345,7 +348,7 @@ public class SurfaceAreaQuery {
         ModuleSaBuildOptionsDocument.ModuleSaBuildOptions item = (ModuleSaBuildOptionsDocument.ModuleSaBuildOptions)returns[0];\r
         return item.getFvBinding();\r
     }\r
-    \r
+\r
     public static List getModuleSupportedArchs() {\r
         String[] xPath = new String[] { "/" };\r
 \r
@@ -356,17 +359,17 @@ public class SurfaceAreaQuery {
         ModuleDefinitionsDocument.ModuleDefinitions item = (ModuleDefinitionsDocument.ModuleDefinitions)returns[0];\r
         return item.getSupportedArchitectures();\r
     }\r
-    \r
+\r
     public static BuildOptionsDocument.BuildOptions.Ffs[] getFpdFfs() {\r
         String[] xPath = new String[] {"/Ffs"};\r
-        \r
+\r
         Object[] returns = get("BuildOptions", xPath);\r
         if (returns == null || returns.length == 0) {\r
             return new BuildOptionsDocument.BuildOptions.Ffs[0];\r
         }\r
         return (BuildOptionsDocument.BuildOptions.Ffs[])returns;\r
     }\r
-    \r
+\r
     public static String getModuleOutputFileBasename() {\r
         String[] xPath = new String[] { "/" };\r
 \r
@@ -377,18 +380,18 @@ public class SurfaceAreaQuery {
         ModuleDefinitionsDocument.ModuleDefinitions item = (ModuleDefinitionsDocument.ModuleDefinitions)returns[0];\r
         return item.getOutputFileBasename();\r
     }\r
-    \r
+\r
     /**\r
      * Retrieve BuildOptions/Option or Arch/Option\r
-     * \r
+     *\r
      * @param toolChainFamilyFlag\r
      *            if true, retrieve options for toolchain family; otherwise for\r
      *            toolchain\r
-     * \r
+     *\r
      * @returns String[][5] name, target, toolchain, arch, coommand of options\r
      *          if elements are found at the known xpath. String[0][] if dont\r
      *          find element.\r
-     * \r
+     *\r
      * @returns Empty array if nothing is there\r
      */\r
     public static String[][] getOptions(String from, String[] xPath, boolean toolChainFamilyFlag) {\r
@@ -441,7 +444,7 @@ public class SurfaceAreaQuery {
             }\r
 \r
             archList = new ArrayList<String>();\r
-            List archEnumList = option.getSupArchList();            \r
+            List archEnumList = option.getSupArchList();\r
             if (archEnumList == null) {\r
                 archList.add(null);\r
             } else {\r
@@ -477,7 +480,7 @@ public class SurfaceAreaQuery {
 \r
     public static String[][] getModuleBuildOptions(boolean toolChainFamilyFlag) {\r
         String[] xPath;\r
-        \r
+\r
         if (toolChainFamilyFlag == true) {\r
             xPath = new String[] {\r
                     "/Options/Option[not(@ToolChainFamily) and not(@TagName)]",\r
@@ -488,8 +491,8 @@ public class SurfaceAreaQuery {
                     "/Options/Option[@TagName]", };\r
         }\r
         return getOptions("ModuleSaBuildOptions", xPath, toolChainFamilyFlag);\r
-    }   \r
-    \r
+    }\r
+\r
     public static String[][] getPlatformBuildOptions(boolean toolChainFamilyFlag) {\r
         String[] xPath;\r
 \r
@@ -513,7 +516,7 @@ public class SurfaceAreaQuery {
         if (returns == null || returns.length == 0) {\r
             return null;\r
         }\r
-        \r
+\r
         PlatformDefinitionsDocument.PlatformDefinitions item = (PlatformDefinitionsDocument.PlatformDefinitions)returns[0];\r
         ToolChainInfo toolChainInfo = new ToolChainInfo();\r
         toolChainInfo.addTargets(item.getBuildTargets().toString());\r
@@ -524,7 +527,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve <xxxHeader>/ModuleType\r
-     * \r
+     *\r
      * @returns The module type name if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -542,10 +545,10 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve PackageDependencies/Package\r
-     * \r
+     *\r
      * @param arch\r
      *            Architecture name\r
-     * \r
+     *\r
      * @returns package name list if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -554,17 +557,17 @@ public class SurfaceAreaQuery {
         String packageGuid = null;\r
         String packageVersion = null;\r
 \r
-        \r
+\r
         xPath = new String[] { "/Package" };\r
-        \r
+\r
         Object[] returns = get("PackageDependencies", xPath);\r
         if (returns == null) {\r
             return new PackageIdentification[0];\r
         }\r
 \r
         //\r
-        //  Get packageIdentification \r
-        // \r
+        //  Get packageIdentification\r
+        //\r
         List<PackageIdentification> packageIdList = new ArrayList<PackageIdentification>();\r
         for (int i = 0; i < returns.length; i++) {\r
             PackageDependenciesDocument.PackageDependencies.Package item = (PackageDependenciesDocument.PackageDependencies.Package) returns[i];\r
@@ -579,7 +582,7 @@ public class SurfaceAreaQuery {
 \r
         //\r
         //  transfer packageIdentification list to array.\r
-        // \r
+        //\r
         PackageIdentification[] packageIdArray = new PackageIdentification[packageIdList.size()];\r
         for (int i = 0; i < packageIdList.size(); i++) {\r
             packageIdArray[i] = new PackageIdentification(null, packageIdList.get(i).getGuid(),packageIdList.get(i).getVersion());\r
@@ -589,10 +592,10 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve LibraryClassDefinitions/LibraryClass for specified usage\r
-     * \r
+     *\r
      * @param usage\r
      *            Library class usage\r
-     * \r
+     *\r
      * @returns LibraryClass objects list if elements are found at the known\r
      *          xpath\r
      * @returns null if nothing is there\r
@@ -614,7 +617,7 @@ public class SurfaceAreaQuery {
         List<String> libraryClassName = new ArrayList<String>();\r
         for (int i = 0; i < libraryClassList.length; i++) {\r
                        List archList = libraryClassList[i].getSupArchList();\r
-                       \r
+\r
                        if (arch == null || contains(archList, arch)) {\r
                 libraryClassName.add(libraryClassList[i].getKeyword());\r
                        }\r
@@ -628,7 +631,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve ModuleEntryPoint names\r
-     * \r
+     *\r
      * @returns ModuleEntryPoint name list if elements are found at the known\r
      *          xpath\r
      * @returns null if nothing is there\r
@@ -653,10 +656,10 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * retrieve Protocol for specified usage\r
-     * \r
+     *\r
      * @param usage\r
      *            Protocol usage arch Architecture\r
-     * \r
+     *\r
      * @returns Protocol String list if elements are found at the known xpath\r
      * @returns String[0] if nothing is there\r
      */\r
@@ -693,10 +696,10 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * retrieve Protocol for specified usage\r
-     * \r
+     *\r
      * @param arch\r
      *            Architecture\r
-     * \r
+     *\r
      * @returns Protocol String list if elements are found at the known xpath\r
      * @returns String[0] if nothing is there\r
      */\r
@@ -716,7 +719,7 @@ public class SurfaceAreaQuery {
         Protocol[] returnlList = (Protocol[]) returns;\r
 \r
         List<String> protocolList = new ArrayList<String>();\r
-        \r
+\r
         for (int i = 0; i < returns.length; i++) {\r
             List archList = returnlList[i].getSupArchList();\r
             if (archList == null || contains(archList, arch)){\r
@@ -732,10 +735,10 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve ProtocolNotify for specified usage\r
-     * \r
+     *\r
      * @param usage\r
      *            ProtocolNotify usage\r
-     * \r
+     *\r
      * @returns String[] if elements are found at the known xpath\r
      * @returns String[0] if nothing is there\r
      */\r
@@ -754,13 +757,13 @@ public class SurfaceAreaQuery {
         }\r
 \r
         List<String> protocolNotifyList = new ArrayList<String>();\r
-        \r
+\r
         for (int i = 0; i < returns.length; i++) {\r
             List archList = ((ProtocolNotify) returns[i]).getSupArchList();\r
             if (archList == null || contains(archList, arch)){\r
                 protocolNotifyList.add(((ProtocolNotify) returns[i]).getProtocolNotifyCName());\r
             }\r
-            \r
+\r
         }\r
         String[] protocolNotifyArray = new String[protocolNotifyList.size()];\r
         for (int i = 0; i < protocolNotifyList.size(); i++) {\r
@@ -771,10 +774,10 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve ProtocolNotify for specified usage\r
-     * \r
+     *\r
      * @param usage\r
      *            ProtocolNotify usage\r
-     * \r
+     *\r
      * @returns String[] if elements are found at the known xpath\r
      * @returns String[0] if nothing is there\r
      */\r
@@ -811,7 +814,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve ModuleUnloadImage names\r
-     * \r
+     *\r
      * @returns ModuleUnloadImage name list if elements are found at the known\r
      *          xpath\r
      * @returns null if nothing is there\r
@@ -836,7 +839,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve Extern\r
-     * \r
+     *\r
      * @returns Extern objects list if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -853,10 +856,10 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve PpiNotify for specified arch\r
-     * \r
+     *\r
      * @param arch\r
      *            PpiNotify arch\r
-     * \r
+     *\r
      * @returns String[] if elements are found at the known xpath\r
      * @returns String[0] if nothing is there\r
      */\r
@@ -874,14 +877,14 @@ public class SurfaceAreaQuery {
             return new String[0];\r
         }\r
 \r
-        \r
+\r
         List<String> ppiNotifyList = new ArrayList<String>();\r
         for (int i = 0; i < returns.length; i++) {\r
             List archList = ((PPIsDocument.PPIs.PpiNotify) returns[i]).getSupArchList();\r
             if (archList == null || contains(archList, arch)){\r
-                ppiNotifyList.add(((PPIsDocument.PPIs.PpiNotify) returns[i]).getPpiNotifyCName()); \r
+                ppiNotifyList.add(((PPIsDocument.PPIs.PpiNotify) returns[i]).getPpiNotifyCName());\r
             }\r
-            \r
+\r
         }\r
         String[] ppiNotifyArray = new String[ppiNotifyList.size()];\r
         for (int i = 0; i < ppiNotifyList.size(); i++) {\r
@@ -893,11 +896,11 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve PpiNotify for specified usage and arch\r
-     * \r
+     *\r
      * @param arch\r
      *            PpiNotify arch usage PpiNotify usage\r
-     * \r
-     * \r
+     *\r
+     *\r
      * @returns String[] if elements are found at the known xpath\r
      * @returns String[0] if nothing is there\r
      */\r
@@ -934,10 +937,10 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve Ppi for specified arch\r
-     * \r
+     *\r
      * @param arch\r
      *            Ppi arch\r
-     * \r
+     *\r
      * @returns String[] if elements are found at the known xpath\r
      * @returns String[0] if nothing is there\r
      */\r
@@ -959,9 +962,9 @@ public class SurfaceAreaQuery {
         for (int i = 0; i < returns.length; i++) {\r
             List archList = ((PPIsDocument.PPIs.Ppi) returns[i]).getSupArchList();\r
             if (archList == null || contains(archList, arch)){\r
-                ppiList.add(((PPIsDocument.PPIs.Ppi) returns[i]).getPpiCName());    \r
+                ppiList.add(((PPIsDocument.PPIs.Ppi) returns[i]).getPpiCName());\r
             }\r
-            \r
+\r
         }\r
         String[] ppiArray = new String[ppiList.size()];\r
         for (int i = 0; i < ppiList.size(); i++) {\r
@@ -972,11 +975,11 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve PpiNotify for specified usage and arch\r
-     * \r
+     *\r
      * @param arch\r
      *            PpiNotify arch usage PpiNotify usage\r
-     * \r
-     * \r
+     *\r
+     *\r
      * @returns String[] if elements are found at the known xpath\r
      * @returns String[0] if nothing is there\r
      */\r
@@ -1013,10 +1016,10 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve GuidEntry information for specified usage\r
-     * \r
+     *\r
      * @param arch\r
      *            GuidEntry arch\r
-     * \r
+     *\r
      * @returns GuidEntry objects list if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -1038,9 +1041,9 @@ public class SurfaceAreaQuery {
         for (int i = 0; i < returns.length; i++) {\r
             List archList = ((GuidsDocument.Guids.GuidCNames) returns[i]).getSupArchList();\r
             if (archList == null || contains(archList, arch)){\r
-                guidList.add(((GuidsDocument.Guids.GuidCNames) returns[i]).getGuidCName());    \r
+                guidList.add(((GuidsDocument.Guids.GuidCNames) returns[i]).getGuidCName());\r
             }\r
-            \r
+\r
         }\r
         String[] guidArray = new String[guidList.size()];\r
         for (int i = 0; i < guidList.size(); i++) {\r
@@ -1052,10 +1055,10 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve GuidEntry information for specified usage\r
-     * \r
+     *\r
      * @param arch\r
      *            GuidEntry arch usage GuidEntry usage\r
-     * \r
+     *\r
      * @returns GuidEntry objects list if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -1091,12 +1094,12 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve Library instance information\r
-     * \r
+     *\r
      * @param arch\r
      *            Architecture name\r
      * @param usage\r
      *            Library instance usage\r
-     * \r
+     *\r
      * @returns library instance name list if elements are found at the known\r
      *          xpath\r
      * @returns null if nothing is there\r
@@ -1112,7 +1115,7 @@ public class SurfaceAreaQuery {
             xPath = new String[] { "/Instance" };\r
         } else {\r
             //\r
-            // Since Schema don't have SupArchList now, so the follow Xpath is \r
+            // Since Schema don't have SupArchList now, so the follow Xpath is\r
             // equal to "/Instance" and [not(@SupArchList) or @SupArchList= arch]\r
             // don't have effect.\r
             //\r
@@ -1167,7 +1170,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrive library's constructor name\r
-     * \r
+     *\r
      * @returns constructor name list if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -1185,7 +1188,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrive library's destructor name\r
-     * \r
+     *\r
      * @returns destructor name list if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -1206,7 +1209,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrive DriverBinding names\r
-     * \r
+     *\r
      * @returns DriverBinding name list if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -1217,7 +1220,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrive ComponentName names\r
-     * \r
+     *\r
      * @returns ComponentName name list if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -1228,7 +1231,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrive DriverConfig names\r
-     * \r
+     *\r
      * @returns DriverConfig name list if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -1239,7 +1242,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrive DriverDiag names\r
-     * \r
+     *\r
      * @returns DriverDiag name list if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -1250,7 +1253,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrive SetVirtualAddressMapCallBack names\r
-     * \r
+     *\r
      * @returns SetVirtualAddressMapCallBack name list if elements are found at\r
      *          the known xpath\r
      * @returns null if nothing is there\r
@@ -1262,7 +1265,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrive ExitBootServicesCallBack names\r
-     * \r
+     *\r
      * @returns ExitBootServicesCallBack name list if elements are found at the\r
      *          known xpath\r
      * @returns null if nothing is there\r
@@ -1274,7 +1277,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve module surface area file information\r
-     * \r
+     *\r
      * @returns ModuleSA objects list if elements are found at the known xpath\r
      * @returns Empty ModuleSA list if nothing is there\r
      */\r
@@ -1348,11 +1351,11 @@ public class SurfaceAreaQuery {
             }\r
             for (int j = 0; j < archList.length; j++) {\r
                 FpdModuleIdentification fpdSaId = new FpdModuleIdentification(saId, archList[j]);\r
-    \r
+\r
                 if (fvBinding != null) {\r
                     fpdSaId.setFvBinding(fvBinding);\r
                 }\r
-    \r
+\r
                 //\r
                 // Put element to Map<FpdModuleIdentification, Map<String,\r
                 // Object>>.\r
@@ -1365,7 +1368,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve valid image names\r
-     * \r
+     *\r
      * @returns valid iamges name list if elements are found at the known xpath\r
      * @returns empty list if nothing is there\r
      */\r
@@ -1384,37 +1387,37 @@ public class SurfaceAreaQuery {
 \r
         return result;\r
     }\r
-    \r
+\r
     public static Node getFpdUserExtensionPreBuild() {\r
-        String[] xPath = new String[] { "/UserExtensions[@UserID='TianoCore' and @Identifier='0']" }; \r
+        String[] xPath = new String[] { "/UserExtensions[@UserID='TianoCore' and @Identifier='0']" };\r
 \r
         Object[] queryResult = get("PlatformSurfaceArea", xPath);\r
         if (queryResult == null || queryResult.length == 0) {\r
             return null;\r
         }\r
         UserExtensionsDocument.UserExtensions a =  (UserExtensionsDocument.UserExtensions)queryResult[0];\r
-        \r
+\r
         return a.getDomNode();\r
     }\r
-    \r
+\r
     public static Node getFpdUserExtensionPostBuild() {\r
-        String[] xPath = new String[] { "/UserExtensions[@UserID='TianoCore' and @Identifier='1']" }; \r
+        String[] xPath = new String[] { "/UserExtensions[@UserID='TianoCore' and @Identifier='1']" };\r
 \r
         Object[] queryResult = get("PlatformSurfaceArea", xPath);\r
         if (queryResult == null || queryResult.length == 0) {\r
             return null;\r
         }\r
         UserExtensionsDocument.UserExtensions a =  (UserExtensionsDocument.UserExtensions)queryResult[0];\r
-        \r
+\r
         return a.getDomNode();\r
     }\r
 \r
     /**\r
      * Retrieve FV image option information\r
-     * \r
+     *\r
      * @param fvName\r
      *            FV image name\r
-     * \r
+     *\r
      * @returns option name/value list if elements are found at the known xpath\r
      * @returns empty list if nothing is there\r
      */\r
@@ -1478,10 +1481,10 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve FV image attributes information\r
-     * \r
+     *\r
      * @param fvName\r
      *            FV image name\r
-     * \r
+     *\r
      * @returns attribute name/value list if elements are found at the known\r
      *          xpath\r
      * @returns empty list if nothing is there\r
@@ -1495,7 +1498,7 @@ public class SurfaceAreaQuery {
         }\r
         ArrayList<String[]> list = new ArrayList<String[]>();\r
         for (int i = 0; i < queryResult.length; i++) {\r
-            \r
+\r
             FvImagesDocument.FvImages.FvImage.FvImageOptions item = (FvImagesDocument.FvImages.FvImage.FvImageOptions) queryResult[i];\r
             List<FvImagesDocument.FvImages.FvImage.FvImageOptions.NameValue> namevalues = item.getNameValueList();\r
             Iterator iter = namevalues.iterator();\r
@@ -1515,7 +1518,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve flash definition file name\r
-     * \r
+     *\r
      * @returns file name if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -1539,21 +1542,21 @@ public class SurfaceAreaQuery {
         }\r
 \r
         String[][] result = new String[queryResult.length][2];\r
-        \r
+\r
         for (int i = 0; i < queryResult.length; i++) {\r
             FvImagesDocument.FvImages.NameValue item = (FvImagesDocument.FvImages.NameValue)queryResult[i];\r
             result[i][0] = item.getName();\r
             result[i][1] = item.getValue();\r
         }\r
-        return result;   \r
+        return result;\r
     }\r
-    \r
+\r
     /**\r
      * Retrieve FV image component options\r
-     * \r
+     *\r
      * @param fvName\r
      *            FV image name\r
-     * \r
+     *\r
      * @returns name/value pairs list if elements are found at the known xpath\r
      * @returns empty list if nothing is there\r
      */\r
@@ -1580,12 +1583,12 @@ public class SurfaceAreaQuery {
                result[i][0] = list.get(i)[0];\r
              result[i][1] = list.get(i)[1];\r
         }\r
-            return result;  \r
+            return result;\r
     }\r
 \r
     /**\r
      * Retrieve PCD tokens\r
-     * \r
+     *\r
      * @returns CName/ItemType pairs list if elements are found at the known\r
      *          xpath\r
      * @returns null if nothing is there\r
@@ -1603,7 +1606,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve MAS header\r
-     * \r
+     *\r
      * @return\r
      * @return\r
      */\r
@@ -1635,12 +1638,12 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve Extern Specification\r
-     * \r
+     *\r
      * @param\r
-     * \r
+     *\r
      * @return String[] If have specification element in the <extern> String[0]\r
      *         If no specification element in the <extern>\r
-     * \r
+     *\r
      */\r
 \r
     public static String[] getExternSpecificaiton() {\r
@@ -1661,7 +1664,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retreive MsaFile which in SPD\r
-     * \r
+     *\r
      * @param\r
      * @return String[][3] The string sequence is ModuleName, ModuleGuid,\r
      *         ModuleVersion, MsaFile String[0][] If no msafile in SPD\r
@@ -1811,7 +1814,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * getSpdPpi() Retrieve the SPD PPI Entry\r
-     * \r
+     *\r
      * @param\r
      * @return Map<String, String[2]> if get the PPI entry from SPD. Key - PPI\r
      *         Name String[0] - PPI CNAME String[1] - PPI Guid Null if no PPI\r
@@ -1843,7 +1846,7 @@ public class SurfaceAreaQuery {
 \r
     /**\r
      * Retrieve module Guid string\r
-     * \r
+     *\r
      * @returns GUILD string if elements are found at the known xpath\r
      * @returns null if nothing is there\r
      */\r
@@ -1875,7 +1878,7 @@ public class SurfaceAreaQuery {
     /**\r
     Get name array of PCD in a module. In one module, token space\r
     is same, and token name should not be conflicted.\r
-    \r
+\r
     @return String[]\r
     **/\r
     public static String[] getModulePcdEntryNameArray() {\r
@@ -1927,7 +1930,7 @@ public class SurfaceAreaQuery {
         }\r
 \r
                ExternsDocument.Externs ext = (ExternsDocument.Externs)returns[0];\r
-               \r
+\r
                if (ext.getTianoR8FlashMapH()){\r
                        return true;\r
            }else {\r
index 66d38f962c8de6e9d4a2a2e081acfd48a0789c96..6e26adee0136c1d6b40998259d76998223c8c821 100644 (file)
@@ -1,8 +1,8 @@
 /** @file\r
   ConfigReader class.\r
-  \r
-  ConfigReader is used to read tool chain config file with flat format. \r
-  \r
+\r
+  ConfigReader is used to read tool chain config file with flat format.\r
+\r
 Copyright (c) 2006, Intel Corporation\r
 All rights reserved. This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
@@ -14,7 +14,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 **/\r
 package org.tianocore.build.toolchain;\r
 \r
-import org.tianocore.exception.EdkException;\r
+import org.tianocore.common.exception.EdkException;\r
 \r
 import java.io.BufferedReader;\r
 import java.io.File;\r
@@ -23,10 +23,10 @@ import java.util.ArrayList;
 import java.util.List;\r
 \r
 /**\r
-  \r
+\r
   ConfigReader is used to read tool chain config file with flat format. Comments\r
   is line starting with character '#'.\r
-  \r
+\r
   @since GenBuild 1.0\r
 **/\r
 public class ConfigReader {\r
@@ -35,14 +35,14 @@ public class ConfigReader {
 \r
 \r
     /**\r
-      Public construct method. \r
+      Public construct method.\r
     **/\r
     public ConfigReader () {\r
     }\r
 \r
     /**\r
       Default filepath is ".".\r
-    \r
+\r
       @param filename the config file name like "target.txt"\r
       @return the variables defined in file\r
     **/\r
@@ -52,8 +52,8 @@ public class ConfigReader {
 \r
     /**\r
       Get all variables defined in config file. the config file format is flat\r
-      with "A=B". If line started with '#' looks as comments. \r
-    \r
+      with "A=B". If line started with '#' looks as comments.\r
+\r
       @param confPath the path of config file\r
       @param filename the file name of the config file\r
       @return the variables defined in the config file\r
@@ -78,7 +78,7 @@ public class ConfigReader {
                 // without '=', or start with '='\r
                 //\r
                 int index;\r
-                if (str.length() == 0 || str.startsWith("#") || \r
+                if (str.length() == 0 || str.startsWith("#") ||\r
                     (index = str.indexOf('=')) <= 0) {\r
                     continue;\r
                 }\r
@@ -101,7 +101,7 @@ public class ConfigReader {
 \r
     public static synchronized ToolChainMap parseToolChainConfig(File ConfigFile) throws EdkException {\r
         ToolChainMap map = new ToolChainMap();\r
-    \r
+\r
         try {\r
             FileReader reader = new FileReader(ConfigFile);\r
             BufferedReader in = new BufferedReader(reader);\r
@@ -114,7 +114,7 @@ public class ConfigReader {
                 // without '=', or start with '='\r
                 //\r
                 int index;\r
-                if (str.length() == 0 || str.startsWith("#") || \r
+                if (str.length() == 0 || str.startsWith("#") ||\r
                     (index = str.indexOf('=')) <= 0) {\r
                     continue;\r
                 }\r
index 891035ca1efa1e4904350e1151b2e6aef8f534f3..4082c6dd43682c3998d89593b802190caeb3adbd 100644 (file)
@@ -1,8 +1,8 @@
 /** @file\r
   ToolChainConfig class.\r
-  \r
+\r
   ToolChainFactory class parse all config files and get tool chain information.\r
-  \r
+\r
 Copyright (c) 2006, Intel Corporation\r
 All rights reserved. This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
@@ -16,7 +16,8 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 package org.tianocore.build.toolchain;\r
 \r
 import org.apache.tools.ant.BuildException;\r
-import org.tianocore.exception.EdkException;\r
+\r
+import org.tianocore.common.exception.EdkException;\r
 import org.tianocore.build.toolchain.ToolChainKey;\r
 import org.tianocore.build.toolchain.ToolChainMap;\r
 \r
@@ -26,9 +27,9 @@ import java.util.Set;
 \r
 \r
 /**\r
\r
+\r
   ToolChainFactory class parse all config files and get tool chain information.\r
-  \r
+\r
  **/\r
 public class ToolChainConfig {\r
     ///\r
@@ -37,7 +38,7 @@ public class ToolChainConfig {
     private ToolChainMap config = null;\r
     ///\r
     /// tool chain information (how many targets, archs, etc.)\r
-    /// \r
+    ///\r
     private ToolChainInfo info = new ToolChainInfo();\r
 \r
     /**\r
@@ -48,7 +49,7 @@ public class ToolChainConfig {
 \r
     /**\r
       Public construct method.\r
-      \r
+\r
       @param toolChainFile File object representing the tool chain configuration file\r
     **/\r
     public ToolChainConfig (File toolChainFile) {\r
@@ -64,7 +65,7 @@ public class ToolChainConfig {
     /**\r
      Collect target, tool chain tag, arch and command information from key part\r
      of configuration\r
-      \r
+\r
      @param toolChainDefKey The set of keys in tool chain configuration\r
      **/\r
     private void parseToolChainDefKey (Set<ToolChainKey> toolChainDefKey) {\r
@@ -80,8 +81,8 @@ public class ToolChainConfig {
     }\r
 \r
     /**\r
-     Return the tool chain configuration information in a Map form \r
-      \r
+     Return the tool chain configuration information in a Map form\r
+\r
      @return ToolChainMap Tool chain configurations in a ToolChainMap\r
      **/\r
     public ToolChainMap getConfig() {\r
@@ -90,7 +91,7 @@ public class ToolChainConfig {
 \r
     /**\r
      Return the tool chain's target, arch, tag and commands information\r
-     \r
+\r
       @return ToolChainInfo\r
      **/\r
     public ToolChainInfo getConfigInfo() {\r
@@ -99,7 +100,7 @@ public class ToolChainConfig {
 \r
     /**\r
      override toString()\r
-     \r
+\r
      @return String The converted configuration string in name=value form\r
      **/\r
     public String toString() {\r
index f6e1e067f898e6e47b98d5020c15e7f2e8a1ed4d..f71fe3a3335f8c97d72844569a2ef86d3d0cb636 100644 (file)
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 \r
 package org.tianocore.build.toolchain;\r
 \r
-import org.tianocore.exception.EdkException;\r
+import org.tianocore.common.exception.EdkException;\r
 \r
 public class ToolChainKey implements java.io.Serializable, Comparable<ToolChainKey> {\r
     static final long serialVersionUID = -8034897190740066933L;\r