blob: c113c95c3a7f0df4cd5dca3a8d7c0dd8df3d34ed [file] [log] [blame]
david_williamsae0e4cb2006-11-11 02:55:51 +00001<project
2 name="Build specific targets and properties"
3 default="noDefault">
4
5 <!-- ===================================================================== -->
6 <!-- Run a given ${target} on all elements being built -->
7 <!-- Add on <ant> task for each top level element being built. -->
8 <!-- ===================================================================== -->
9 <target name="allElements">
10 <echo message="Target:${target} " />
11 <echo message="basedir: ${basedir}" />
david_williamsae0e4cb2006-11-11 02:55:51 +000012 <echo message="buildDirectory: ${buildDirectory}" />
13 <echo message="baseLocation: ${baseLocation}" />
14 <echo message="generic target: ${genericTargets}" />
david_williamsd913e922006-11-13 07:24:21 +000015 <ant
16 antfile="${genericTargets}"
17 target="${target}">
18 <property
19 name="type"
20 value="feature" />
21 <property
22 name="id"
david_williamseb49d082007-05-01 03:03:15 +000023 value="org.eclipse.jpt.sdk" />
david_williamsae0e4cb2006-11-11 02:55:51 +000024 </ant>
25 </target>
26
27 <!-- ===================================================================== -->
28 <!-- Targets to assemble the built elements for particular configurations -->
29 <!-- These generally call the generated assemble scripts (named in -->
30 <!-- ${assembleScriptName}) but may also add pre and post processing -->
31 <!-- Add one target for each root element and each configuration -->
32 <!-- ===================================================================== -->
33
david_williamseb49d082007-05-01 03:03:15 +000034 <target name="assemble.org.eclipse.jpt.sdk">
david_williamsd913e922006-11-13 07:24:21 +000035 <property
36 name="archiveName"
david_williamseb49d082007-05-01 03:03:15 +000037 value="wtp-jpt-sdk-${buildLabel}.zip" />
david_williamsd913e922006-11-13 07:24:21 +000038 <ant
39 antfile="${assembleScriptName}"
40 dir="${buildDirectory}" />
41 </target>
42
43 <target name="prePackage" />
44
45 <target name="postPackage">
46 <property
47 name="archiveName"
david_williamseb49d082007-05-01 03:03:15 +000048 value="wtp-jpt-sdk-${buildLabel}.zip" />
david_williamsd913e922006-11-13 07:24:21 +000049
50 <ant
51 antfile="${wtp.builder.home}/scripts/build/buildutilities.xml"
52 target="unpackUpdateJarsAndCreateZippedPackages">
53 <property
54 name="buildDirectory"
55 value="${buildDirectory}" />
56 <property
57 name="buildLabel"
58 value="${buildLabel}" />
59 <property
60 name="archiveName"
61 value="${archiveName}" />
62 </ant>
63
64 </target>
david_williamsae0e4cb2006-11-11 02:55:51 +000065
66 <!-- ===================================================================== -->
67 <!-- Check out map files from correct repository -->
68 <!-- Replace values for cvsRoot, package and mapVersionTag as desired. -->
69 <!-- ===================================================================== -->
70 <target name="checkLocal">
71 <available
72 property="mapsLocal"
73 file="${buildDirectory}/maps/releng.dali" />
74 </target>
75 <target
76 name="getMapFiles"
77 depends="checkLocal"
78 unless="mapsLocal">
79
80 <!-- *** change the repo info -->
81 <property
82 name="mapCvsRoot"
83 value=":${cvsProtocol}:${cvsUser}@${cvsServer}:${cvsRoot}" />
84 <property
85 name="mapVersionTag"
86 value="HEAD" />
david_williams0b74c592007-04-09 06:11:35 +000087
david_williamsd913e922006-11-13 07:24:21 +000088 <property
89 name="cvsPackage"
90 value="releng.dali" />
91 <echo message="${mapCvsRoot} ${mapVersionTag} " />
92 <echo message="cvsPackage = ${cvsPackage} " />
david_williamsae0e4cb2006-11-11 02:55:51 +000093
94 <cvs
95 cvsRoot="${mapCvsRoot}"
96 package="${cvsPackage}"
97 dest="${buildDirectory}/maps"
98 tag="${mapVersionTag}" />
david_williams0b74c592007-04-09 06:11:35 +000099
david_williamsae0e4cb2006-11-11 02:55:51 +0000100 <!--tag the map files project-->
101 <antcall target="tagMapFiles">
102 <param
103 name="mapCvsRoot"
104 value="${mapCvsRoot}" />
105 </antcall>
106 </target>
107
david_williams6ac0ea22007-02-28 02:25:23 +0000108 <!-- ===================================================================== -->
109 <!-- Check out the cvsPackage -->
110 <!-- ===================================================================== -->
111 <target name="checkOutMaps">
112 <echo message="${mapCvsRoot} ${mapVersionTag} " />
113 <echo message="cvsPackage = ${cvsPackage} " />
114 <cvs
115 cvsRoot="${mapCvsRoot}"
116 package="${cvsPackage}"
117 dest="${buildDirectory}/maps"
118 tag="${mapVersionTag}" />
119 </target>
120
121 <!-- ===================================================================== -->
122 <!-- Tag Map Files mapCvsRoot -->
123 <!-- ===================================================================== -->
david_williamsae0e4cb2006-11-11 02:55:51 +0000124 <target
125 name="tagMapFiles"
126 if="tagMaps">
127 <cvs
128 cvsRoot="${mapCvsRoot}"
129 dest="${buildDirectory}/maps"
130 command="tag v${buildType}${timestamp}" />
131 </target>
132
david_williamsae0e4cb2006-11-11 02:55:51 +0000133 <!-- ===================================================================== -->
134 <!-- Steps to do before setup -->
135 <!-- ===================================================================== -->
136 <target name="preSetup"></target>
137
138 <!-- ===================================================================== -->
139 <!-- Steps to do after setup but before starting the build proper -->
140 <!-- ===================================================================== -->
141 <target name="postSetup">
david_williamsd913e922006-11-13 07:24:21 +0000142 <dirname
143 file="${ant.file}"
144 property="component.dir" />
david_williamsae0e4cb2006-11-11 02:55:51 +0000145 <echo message="ant.file: ${ant.file}" />
146 <echo message="component.dir: ${component.dir}" />
147
david_williamsd913e922006-11-13 07:24:21 +0000148 <ant
149 antfile="${component.dir}/dependency.xml"
150 target="get">
151 <property
152 name="dependency.properties"
153 value="${buildDirectory}/maps/releng/maps/dependencies.properties" />
154 <property
155 name="base.install.dir"
156 value="${buildRoot}" />
david_williamsae0e4cb2006-11-11 02:55:51 +0000157 </ant>
david_williamsd913e922006-11-13 07:24:21 +0000158
david_williamsae0e4cb2006-11-11 02:55:51 +0000159 </target>
160
161 <!-- ===================================================================== -->
162 <!-- Steps to do before fetching the build elements -->
163 <!-- ===================================================================== -->
164 <target name="preFetch"></target>
165
166 <!-- ===================================================================== -->
167 <!-- Steps to do after fetching the build elements -->
168 <!-- ===================================================================== -->
169 <target name="postFetch"></target>
170
171 <!-- ===================================================================== -->
172 <!-- Steps to do before generating the build scripts. -->
173 <!-- ===================================================================== -->
david_williams0b74c592007-04-09 06:11:35 +0000174 <target name="postGenerate">
175 <customizeAccessRules bundleDirectory="${buildDirectory}/plugins" defaultRules="+org/eclipse/wst/**/*, +org/eclipse/jst/**/*" />
176 </target>
david_williamsae0e4cb2006-11-11 02:55:51 +0000177 <!-- ===================================================================== -->
178 <!-- Steps to do after generating the build scripts. -->
179 <!-- ===================================================================== -->
david_williams0b74c592007-04-09 06:11:35 +0000180 <target name="preGenerate"></target>
david_williamsae0e4cb2006-11-11 02:55:51 +0000181
182
183 <!-- ===================================================================== -->
184 <!-- Steps to do before running the build.xmls for the elements being built. -->
185 <!-- ===================================================================== -->
186 <target name="preProcess">
187 <replace
188 dir="${buildDirectory}/plugins"
189 value="${timestamp}"
190 token="@build@">
191 <include name="**/about.mappings" />
192 </replace>
193 </target>
194
195 <!-- ===================================================================== -->
196 <!-- Steps to do after running the build.xmls for the elements being built. -->
197 <!-- ===================================================================== -->
198 <target name="postProcess">
199 <condition property="logsAvailable">
200 <istrue value="${javacVerbose}" />
201 </condition>
202 <antcall target="gatherLogs" />
david_williams0b74c592007-04-09 06:11:35 +0000203
david_williamsae0e4cb2006-11-11 02:55:51 +0000204 </target>
205
206
207 <!-- ===================================================================== -->
208 <!-- Steps to do before running assemble. -->
209 <!-- ===================================================================== -->
210 <target name="preAssemble"></target>
211
212 <!-- ===================================================================== -->
213 <!-- Steps to do after running assemble. -->
214 <!-- ===================================================================== -->
david_williamsd913e922006-11-13 07:24:21 +0000215 <target name="postAssemble"></target>
david_williamsae0e4cb2006-11-11 02:55:51 +0000216
217 <!-- ===================================================================== -->
218 <!-- Steps to do after the build is done. -->
219 <!-- ===================================================================== -->
220 <target name="postBuild"></target>
221
222 <!-- ===================================================================== -->
david_williamsd913e922006-11-13 07:24:21 +0000223 <!-- Steps to test the build results -->
david_williamsae0e4cb2006-11-11 02:55:51 +0000224 <!-- ===================================================================== -->
225 <target name="test"></target>
226
227 <!-- ===================================================================== -->
228 <!-- Steps to do to publish the build results -->
229 <!-- ===================================================================== -->
230 <target name="publish"></target>
231
232 <!-- ===================================================================== -->
233 <!-- Helper targets -->
234 <!-- ===================================================================== -->
235 <target
236 name="gatherLogs"
237 if="logsAvailable">
238 <mkdir dir="${buildDirectory}/${buildLabel}/compilelogs" />
david_williams0b74c592007-04-09 06:11:35 +0000239 <echo message="logExtension: ${logExtension}" />
david_williamsae0e4cb2006-11-11 02:55:51 +0000240 <antcall target="allElements">
241 <param
242 name="target"
243 value="gatherLogs" />
david_williams0b74c592007-04-09 06:11:35 +0000244 <param
245 name="logExtension"
246 value="${logExtension}" />
david_williamsae0e4cb2006-11-11 02:55:51 +0000247 </antcall>
david_williamsae0e4cb2006-11-11 02:55:51 +0000248 <unzip
249 dest="${buildDirectory}/${buildLabel}/compilelogs"
250 overwrite="true">
david_williamseb49d082007-05-01 03:03:15 +0000251 <fileset dir="${buildDirectory}/features/org.eclipse.jpt.sdk">
david_williamsae0e4cb2006-11-11 02:55:51 +0000252 <include name="**/*.log.zip" />
253 </fileset>
254 </unzip>
255 </target>
256
257 <target
258 name="clean"
259 unless="noclean">
260 <antcall target="allElements">
261 <param
262 name="target"
263 value="cleanElement" />
264 </antcall>
265 </target>
266
267 <!-- ===================================================================== -->
268 <!-- Default target -->
269 <!-- ===================================================================== -->
270 <target name="noDefault">
271 <echo message="You must specify a target when invoking this file" />
272 </target>
273
274</project>