source: main/trunk/release-kits/kits/derk/ant-scripts/build.xml@ 21649

Last change on this file since 21649 was 21649, checked in by oranfry, 11 years ago

change all uses of svnant to execs of system svn

File size: 2.9 KB
Line 
1<?xml version="1.0" encoding="utf-8" ?>
2<!--
3 ..........................................................
4 April 2009
5 Documented Example Release Kit (derk)
6 Oran Fry
7 ..........................................................
8-->
9
10<project name="derk-build" default="derk">
11
12 <!-- CONSTANTS -->
13
14 <!-- for the benefit of the shared scripts, set release-kit home -->
15 <property name="rk.name" value="derk"/>
16 <property name="rk.home" value="${derk.home}" />
17 <property name="rk.os" value="multi" />
18 <property name="os.suffix" value="AnyPlatform"/>
19
20 <!-- IMPORT OTHER ANT SCRIPTS -->
21 <import file="${rk.home}/shared/core/ant-scripts/shared.xml"/>
22
23 <!-- THE MAIN TARGET -->
24 <target name="derk" depends="init">
25 <antcall target="export-dec"/>
26 <antcall target="tweak-files"/>
27 <antcall target="prepare-gs2build"/>
28 <antcall target="build-collections"/>
29 <antcall target="create-archives"/>
30 </target>
31
32 <target name="properties">
33 <echo>Required Properties:</echo>
34 <echo>version the version string for the release</echo>
35 <echo/>
36
37 <echo>Optional Properties:</echo>
38 <echo>branch.path the branch of gs2build to use to build collections. Default: trunk.</echo>
39 <echo/>
40 </target>
41
42 <target name="export-dec">
43 <if><bool><not><available file="dec"/></not></bool>
44 <exec executable="svn">
45 <arg value="export"/>
46 <arg value="${svn.root}/documented-examples/${branch.path}"/>
47 <arg value="documented-examples"/>
48 </exec>
49 </if>
50 </target>
51
52 <target name="tweak-files">
53 <delete file="documented-examples/text-for-translation.txt"/>
54 </target>
55
56 <target name="prepare-gs2build">
57 <if>
58 <bool><not><available file="gs2build"/></not></bool>
59 <exec executable="svn">
60 <arg value="export"/>
61 <arg value="${svn.root}/main/${branch.path}/gs2build"/>
62 <arg value="gs2build"/>
63 </exec>
64 </if>
65
66 <if>
67 <bool><not><available file="gs2build/Makefile"/></not></bool>
68 <exec dir="gs2build" executable="/bin/bash" failonerror="true"><arg value="./configure"/></exec>
69 <exec dir="gs2build/common-src" executable="make" failonerror="true"/>
70 <exec dir="gs2build/common-src" executable="make" failonerror="true"><arg value="install"/></exec>
71 <exec dir="gs2build" executable="/bin/bash" failonerror="true"><arg value="./configure"/></exec>
72 <exec dir="gs2build" executable="make" failonerror="true"/>
73 <exec dir="gs2build" executable="make" failonerror="true"><arg value="install"/></exec>
74 </if>
75 </target>
76
77 <target name="build-collections">
78 <exec dir="gs2build" executable="${derk.home}/resources/build.sh" failonerror="true"/>
79 </target>
80
81 <target name="create-archives">
82 <mkdir dir="products"/>
83 <zip destfile="products/Greenstone-documented-examples-${version}.zip" basedir="." includes="documented-examples/**/*"/>
84 <exec executable="tar">
85 <arg line="-czf products/Greenstone-documented-examples-${version}.tar.gz documented-examples"/>
86 </exec>
87 </target>
88
89</project>
Note: See TracBrowser for help on using the repository browser.