]> git.proxmox.com Git - mirror_edk2.git/blob - Tools/Java/Source/Cpptasks/build.xml
971e7e774cf804ca9ab343d5f5e226cea09e5677
[mirror_edk2.git] / Tools / Java / Source / Cpptasks / build.xml
1 <?xml version="1.0"?>
2 <!--
3 Copyright (c) 2006, Intel Corporation
4 All rights reserved. This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php
8
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
11 -->
12 <project name="CppTasks" default="CppTasks" basedir=".">
13 <taskdef resource="net/sf/antcontrib/antlib.xml"/>
14 <property environment="env"/>
15 <property name="workspace" value="${env.WORKSPACE}"/>
16 <property name="buildDir" value="build"/>
17 <property name="installLocation" value="${workspace}/Tools/Jars"/>
18 <target name="CppTasks" depends="install"/>
19 <target name="init">
20 <uptodate property="jar.newer" targetfile="${installLocation}/cpptasks.jar">
21 <srcfiles dir="net" includes="**"/>
22 </uptodate>
23 </target>
24 <target name="source" depends="init" unless="jar.newer">
25 <mkdir dir="${buildDir}"/>
26 <javac srcdir="net" destdir="${buildDir}" source="1.4">
27 <classpath>
28 <fileset dir="${workspace}/Tools/Jars">
29 <include name="*.jar"/>
30 </fileset>
31 </classpath>
32 </javac>
33 </target>
34 <target name="clean">
35 <delete includeemptydirs="true" failonerror="false">
36 <fileset dir="${WORKSPACE}/Tools/Java/Source/Cpptasks" includes="${buildDir}"/>
37 </delete>
38 </target>
39 <target name="cleanall" depends="clean">
40 <delete file="${installLocation}/cpptasks.jar"/>
41 <if>
42 <available file="${installLocation}/cpptasks.jar"/>
43 <then>
44 <echo message="You must manually remove the file: ${installLocation}/cpptasks.jar"/>
45 <echo message="Java has already loaded the file, and cannot remove it within ANT!"/>
46 </then>
47 </if>
48 </target>
49 <target name="install" depends="source" unless="jar.newer">
50 <copy file="cpptasks.tasks" toDir="${buildDir}"/>
51 <copy file="cpptasks.types" toDir="${buildDir}"/>
52 <jar destfile="${installLocation}/cpptasks.jar"
53 basedir="${buildDir}"
54 includes="**"
55 />
56 </target>
57 </project>