blob: 4b02c253f65789068e197a111662fbcb1ab8ee3f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
|
<?xml version="1.0"?>
<!--
Copyright (c) 2006, Intel Corporation
All rights reserved. This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
http://opensource.org/licenses/bsd-license.php
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-->
<project name="Tools" default="all" basedir=".">
<taskdef resource="net/sf/antcontrib/antlib.xml"/>
<property environment="env"/>
<target name="all" depends="C_Code">
<echo message="The EDK II Tools build has completed!"/>
</target>
<target name="C_Code" depends="JavaCode">
<subant target="" inheritall="false">
<filelist dir="."
files="
CCode/Source/build.xml
"/>
</subant>
</target>
<target name="JavaCode" depends="SurfaceArea">
<subant target="" verbose="true" inheritall="false">
<!-- Note: this is an ordered list. The projects have dependencies between them. -->
<filelist dir="."
files="
Java/Source/Common/build.xml
Java/Source/PcdTools/build.xml
Java/Source/GenBuild/build.xml
Java/Source/FrameworkTasks/build.xml
Java/Source/Cpptasks/build.xml
Java/Source/FrameworkWizard/build.xml
Java/Source/MigrationTools/build.xml
Java/Source/ContextTool/build.xml
Java/Source/Merge/build.xml
Java/Source/CheckTools/build.xml
Java/Source/DbTools/build.xml
"/>
</subant>
<echo message="The EDK II Java Tools build has completed!"/>
</target>
<target name="Wizard" depends="SurfaceArea">
<subant target="" verbose="true" inheritall="false">
<!-- Note: this is an ordered list. The projects have dependencies between them. -->
<filelist dir="."
files="
Java/Source/FrameworkWizard/build.xml
"/>
</subant>
</target>
<target name="Merge" depends="SurfaceArea">
<subant target="" verbose="true" inheritall="false">
<filelist dir="."
files="
Java/Source/Merge/build.xml
"/>
</subant>
</target>
<target name="SurfaceArea" depends="makeCatalog">
<subant target="" verbose="true" inheritall="false">
<filelist dir="."
files="
Java/Source/SurfaceArea/build.xml
"/>
</subant>
</target>
<target name="makeCatalog">
<if>
<not>
<available file="XMLSchema/catalog.xml"/>
</not>
<then>
<echo file="XMLSchema/catalog.xml"><![CDATA[<?xml version="1.0"?>
<!DOCTYPE catalog PUBLIC "-//OASIS//DTD Entity Resolution XML Catalog V1.0//EN" "http://www.oasis-open.org/committees/entity/release/1.0/catalog.xsd">
<catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog">
<rewriteSystem systemIdStartString="http://www.TianoCore.org/2006/Edk2.0/"
rewritePrefix="file:/]]>${env.WORKSPACE}<![CDATA[/Tools/XMLSchema/"/>
<rewriteURI uriStartString="http://www.TianoCore.org/2006/Edk2.0/"
rewritePrefix="file:/]]>${env.WORKSPACE}<![CDATA[/Tools/XMLSchema/"/>
</catalog>]]>
</echo>
</then>
</if>
<if>
<not>
<available file="Conf/tools_def.txt"/>
</not>
<then>
<copy file="Conf/tools_def.template" tofile="Conf/tools_def.txt"/>
</then>
</if>
<if>
<not>
<available file="Conf/target.txt"/>
</not>
<then>
<copy file="Conf/target.template" tofile="Conf/target.txt"/>
</then>
</if>
<if>
<not>
<available file="Conf/FrameworkDatabase.db"/>
</not>
<then>
<copy file="Conf/FrameworkDatabase.template" tofile="Conf/FrameworkDatabase.db"/>
</then>
</if>
</target>
<target name="reconfig">
<!-- backup all config files -->
<if>
<available file="Conf/target.txt"/>
<then>
<echo message="Backup Conf/target.txt to Conf/target.txt.bak" />
<copy file="Conf/target.txt" tofile="Conf/target.txt.bak" overwrite="true" />
</then>
</if>
<if>
<available file="Conf/tools_def.txt"/>
<then>
<echo message="Backup Conf/tools_def.txt to Conf/tools_def.txt.bak" />
<copy file="Conf/tools_def.txt" tofile="Conf/tools_def.txt.bak" overwrite="true" />
</then>
</if>
<if>
<available file="Conf/FrameworkDatabase.db"/>
<then>
<echo message="Backup Conf/FrameworkDatabase.db to Conf/FrameworkDatabase.db.bak" />
<copy file="Conf/FrameworkDatabase.db" tofile="Conf/FrameworkDatabase.db.bak" overwrite="true" />
</then>
</if>
<if>
<available file="Conf/tools_def.template"/>
<then>
<echo message="Copy file from Conf/tools_def.template to Conf/tools_def.txt" />
<copy file="Conf/tools_def.template" tofile="Conf/tools_def.txt" overwrite="true" />
</then>
</if>
<if>
<available file="Conf/target.template"/>
<then>
<echo message="Copy file from Conf/target.template to Conf/target.txt" />
<copy file="Conf/target.template" tofile="Conf/target.txt" overwrite="true" />
</then>
</if>
<if>
<available file="Conf/FrameworkDatabase.template"/>
<then>
<echo message="Copy file from Conf/FrameworkDatabase.template to Conf/FrameworkDatabase.db" />
<copy file="Conf/FrameworkDatabase.template" tofile="Conf/FrameworkDatabase.db" overwrite="true" />
</then>
</if>
</target>
<target name="clean">
<subant target="clean" inheritall="false">
<filelist dir="."
files="
Java/Source/FrameworkWizard/build.xml
Java/Source/Cpptasks/build.xml
Java/Source/FrameworkTasks/build.xml
Java/Source/GenBuild/build.xml
Java/Source/PcdTools/build.xml
Java/Source/Common/build.xml
Java/Source/SurfaceArea/build.xml
Java/Source/MigrationTools/build.xml
Java/Source/ContextTool/build.xml
Java/Source/Merge/build.xml
Java/Source/CheckTools/build.xml
Java/Source/DbTools/build.xml
CCode/Source/build.xml
"/>
</subant>
</target>
<target name="cleanall">
<echo message="Removing extra ${env.WORKSPACE} history.xml files!"/>
<if>
<available file="${env.WORKSPACE}/Tools/bin/history.xml"/>
<then>
<delete failonerror="false" quiet="true">
<fileset file="${env.WORKSPACE}/Tools/bin/history.xml"/>
</delete>
</then>
</if>
<if>
<available file="${env.WORKSPACE}/Tools/CCode/Source/Library/history.xml"/>
<then>
<delete failonerror="false" quiet="true">
<fileset file="${env.WORKSPACE}/Tools/CCode/Source/Library/history.xml"/>
</delete>
</then>
</if>
<available classname="org.tianocore.frameworkwizard.FrameworkWizardUI" property="FrameworkWizardUI.available"/>
<available classname="org.tianocore.build.GenBuildTask" property="GenBuildTask.available"/>
<available classname="org.tianocore.framework.tasks.Tool" property="Tool.available"/>
<available classname="org.tianocore.pcd.action.BuildAction" property="PcdClass.available"/>
<if>
<or>
<isset property="FrameworkWizardUI.available"/>
<isset property="GenBuildTask.available"/>
<isset property="Tool.available"/>
<isset property="PcdClass.available"/>
</or>
<then>
<fail message="Use ant -noclasspath cleanall, to remove all jar files!"/>
</then>
</if>
<subant target="cleanall" inheritall="true">
<filelist dir="."
files="
Java/Source/FrameworkWizard/build.xml
Java/Source/Cpptasks/build.xml
Java/Source/FrameworkTasks/build.xml
Java/Source/GenBuild/build.xml
Java/Source/PcdTools/build.xml
Java/Source/Common/build.xml
Java/Source/SurfaceArea/build.xml
Java/Source/MigrationTools/build.xml
Java/Source/ContextTool/build.xml
Java/Source/Merge/build.xml
Java/Source/CheckTools/build.xml
Java/Source/DbTools/build.xml
CCode/Source/build.xml
"/>
</subant>
</target>
</project>
|