source: main/trunk/release-kits/kits/clientrk/ant-scripts/compile.xml@ 34256

Last change on this file since 34256 was 34256, checked in by ak19, 4 years ago

Tried to add the infrastructure for standalone client-gli (client-fli) to release kit, but there's no way of testing it from home as many properties are simply not set with a plain release-kit checkout and libraries for using things like <if> are also unavailable despite importing shared.xml

File size: 2.0 KB
Line 
1<?xml version="1.0" encoding="utf-8" ?>
2<project name="clientrk-compile">
3
4 <property name="gli" value="standalone-client-gli"/>
5
6 <!-- TODO: 3 artificial vars -->
7 <!--
8 <property name="branch.path" value="trunk"/>
9 <property name="branch.revision" value="HEAD"/>
10 <property name="svn.root" value="http://svn.greenstone.org"/>
11 -->
12
13 <target name="compile">
14
15 <!-- checkout GLI source code -->
16 <exec executable="svn">
17 <arg value="checkout"/>
18 <arg value="${svn.root}/main/${branch.path}/gli"/>
19 <arg value="${gli}"/>
20 <arg value="-r"/><arg value="${branch.revision}"/>
21 </exec>
22
23 <!-- run makegli and makejar -->
24 <if>
25 <bool><equals arg1="${rk.os}" arg2="windows"/></bool>
26
27 <exec executable="cmd">
28 <arg value="/c"/>
29 <arg value="makegli.bat"/>
30 </exec>
31 <exec executable="cmd">
32 <arg value="/c"/>
33 <arg value="makejar.bat"/>
34 </exec>
35
36 <else>
37 <exec executable="/bin/bash" dir="${gli}">
38 <arg value="-c"/>
39 <arg value="makegli.sh"/>
40 </exec>
41 <exec executable="/bin/bash" dir="${gli}">
42 <arg value="-c"/>
43 <arg value="makejar.sh"/>
44 </exec>
45 </else>
46 </if>
47
48 <!-- Now that GLI.jar but also GLIServer.jar are generated,
49 can delete the src, classes and jar folders.
50 If classes didn't exist, compile failed.
51 If jar folder didn't exist, makejar failed.
52 TODO: Or is it best to test for the existence of the two .jar files?
53 -->
54 <delete dir="${gli}/src" quiet="true" />
55 <delete dir="${gli}/classes" failonerror="true" />
56 <delete dir="${gli}/jar" failonerror="true" />
57
58 <!-- strip out .svn dirs -->
59 <antcall target="strip-svn-dirs"><param name="dir" value="${gli}"/></antcall>
60
61 <!-- create a tarball of the standalone client-gli folder -->
62 <exec executable="tar" dir="${gli}">
63 <arg value="xvzf"/>
64 <arg value="${gli}.tar.gz"/>
65 </exec>
66
67 <!-- delete everything but the tarball -->
68 <delete dir="${gli}"/>
69
70 </target>
71</project>
Note: See TracBrowser for help on using the repository browser.