Fixed the build.xml files so that clean and cleanall actually removes the temporary...
[mirror_edk2.git] / Tools / build.xml
CommitLineData
878ddf1f 1<?xml version="1.0"?>\r
2<!--\r
3Copyright (c) 2006, Intel Corporation\r
4All rights reserved. This program and the accompanying materials\r
5are licensed and made available under the terms and conditions of the BSD License\r
6which accompanies this distribution. The full text of the license may be found at\r
7http://opensource.org/licenses/bsd-license.php\r
8\r
9THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
10WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
11-->\r
12<project name="Tools" default="all" basedir=".">\r
13\r
3c8842bc 14 <taskdef resource="net/sf/antcontrib/antlib.xml"/>\r
878ddf1f 15 <property environment="env"/>\r
16\r
c80da0c4 17 <target name="all" depends="C_Code">\r
18 <echo message="The EDK II Tools build has completed!"/>\r
19 </target>\r
a7828769 20\r
21 <target name="C_Code" depends="JavaCode">\r
22 <subant target="" inheritall="false">\r
23 <filelist dir="."\r
24 files="\r
ecb33821 25 CCode/Source/build.xml\r
a7828769 26 "/>\r
27 </subant>\r
28 </target>\r
29\r
878ddf1f 30 <target name="JavaCode" depends="SurfaceArea">\r
31 <subant target="" verbose="true" inheritall="false">\r
32 <!-- Note: this is an ordered list. The projects have dependencies between them. -->\r
33 <filelist dir="."\r
34 files="\r
feccee87 35 Java/Source/Common/build.xml\r
36 Java/Source/PcdTools/build.xml\r
37 Java/Source/GenBuild/build.xml\r
38 Java/Source/FrameworkTasks/build.xml\r
39 Java/Source/Cpptasks/build.xml\r
40 Java/Source/FrameworkWizard/build.xml\r
41 Java/Source/MigrationTools/build.xml\r
42 Java/Source/ContextTool/build.xml\r
43 Java/Source/Merge/build.xml\r
ee80c4d0 44 "/>\r
878ddf1f 45 </subant>\r
c80da0c4 46 <echo message="The EDK II Java Tools build has completed!"/>\r
47 </target>\r
48\r
49 <target name="Wizard" depends="SurfaceArea">\r
50 <subant target="" verbose="true" inheritall="false">\r
51 <!-- Note: this is an ordered list. The projects have dependencies between them. -->\r
52 <filelist dir="."\r
53 files="\r
feccee87 54 Java/Source/FrameworkWizard/build.xml\r
c80da0c4 55 "/>\r
56 </subant>\r
878ddf1f 57 </target>\r
58\r
ee2db093 59 <target name="Merge" depends="SurfaceArea">\r
60 <subant target="" verbose="true" inheritall="false">\r
61 <filelist dir="."\r
62 files="\r
feccee87 63 Java/Source/Merge/build.xml\r
ee2db093 64 "/>\r
65 </subant>\r
66 </target>\r
67\r
878ddf1f 68 <target name="SurfaceArea" depends="makeCatalog">\r
69 <subant target="" verbose="true" inheritall="false">\r
70 <filelist dir="."\r
71 files="\r
feccee87 72 Java/Source/SurfaceArea/build.xml\r
878ddf1f 73 "/>\r
74 </subant>\r
75 </target>\r
76\r
878ddf1f 77 <target name="makeCatalog">\r
c7794830 78 <if>\r
79 <not>\r
80 <available file="XMLSchema/catalog.xml"/>\r
81 </not>\r
82 <then>\r
83 <echo file="XMLSchema/catalog.xml"><![CDATA[<?xml version="1.0"?>\r
878ddf1f 84<!DOCTYPE catalog PUBLIC "-//OASIS//DTD Entity Resolution XML Catalog V1.0//EN" "http://www.oasis-open.org/committees/entity/release/1.0/catalog.xsd">\r
85<catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog">\r
86 <rewriteSystem systemIdStartString="http://www.TianoCore.org/2006/Edk2.0/"\r
87 rewritePrefix="file:/]]>${env.WORKSPACE}<![CDATA[/Tools/XMLSchema/"/>\r
88 <rewriteURI uriStartString="http://www.TianoCore.org/2006/Edk2.0/"\r
89 rewritePrefix="file:/]]>${env.WORKSPACE}<![CDATA[/Tools/XMLSchema/"/>\r
90</catalog>]]>\r
c7794830 91</echo>\r
92 </then>\r
93 </if>\r
e5890ee5 94 <if>\r
95 <not>\r
96 <available file="Conf/tools_def.txt"/>\r
97 </not>\r
98 <then>\r
99 <copy file="Conf/tools_def.template" tofile="Conf/tools_def.txt"/>\r
100 </then>\r
101 </if>\r
102\r
103 <if>\r
104 <not>\r
105 <available file="Conf/target.txt"/>\r
106 </not>\r
107 <then>\r
108 <copy file="Conf/target.template" tofile="Conf/target.txt"/>\r
109 </then>\r
110 </if>\r
111\r
3c8842bc 112 <if>\r
113 <not>\r
114 <available file="Conf/FrameworkDatabase.db"/>\r
115 </not>\r
116 <then>\r
117 <copy file="Conf/FrameworkDatabase.template" tofile="Conf/FrameworkDatabase.db"/>\r
118 </then>\r
119 </if>\r
878ddf1f 120 </target>\r
2a8198da 121\r
878ddf1f 122 <target name="clean">\r
123 <subant target="clean" inheritall="false">\r
124 <filelist dir="."\r
125 files="\r
feccee87 126 Java/Source/FrameworkWizard/build.xml \r
127 Java/Source/Cpptasks/build.xml \r
128 Java/Source/FrameworkTasks/build.xml \r
129 Java/Source/GenBuild/build.xml \r
130 Java/Source/PcdTools/build.xml \r
131 Java/Source/Common/build.xml \r
132 Java/Source/SurfaceArea/build.xml \r
28305207 133 CCode/Source/build.xml\r
feccee87 134 Java/Source/MigrationTools/build.xml\r
135 Java/Source/ContextTool/build.xml\r
136 Java/Source/Merge/build.xml\r
7f762c2d 137 "/>\r
878ddf1f 138 </subant>\r
139 </target>\r
2a8198da 140\r
878ddf1f 141 <target name="cleanall">\r
8a07290e 142 <available classname="org.tianocore.frameworkwizard.FrameworkWizardUI" property="FrameworkWizardUI.available"/>\r
143 <available classname="org.tianocore.build.GenBuildTask" property="GenBuildTask.available"/>\r
144 <available classname="org.tianocore.framework.tasks.Tool" property="Tool.available"/>\r
145 <available classname="org.tianocore.pcd.action.BuildAction" property="PcdClass.available"/>\r
146 <if>\r
147 <or>\r
148 <isset property="FrameworkWizardUI.available"/>\r
149 <isset property="GenBuildTask.available"/>\r
150 <isset property="Tool.available"/>\r
151 <isset property="PcdClass.available"/>\r
152 </or>\r
153 <then>\r
154 <fail message="Use ant -noclasspath cleanall, to remove all jar files!"/>\r
155 </then>\r
156 </if>\r
7f762c2d 157 <subant target="cleanall" inheritall="true">\r
878ddf1f 158 <filelist dir="."\r
159 files="\r
feccee87 160 Java/Source/FrameworkWizard/build.xml \r
161 Java/Source/Cpptasks/build.xml \r
162 Java/Source/FrameworkTasks/build.xml \r
163 Java/Source/GenBuild/build.xml \r
164 Java/Source/PcdTools/build.xml \r
165 Java/Source/Common/build.xml \r
166 Java/Source/SurfaceArea/build.xml \r
28305207 167 CCode/Source/build.xml\r
feccee87 168 Java/Source/MigrationTools/build.xml\r
169 Java/Source/ContextTool/build.xml\r
170 Java/Source/Merge/build.xml\r
7f762c2d 171 "/>\r
878ddf1f 172 </subant>\r
173 </target>\r
174</project>\r