source: main/trunk/release-kits/shared/greenstone3/ant-scripts/greenstone3-shared.xml@ 21658

Last change on this file since 21658 was 21658, checked in by oranfry, 12 years ago

fixes

File size: 2.9 KB
Line 
1<?xml version="1.0" encoding="utf-8" ?>
2<!--
3 ..........................................................
4 August 2008
5 Targets for Greenstone3 release kits
6 Oran Fry
7 ..........................................................
8-->
9
10<project name="greenstone3-targets">
11
12 <property name="version.major" value="3"/>
13 <target name="gs3-init">
14
15 <!-- don't let greenstone3 block and wait for user input to accept
16 the properties for the build -->
17 <property name="forward.properties.accepted" value="true"/>
18
19 <!-- make sure all c++ compilation is done statically on linux -->
20 <if><bool><equals arg1="${rk.os}" arg2="linux"/></bool>
21 <property name="forward.compile.static" value="true"/>
22 </if>
23
24 <!-- show the property set to be forwarded to greenstone3 -->
25 <echo>Properties to be forwarded to greenstone3 build</echo>
26 <echoproperties><propertyset refid="forward.properties"/></echoproperties>
27
28 </target>
29
30 <target name="gs3-properties">
31 <echo>forward.* (eg, forward.proxy.host) (optional) any property to forward to greenstone3 during build</echo>
32 </target>
33
34 <target name="greenstone3-set-version-numbers">
35 <rsr
36 file="${greenstone3basedir}/resources/java/global.properties.in"
37 pattern="@gsdl3version@"
38 replacement="${version}" />
39 <rsr
40 file="${greenstone3basedir}/resources/java/server.properties"
41 pattern="^(Server3Control\.Version=).*$"
42 replacement="$1${version}" />
43
44 </target>
45
46 <!--
47 unused. might need to find a way to get the system ant into the release, as ant no longer comes with the release kits
48 -->
49 <target name="insert-ant">
50
51 <!-- remove any existing ant -->
52 <delete dir="compiled/packages/ant"/>
53
54 <!-- windows copy -->
55 <if><bool><equals arg1="${rk.os}" arg2="windows"/></bool>
56 <copy todir="compiled/packages">
57 <fileset dir="${rk.home}/core" includes="ant/**/*"/>
58 </copy>
59
60 <!-- linux, mac copy-->
61 <else><if><bool><or><equals arg1="${rk.os}" arg2="linux"/><equals arg1="${rk.os}" arg2="mac"/></or></bool>
62 <exec executable="cp">
63 <arg value="-r"/>
64 <arg value="${rk.home}/core/ant"/>
65 <arg value="compiled/packages"/>
66 </exec>
67
68 <!-- otherwise fail -->
69 <else>
70 <fail>this target does not support the current os</fail>
71
72 </else></if></else></if>
73
74 </target>
75
76 <!-- unused. this or something similar might need to go back in, to make the forward.properties permanent -->
77 <target name="generate-build-properties">
78 <copy file="${greenstone3.basedir}/build.properties.in" tofile="${greenstone3.basedir}/build.properties"/>
79 <if><bool><istrue value="${install.flax}"/></bool>
80 <rsr file="${greenstone3.basedir}/build.properties" pattern="^#install.flax\s*[=:].*" replacement="install.flax=true"/>
81 </if>
82 <if><bool><isset property="server.default.servlet"/></bool>
83 <rsr file="${greenstone3.basedir}/build.properties" pattern="^#?server.default.servlet\s*[=:].*" replacement="server.default.servlet=${server.default.servlet}"/>
84 </if>
85 </target>
86
87</project>
Note: See TracBrowser for help on using the repository browser.