]> git.proxmox.com Git - mirror_edk2.git/blobdiff - Tools/Source/Common/build.xml
Add exception and log mechanism
[mirror_edk2.git] / Tools / Source / Common / build.xml
diff --git a/Tools/Source/Common/build.xml b/Tools/Source/Common/build.xml
new file mode 100644 (file)
index 0000000..ad517cd
--- /dev/null
@@ -0,0 +1,45 @@
+<?xml version="1.0"?>\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
+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
+<project name="Common" default="all" basedir=".">\r
+\r
+  <taskdef resource="net/sf/antcontrib/antlib.xml"/>\r
+  <property environment="env"/>\r
+  <property name="WORKSPACE" value="${env.WORKSPACE}"/>\r
+  <property name="buildDir" value="build"/>\r
+  <property name="installLocation" value="${WORKSPACE}/Tools/Jars"/>\r
+  <target name="all" depends="install"/>\r
+  <target name="source">\r
+    <mkdir dir="${buildDir}"/>\r
+    <javac srcdir="." destdir="${buildDir}">\r
+      <compilerarg value="-Xlint"/>\r
+    </javac>\r
+  </target>\r
+  <target name="clean">\r
+    <delete dir="${buildDir}"/>\r
+  </target>\r
+  <target name="cleanall">\r
+    <delete dir="${buildDir}"/>\r
+    <if>\r
+      <available file="${installLocation}/Common.jar"/>\r
+      <then>\r
+        <echo message="You must manually remove the file: ${installLocation}/Common.jar"/>\r
+        <echo message="Java has already loaded the file, and cannot remove it within ANT!"/>\r
+      </then>\r
+    </if>\r
+  </target>\r
+  <target name="install" depends="source">\r
+    <jar destfile="${installLocation}/Common.jar"\r
+      basedir="${buildDir}"\r
+      includes="**"\r
+    />\r
+  </target>\r
+</project>\r