root/main/trunk/release-kits/kits/rk2/ant-scripts/compile.xml @ 23032

Revision 23032, 21.6 KB (checked in by sjm84, 10 years ago)

Modified the release kit to use the zipped up versions of the gnome-lib extension rather than compiling it from scratch

Line 
1<?xml version="1.0" encoding="utf-8" ?>
2<project name="rk2-compile">
3
4    <target name="compile" depends="init,gs2-init">
5    <!-- checkout greenstone2 (or gsdl if a pre-2.84 release is being created) and gli -->
6        <if>
7            <bool>
8                <or>
9                    <equals arg1="${branch.path}" arg2="trunk"/>
10                    <equals arg1="${branch.path}" arg2="tags/stable"/>
11                    <isgreaterthan arg1="${branch.tag.version}" arg2="2.83"/>
12                </or>
13            </bool>
14            <exec executable="svn">
15                <arg value="checkout"/>
16                <arg value="${svn.root}/main/${branch.path}/greenstone2"/>
17                <arg value="${basedir}/compiled"/>
18            </exec>       
19            <else>
20                <exec executable="svn">
21                    <arg value="checkout"/>
22                    <arg value="${svn.root}/main/${branch.path}/gsdl"/>
23                    <arg value="${basedir}/compiled"/>
24                </exec>
25            </else>
26        </if>
27       
28        <exec executable="svn">
29            <arg value="checkout"/>
30            <arg value="${svn.root}/main/${branch.path}/gli"/>
31            <arg value="${basedir}/compiled/gli"/>
32        </exec>
33
34        <!-- drop in documentation -->
35        <copy todir="compiled" overwrite="true">
36            <fileset dir="${rk.home}/shared/greenstone2/docs" excludes="READMEar.txt,READMEes.txt,READMEfr.txt,READMEru.txt"/>
37        </copy>
38
39        <!-- set version numbers -->
40        <antcall target="gsdl-set-version-numbers"><param name="gsdl.basedir" value="${basedir}/compiled"/></antcall>
41        <antcall target="gli-set-version-numbers"><param name="glibasedir" value="${basedir}/compiled/gli"/></antcall>
42
43        <!-- we do not want the *.app folders if we are not mac-->
44        <if><bool><not><equals arg1="${rk.os}" arg2="mac"/></not></bool>
45            <delete dir="${basedir}/compiled/client-gli.app"/>
46            <delete dir="${basedir}/compiled/gems.app"/>
47            <delete dir="${basedir}/compiled/gs2-server.app"/>
48            <delete dir="${basedir}/compiled/gli.app"/>
49        </if>
50
51        <!-- mac or linux: compile the support library -->
52        <if><bool><or><equals arg1="${rk.os}" arg2="mac"/><equals arg1="${rk.os}" arg2="linux"/></or></bool>
53            <!-- checkout the gnome support library extension-->
54            <if><bool><or>
55                <equals arg1="${branch.path}" arg2="trunk"/>
56                <equals arg1="${branch.path}" arg2="tags/stable"/>
57                <isgreaterthan arg1="${branch.tag.version}" arg2="2.83"/>
58            </or></bool>
59                <echo>EXPORTING GNOME LIB EXTENSION</echo>
60                <exec executable="svn">
61                    <arg value="export"/>
62                    <arg value="${svn.root}/gs2-extensions/gnome-lib/trunk/gnome-lib-${os.shell}.tar.gz"/>
63                    <arg value="${basedir}/compiled/ext/gnome-lib-${os.shell}.tar.gz"/>
64                </exec>
65
66                <exec executable="/bin/tar" dir="${basedir}/compiled/ext">
67                    <arg value="xvzf"/>
68                    <arg value="gnome-lib-${os.shell}.tar.gz"/>
69                </exec>
70                <echo>DONE EXTRACTING GNOME LIB EXTENSION</echo>
71            </if>
72        </if>
73       
74        <!-- windows only -->
75        <if><bool><equals arg1="${rk.os}" arg2="windows"/></bool>
76
77            <!-- unzip packages -->
78            <unzip src="${basedir}/compiled/common-src/packages/windows/crypt/crypt.zip" dest="${basedir}/compiled/common-src/packages/windows/crypt"/>
79           
80            <!-- unzip expat if the version is less that 2.84 -->
81            <if><bool><and>
82                <not><equals arg1="${branch.path}" arg2="trunk"/></not>
83                <not><equals arg1="${branch.path}" arg2="tags/stable"/></not>
84                <islessthan arg1="${branch.tag.version}" arg2="2.84"/>
85            </and></bool>
86                <unzip src="${basedir}/compiled/common-src/packages/windows/expat/expat.zip" dest="${basedir}/compiled/common-src/packages/windows/expat"/>
87            </if>
88           
89            <unzip src="${basedir}/compiled/common-src/packages/windows/stlport/stlport.zip" dest="${basedir}/compiled/common-src/packages/windows/stlport"/>
90            <unzip src="${basedir}/compiled/common-src/indexers/packages/windows/iconv/iconv.zip" dest="${basedir}/compiled/common-src/indexers/packages/windows/iconv"/>
91            <untar src="${basedir}/compiled/common-src/packages/sqlite/sqlite-amalgamation-3.5.9.tar.gz" dest="${basedir}/compiled/common-src/packages/sqlite" compression="gzip"/>
92
93            <!-- get winbin from tags if the version is greater than 2.83 otherwise get it from trunk -->
94            <if><bool><not><available file="${basedir}/compiled/bin/windows"/></not></bool>
95                <if><bool><and>
96                    <not><equals arg1="${branch.path}" arg2="trunk"/></not>
97                    <not><equals arg1="${branch.path}" arg2="tags/stable"/></not>
98                    <isgreaterthan arg1="${branch.tag.version}" arg2="2.83"/>
99                </and></bool>
100                   
101                    <exec executable="svn">
102                        <arg value="export"/>
103                        <arg value="${svn.root}/main/${branch.path}/binaries/windows/bin"/>
104                        <arg value="${basedir}/compiled/bin/windows"/>
105                        <arg value="-r"/>
106                        <arg value="${branch.revision}"/>
107                    </exec>
108                   
109                    <else>
110                        <exec executable="svn">
111                            <arg value="export"/>
112                            <arg value="${svn.root}/main/trunk/binaries/windows/bin"/>
113                            <arg value="${basedir}/compiled/bin/windows"/>
114                            <arg value="-r"/>
115                            <arg value="${branch.revision}"/>
116                        </exec>
117                    </else>
118                </if>
119            </if>
120
121            <!-- insert windows perl -->
122            <unzip src="${rk.home}/shared/windows/perl.zip" dest="compiled/bin/windows"/>
123           
124            <exec executable="${basedir}/compiled/bin/windows/gunzip.exe" dir="${basedir}/compiled/runtime-src/packages/apache-httpd">
125                <arg value="-d"/>
126                <arg value="httpd-2.2.11-gs.tar.gz"/>
127            </exec>
128               
129            <exec executable="${basedir}/compiled/bin/windows/tar.exe" dir="${basedir}/compiled/runtime-src/packages/apache-httpd">
130                <arg value="-xvf"/>
131                <arg value="httpd-2.2.11-gs.tar"/>
132            </exec>
133           
134            <!-- Insert a unique number after every occurrence of the word tempfile to prevent some strange race conditions present on Windows 7 (iuv = InsertUniqueValue) -->
135            <iuv>
136                <fileset dir="${basedir}/compiled/runtime-src/packages/apache-httpd/httpd-2.2.11" includes="**/*.mak"/>
137                <job pattern="tempfile"/>
138            </iuv>
139           
140            <!-- compile c code -->
141            <exec dir="${basedir}/compiled" executable="nmake"><arg value="/f"/><arg value="win32.mak"/><arg value="clean"/></exec>
142            <exec dir="${basedir}/compiled" executable="nmake"><arg value="/f"/><arg value="win32.mak"/><arg value="APACHE_HTTPD=1"/></exec>
143            <exec dir="${basedir}/compiled" executable="nmake"><arg value="/f"/><arg value="win32.mak"/><arg value="LOCAL_LIBRARY=1"/></exec>
144            <delete><fileset dir="${basedir}/compiled/apache-httpd" includes="**/*.pdb"/></delete>
145
146            <copy file="${rk.home}/shared/windows/msvcr100.dll" tofile="${basedir}/compiled/apache-httpd/windows/lib/msvcr100.dll"/>
147            <copy file="${rk.home}/shared/windows/MSVCR71.DLL" tofile="${basedir}/compiled/apache-httpd/windows/lib/MSVCR71.DLL"/>
148           
149            <mkdir dir="products"/>
150            <copy file="${basedir}/compiled/server.exe" tofile="${basedir}/products/server-${version}.exe"/>
151            <move file="${basedir}/compiled/server.exe" todir="${basedir}/compiled/bin/windows"/>
152
153
154        <!-- linux only -->
155        <else><if><bool><equals arg1="${rk.os}" arg2="linux"/></bool>
156            <!-- add static to configure.in -->
157            <rsr file="${basedir}/compiled/configure.in" pattern="^LDFLAGS=.*$" replacement="LDFLAGS=-static"/>
158            <exec dir="${basedir}/compiled" executable="autoconf" output="${basedir}/compiled/configure">
159                <arg value="configure.in"/>
160            </exec>
161
162            <!-- set environment in packages/configure -->
163            <rsr file="${basedir}/compiled/common-src/packages/configure" pattern="^ENVIRONMENT=.*$" replacement="ENVIRONMENT=&quot;LDFLAGS=-static&quot;"/>
164            <rsr file="${basedir}/compiled/build-src/packages/configure" pattern="^ENVIRONMENT=.*$" replacement="ENVIRONMENT=&quot;LDFLAGS=-static&quot;"/>
165
166            <!-- run configure -->
167            <exec dir="${basedir}/compiled" executable="${basedir}/compiled/configure" failonerror="true">
168                <arg line="--enable-apache-httpd"/>
169                <arg line="PATH=&quot;${basedir}/compiled/ext/gnome-lib/linux/bin:${env.PATH}&quot;"/>
170                <arg line="CFLAGS=&quot;-I${basedir}/compiled/ext/gnome-lib/linux/include&quot;"/>
171                <arg line="CPPFLAGS=&quot;-I${basedir}/compiled/ext/gnome-lib/linux/include&quot;"/>
172                <arg line="CXXFLAGS=&quot;-I${basedir}/compiled/ext/gnome-lib/linux/include&quot;"/>
173                <arg line="LDFLAGS=&quot;-static -L${basedir}/compiled/ext/gnome-lib/linux/lib&quot;"/>
174            </exec>
175
176            <!-- add -static to makefiles -->
177            <rsr file="${basedir}/compiled/build-src/packages/xlhtml/xlhtml-0.4.9.0/xlhtml/Makefile" pattern="^LDFLAGS =.*$" replacement="LDFLAGS = -static"/>
178            <rsr file="${basedir}/compiled/build-src/packages/xlhtml/xlhtml-0.4.9.0/ppthtml/Makefile" pattern="^LDFLAGS =.*$" replacement="LDFLAGS = -static"/>
179            <rsr file="${basedir}/compiled/build-src/packages/rtftohtml/rtftohtml_src/Makefile" pattern="(-o rtftohtml.{2}EXEEXT.{1})" replacement="$1 -static"/>
180
181        <!-- mac only -->
182        <else><if><bool><equals arg1="${rk.os}" arg2="mac"/></bool>
183            <!-- run configure -->
184            <exec dir="${basedir}/compiled" executable="${basedir}/compiled/configure" failonerror="true">
185                <arg line="--enable-apache-httpd"/>
186                <arg line="PATH=&quot;${basedir}/compiled/ext/gnome-lib/darwin/bin:${env.PATH}&quot;"/>
187                <arg line="CFLAGS=&quot;-I${basedir}/compiled/ext/gnome-lib/darwin/include&quot;"/>
188                <arg line="CPPFLAGS=&quot;-I${basedir}/compiled/ext/gnome-lib/darwin/include&quot;"/>
189                <arg line="CXXFLAGS=&quot;-I${basedir}/compiled/ext/gnome-lib/darwin/include&quot;"/>
190                <arg line="LDFLAGS=&quot;-L${basedir}/compiled/ext/gnome-lib/darwin/lib&quot;"/>
191            </exec>
192
193            <!-- tweak makefiles -->
194            <rsr file="${basedir}/compiled/runtime-src/src/recpt/Makefile" pattern="^(LIBS =.*)-L(.)\(PACKAGES_DIR\)/expat/lib -lexpat(.*)$" replacement="$1$2(PACKAGES_DIR)/expat/lib/libexpat.a$3"/>
195            <rsr file="${basedir}/compiled/runtime-src/src/oaiservr/Makefile" pattern="^(LIBS =.*)-L(.)\(PACKAGES_DIR\)/expat/lib -lexpat(.*)$" replacement="$1$2(PACKAGES_DIR)/expat/lib/libexpat.a$3"/>
196
197        </if></else></if></else></if>
198
199        <!-- mac and linux: compile -->
200        <if><bool><or><equals arg1="${rk.os}" arg2="mac"/><equals arg1="${rk.os}" arg2="linux"/></or></bool>
201            <!-- make -->
202            <exec dir="${basedir}/compiled" executable="make" failonerror="true"/>
203
204            <!-- make install -->
205            <exec dir="${basedir}/compiled" executable="make" failonerror="true"><arg value="install"/></exec>
206
207            <!-- make apache-for-dist -->
208            <exec dir="${basedir}/compiled" executable="make" failonerror="true"><arg value="apache-for-dist"/></exec>
209
210            <!-- strip executables -->
211            <exec dir="${basedir}/compiled/bin/${os.shell}" executable="find" failonerror="true">
212                <arg line=". ! -name . -type f -maxdepth 1 -exec strip {} &#59;"/>
213            </exec>
214        </if>
215
216        <!-- Delete the entire gnome support library on Linux -->
217        <if><bool><equals arg1="${rk.os}" arg2="linux"/></bool>
218            <delete dir="${basedir}/compiled/ext/gnome-lib"/>
219            <delete dir="${basedir}/compiled/ext/gnome-lib-linux.tar.gz"/>
220        </if>
221
222        <!-- Delete all but the lib folder and the setup.bash script of the gnome support library on Mac -->
223        <if><bool><equals arg1="${rk.os}" arg2="mac"/></bool>
224            <delete dir="${basedir}/compiled/ext/gnome-lib/cascade-make"/>
225            <delete dir="${basedir}/compiled/ext/gnome-lib/packages"/>
226            <delete dir="${basedir}/compiled/ext/gnome-lib/darwin/bin"/>
227            <delete dir="${basedir}/compiled/ext/gnome-lib/darwin/etc"/>
228            <delete dir="${basedir}/compiled/ext/gnome-lib/darwin/include"/>
229            <delete dir="${basedir}/compiled/ext/gnome-lib/darwin/share"/>
230            <delete file="${basedir}/compiled/ext/gnome-lib/setup.bat"/>
231            <delete file="${basedir}/compiled/ext/gnome-lib/CASCADE-MAKE.sh"/>
232            <delete file="${basedir}/compiled/ext/gnome-lib-darwin.tar.gz"/>
233        </if>
234       
235        <!-- insert the necessary additional xml parser versions-->
236        <if><bool><equals arg1="${rk.os}" arg2="linux"/></bool>
237            <!-- Add the 5.6 version if necessary -->
238            <if><bool><not><available file="${basedir}/compiled/perllib/cpan/perl-5.6"/></not></bool>
239                <copy todir="${basedir}/compiled/perllib/cpan">
240                    <fileset dir="${rk.home}/shared/linux/XML-Parser" includes="perl-5.6,perl-5.6/**/*"/>
241                </copy>
242            </if>
243           
244            <!-- Add the 5.8 version if necessary -->
245            <if><bool><not><available file="${basedir}/compiled/perllib/cpan/perl-5.8"/></not></bool>
246                <copy todir="${basedir}/compiled/perllib/cpan">
247                    <fileset dir="${rk.home}/shared/linux/XML-Parser" includes="perl-5.8,perl-5.8/**/*"/>
248                </copy>
249            </if>
250           
251            <!-- Add the 5.10 version if necessary -->
252            <if><bool><not><available file="${basedir}/compiled/perllib/cpan/perl-5.10"/></not></bool>
253                <copy todir="${basedir}/compiled/perllib/cpan">
254                    <fileset dir="${rk.home}/shared/linux/XML-Parser" includes="perl-5.10,perl-5.10/**/*"/>
255                </copy>
256            </if>
257        </if>
258
259        <!-- compile gli -->
260        <!-- (linux and mac) -->
261        <if><bool><or><equals arg1="${rk.os}" arg2="mac"/><equals arg1="${rk.os}" arg2="linux"/></or></bool>
262            <exec dir="compiled/gli" executable="/bin/bash"><arg value="-c"/><arg value="./makegli.sh"/></exec>
263            <exec dir="compiled/gli" executable="/bin/bash"><arg value="-c"/><arg value="./makejar.sh"/></exec>
264        <!-- windows -->
265        <else><if><bool><equals arg1="${rk.os}" arg2="windows"/></bool>
266            <exec dir="compiled/gli" executable="cmd.exe"><arg value="/c"/><arg value="makegli.bat"/></exec>
267            <exec dir="compiled/gli" executable="cmd.exe"><arg value="/c"/><arg value="makejar.bat"/></exec>
268        </if></else></if>
269
270        <delete dir="compiled/gli/jar"/>
271        <delete dir="compiled/gli/classes/org"/>
272        <move file="compiled/gli/GLIServer.jar" todir="compiled/bin/java"/>
273
274        <!-- compile uninstaller -->
275        <antcall target="insert-and-compile-uninstaller" />
276
277        <!-- build demo collection -->
278        <!-- the envs on these execs simulate the environment when you run setup.bat -->
279        <if>
280            <bool>
281                <equals arg1="${rk.os}" arg2="windows"/>
282            </bool>
283           
284            <exec dir="${basedir}/compiled" executable="${basedir}/compiled/bin/windows/perl/bin/perl">
285                <arg line="-S"/>
286                <arg line="bin/script/import.pl demo"/>
287                <env key="GSDLHOME" path="${basedir}/compiled"/>
288                <env key="GSDLCOLLECTDIR" path="${basedir}/compiled/collect"/>
289                <env key="GSDLOS" value="windows"/>
290                <env key="PATH" path="${basedir}/compiled/bin/windows/perl/bin:${basedir}/compiled/bin/windows:${basedir}/compiled/bin/script:${env.PATH}"/>
291            </exec>
292            <exec dir="${basedir}/compiled" executable="${basedir}/compiled/bin/windows/perl/bin/perl">
293                <arg line="-S"/>
294                <arg line="bin/script/buildcol.pl demo"/>
295                <env key="GSDLHOME" path="${basedir}/compiled"/>
296                <env key="GSDLCOLLECTDIR" path="${basedir}/compiled/collect"/>
297                <env key="GSDLOS" value="windows"/>
298                <env key="PATH" path="${basedir}/compiled/bin/windows/perl/bin:${basedir}/compiled/bin/windows:${basedir}/compiled/bin/script:${env.PATH}"/>
299            </exec>
300           
301            <else>
302                <exec dir="${basedir}/compiled" executable="perl">
303                    <arg line="-S"/>
304                    <arg line="bin/script/import.pl demo"/>
305                    <env key="GSDLHOME" path="${basedir}/compiled"/>
306                    <env key="GSDLCOLLECTDIR" path="${basedir}/compiled/collect"/>
307                    <env key="GSDLOS" value="linux"/>
308                    <env key="PATH" path="${basedir}/compiled/bin/linux:${basedir}/compiled/bin/script:${env.PATH}"/>
309                </exec>
310                <exec dir="${basedir}/compiled" executable="perl">
311                    <arg line="-S"/>
312                    <arg line="bin/script/buildcol.pl demo"/>
313                    <env key="GSDLHOME" path="${basedir}/compiled"/>
314                    <env key="GSDLCOLLECTDIR" path="${basedir}/compiled/collect"/>
315                    <env key="GSDLOS" value="linux"/>
316                    <env key="PATH" path="${basedir}/compiled/bin/linux:${basedir}/compiled/bin/script:${env.PATH}"/>
317                </exec>
318            </else>
319        </if>
320        <delete dir="${basedir}/compiled/collect/demo/index"/>
321        <move file="${basedir}/compiled/collect/demo/building" tofile="${basedir}/compiled/collect/demo/index"/>
322
323        <!-- delete the source code -->
324        <delete><fileset dir="compiled" includes="Makefile,config.cache,config.h,config.log,stamp-h,config.status"/></delete>
325        <delete dir="compiled/common-src"/>
326        <delete dir="compiled/build-src"/>
327        <delete dir="compiled/runtime-src"/>
328        <delete><fileset dir="compiled" includes="Install.txt,acconfig.h,aclocal.m4,config.guess,config.sub,configtest.pl,configure,configure.in,install-sh,Makefile.in,micotest.cpp,config.h.in,win32.mak,win32cfg.h"/></delete>
329
330        <!-- strip .svn working-copy dirs -->
331        <antcall target="strip-svn-dirs"><param name="dir" value="compiled"/></antcall>
332
333        <!-- create needed empty files -->
334        <mkdir dir="compiled/tmp"/>
335        <chmod dir="compiled/tmp" perm="a+rwx"/>
336        <echo file="compiled/etc/usage.txt"></echo>
337
338        <!-- windows -->
339        <if><bool><equals arg1="${rk.os}" arg2="windows"/></bool>
340
341            <!-- make a copy of server.exe in the root -->
342            <copy file="compiled/bin/windows/server.exe" tofile="compiled/server.exe"/>
343
344            <!-- delete sourcecode -->
345            <delete dir="${binzip.dir}/common-src"/>
346            <delete dir="${binzip.dir}/build-src"/>
347            <delete dir="${binzip.dir}/runtime-src"/>
348           
349            <!-- create simple zipped binary distribution
350            <mkdir dir="distributions"/>
351            <property name="binzip.dir" value="distributions/Greenstone-${version}-${os.suffix}-binary"/>
352            <copy todir="${binzip.dir}"><fileset dir="compiled"/></copy>
353            <delete><fileset dir="${binzip.dir}" includes="README*.txt,Uninstall.bat,Uninst.bat,uninst.jar,win32.mak,win32cfg.h,makegs2.bat" excludes="READMEen.txt"/></delete>
354            -->
355
356            <!-- delete unneeded files -->
357            <delete dir="compiled/bin/linux" />
358            <delete><fileset dir="compiled" includes="*.bash,*.sh,*.csh,.gstermrc"/></delete>
359            <delete><fileset dir="compiled/gli" includes="*.sh,*4gs3.bat"/></delete>
360            <delete dir="compiled/autom4te.cache" />
361
362        <!-- linux -->
363        <else><if><bool><equals arg1="${rk.os}" arg2="linux"/></bool>
364
365            <!-- grab imagemagick and wv binaries -->
366            <delete dir="compiled/bin/linux/imagemagick"/>
367
368            <if><bool><or>
369                <equals arg1="${branch.path}" arg2="trunk"/>
370                <equals arg1="${branch.path}" arg2="tags/stable"/>
371                <isgreaterthan arg1="${branch.tag.version}" arg2="2.83"/>
372            </or></bool>
373                <exec executable="svn">
374                    <arg value="export"/>
375                    <arg value="${svn.root}/main/${branch.path}/binaries/linux/imagemagick"/>
376                    <arg value="compiled/bin/linux/imagemagick"/>
377                </exec>
378
379                <else>
380                    <delete dir="compiled/bin/linux/wv"/>   
381                    <exec executable="svn">
382                        <arg value="export"/>
383                        <arg value="${svn.root}/main/trunk/binaries/linux/imagemagick"/>
384                        <arg value="compiled/bin/linux/imagemagick"/>
385                    </exec>
386
387                    <exec executable="svn">
388                        <arg value="export"/>
389                        <arg value="${svn.root}/main/trunk/binaries/linux/wv"/>
390                        <arg value="compiled/bin/linux/wv"/>
391                    </exec>
392                </else>
393            </if>
394
395            <!-- delete unneeded files -->
396            <delete><fileset dir="compiled" includes="win32.mak,win32cfg.h,Install.sh,Support.htm,micotest.cpp"/></delete>
397            <delete><fileset dir="compiled/gli" includes="*.bat"/></delete>
398            <delete><fileset dir="compiled" includes="*.bat"/></delete>
399            <delete dir="compiled/common-src/packages/windows"/>
400            <delete dir="compiled/common-src/indexers/packages/windows"/>
401
402        <!-- mac -->
403        <else><if><bool><equals arg1="${rk.os}" arg2="mac"/></bool>
404            <!-- grab imagemagick and ghostscript binaries -->
405            <delete dir="compiled/bin/darwin/imagemagick"/>
406            <delete dir="compiled/bin/darwin/ghostscript"/>
407
408            <if><bool><and>
409                <not><equals arg1="${branch.path}" arg2="trunk"/></not>
410                <not><equals arg1="${branch.path}" arg2="tags/stable"/></not>
411                <isgreaterthan arg1="${branch.tag.version}" arg2="2.83"/>
412            </and></bool>
413
414                <exec executable="svn">
415                    <arg value="export"/>
416                    <arg value="${svn.root}/main/${branch.path}/binaries/mac/intel/imagemagick"/>
417                    <arg value="compiled/bin/darwin/imagemagick"/>
418                </exec>
419             
420                <exec executable="svn">
421                    <arg value="export"/>
422                    <arg value="${svn.root}/main/${branch.path}/binaries/mac/intel/ghostscript"/>
423                    <arg value="compiled/bin/darwin/ghostscript"/>
424                </exec>
425
426                <else>             
427                    <exec executable="svn">
428                        <arg value="export"/>
429                        <arg value="${svn.root}/main/trunk/binaries/mac/intel/imagemagick"/>
430                        <arg value="compiled/bin/darwin/imagemagick"/>
431                    </exec>
432               
433                    <exec executable="svn">
434                        <arg value="export"/>
435                        <arg value="${svn.root}/main/trunk/binaries/mac/intel/ghostscript"/>
436                        <arg value="compiled/bin/darwin/ghostscript"/>
437                    </exec>
438                </else>
439            </if>
440
441            <!-- delete unneeded files -->
442            <delete><fileset dir="compiled" includes="win32.mak,win32cfg.h,Install.sh,Support.htm,*.bat"/></delete>
443            <delete><fileset dir="compiled/gli" includes="*.bat"/></delete>
444            <delete dir="compiled/common-src/packages/windows"/>
445
446        </if></else></if></else></if>
447
448        <!-- delete unneeded files -->
449        <delete dir="compiled/uninstaller" />
450        <delete file="compiled/bin/java/SignedGatherer.jar" />
451
452        <!-- tidy up gli -->
453        <antcall target="gli-tidy-for-dist"><param name="glibasedir" value="compiled/gli"/></antcall>
454
455        <!-- mac and linux: insert export to cdrom package -->
456        <if><bool><or><equals arg1="${rk.os}" arg2="mac"/><equals arg1="${rk.os}" arg2="linux"/></or></bool>
457            <mkdir dir="compiled/bin/windows"/>
458            <get src="${server.exe.location}" dest="compiled/bin/windows/server.exe"/>
459
460            <if><bool><and>
461                <not><equals arg1="${branch.path}" arg2="trunk"/></not>
462                <not><equals arg1="${branch.path}" arg2="tags/stable"/></not>
463                <isgreaterthan arg1="${branch.tag.version}" arg2="2.83"/>
464            </and></bool>
465                <get src="${svn.root}/main/${branch.path}/binaries/windows/bin/Setup.exe" dest="compiled/bin/windows/Setup.exe"/>
466                <get src="${svn.root}/main/${branch.path}/binaries/windows/bin/gssetup.exe" dest="compiled/bin/windows/gssetup.exe"/>
467
468                <else>
469                    <get src="${svn.root}/main/trunk/binaries/windows/bin/Setup.exe" dest="compiled/bin/windows/Setup.exe"/>
470                    <get src="${svn.root}/main/trunk/binaries/windows/bin/gssetup.exe" dest="compiled/bin/windows/gssetup.exe"/>
471                </else>
472            </if>
473        </if>
474
475    </target>
476
477</project>
Note: See TracBrowser for help on using the browser.