source: main/trunk/release-kits/kits/rk3/ant-scripts/compile.xml@ 23051

Last change on this file since 23051 was 23051, checked in by sjm84, 14 years ago

Reverted rk2 back to compiling up the gnome-lib (possibly temporarily) and updated the svn URLs for both rk2 and rk3

File size: 6.0 KB
RevLine 
[20335]1<?xml version="1.0" encoding="utf-8" ?>
2<project name="rk3-compile">
3
4 <target name="compile">
[21630]5
6 <!-- checkout greenstone3 -->
7 <exec executable="svn">
8 <arg value="checkout"/>
9 <arg value="${svn.root}/main/${branch.path}/greenstone3"/>
10 <arg value="compiled"/>
[21652]11 <arg value="-r"/><arg value="${branch.revision}"/>
[21630]12 </exec>
13
[21748]14 <!-- make sure all c++ compilation is done statically on linux -->
15 <if><bool><equals arg1="${rk.os}" arg2="linux"/></bool>
16 <property name="forward.compile.static" value="true"/>
17 </if>
18
[22851]19 <!-- make sure the c++ compilation can see the support library in the extension folder -->
20 <if><bool><or><equals arg1="${rk.os}" arg2="mac"/><equals arg1="${rk.os}" arg2="linux"/></or></bool>
21 <property name="forward.use.support.lib" value="true"/>
22 </if>
23
24 <antcall target="persist-forwarded-properties">
25 <param name="greenstone3basedir" value="compiled"/>
26 </antcall>
27
[21630]28 <!-- run greenstone3's ant prepare -->
[20335]29 <ant dir="compiled" inheritAll="false">
30 <target name="prepare"/>
31 <propertyset refid="forward.properties"/>
[21748]32 <property name="properties.accepted" value="true"/>
[20335]33 </ant>
[21630]34
35 <!-- set all version numbers -->
36 <antcall target="greenstone3-set-version-numbers"><param name="greenstone3basedir" value="compiled"/></antcall>
37 <antcall target="gli-set-version-numbers"><param name="glibasedir" value="compiled/gli"/></antcall>
38 <antcall target="gsdl-set-version-numbers"><param name="gsdl.basedir" value="compiled/gs2build"/></antcall>
39
[22836]40 <!-- mac or linux: compile the support library -->
41 <if><bool><or><equals arg1="${rk.os}" arg2="mac"/><equals arg1="${rk.os}" arg2="linux"/></or></bool>
42 <!-- checkout the gnome support library extension-->
[22939]43 <if><bool><or>
44 <equals arg1="${branch.path}" arg2="trunk"/>
45 <equals arg1="${branch.path}" arg2="tags/stable"/>
[22836]46 <isgreaterthan arg1="${branch.tag.version}" arg2="2.83"/>
[22939]47 </or></bool>
48 <echo>COMPILING GNOME LIB EXTENSION</echo>
[22836]49 <exec executable="svn">
50 <arg value="checkout"/>
[23051]51 <arg value="${svn.root}/gs2-extensions/gnome-lib/trunk/src"/>
[22851]52 <arg value="${basedir}/compiled/ext/gnome-lib"/>
[22836]53 </exec>
[22851]54 <exec executable="/bin/bash" dir="${basedir}/compiled/ext/gnome-lib">
[22836]55 <arg value="-c"/>
56 <arg value="./CASCADE-MAKE.sh"/>
57 </exec>
[22939]58 <echo>DONE COMPILING GNOME LIB EXTENSION</echo>
[22941]59 </if>
[22836]60 </if>
61
[21630]62 <!-- run greenstone3's ant install and ant dist-tidy -->
[20335]63 <ant dir="compiled" inheritAll="false">
64 <target name="install"/>
65 <target name="dist-tidy"/>
66 <propertyset refid="forward.properties"/>
[21748]67 <property name="properties.accepted" value="true"/>
[20335]68 </ant>
69
[22851]70 <!-- Delete the entire gnome support library on Linux -->
71 <if><bool><equals arg1="${rk.os}" arg2="linux"/></bool>
72 <delete dir="${basedir}/compiled/ext/gnome-lib"/>
73 </if>
74
75 <!-- Delete all but the lib folder of the gnome support library on Mac -->
76 <if><bool><equals arg1="${rk.os}" arg2="mac"/></bool>
77 <delete dir="${basedir}/compiled/ext/gnome-lib/cascade-make"/>
78 <delete dir="${basedir}/compiled/ext/gnome-lib/packages"/>
79 <delete dir="${basedir}/compiled/ext/gnome-lib/darwin/bin"/>
80 <delete dir="${basedir}/compiled/ext/gnome-lib/darwin/etc"/>
81 <delete dir="${basedir}/compiled/ext/gnome-lib/darwin/include"/>
82 <delete dir="${basedir}/compiled/ext/gnome-lib/darwin/share"/>
83 <delete file="${basedir}/compiled/ext/gnome-lib/setup.bat"/>
84 <delete file="${basedir}/compiled/ext/gnome-lib/CASCADE-MAKE.sh"/>
85 </if>
86
[21630]87 <!-- insert an xml parser -->
88 <copy todir="compiled/gs2build/perllib/cpan">
[22425]89 <fileset dir="${rk.home}/shared/linux" includes="XML-Parser/**/*"/>
[21630]90 </copy>
91
[21842]92 <!-- insert ant -->
93 <mkdir dir="compiled/packages"/>
94 <get src="http://www.greenstone.org/gs3files/apache-ant-1.8.0-bin.tar.gz" dest="compiled/packages/apache-ant-1.8.0-bin.tar.gz"/>
95 <untar src="compiled/packages/apache-ant-1.8.0-bin.tar.gz" dest="compiled/packages/" compression="gzip"/>
96 <move file="compiled/packages/apache-ant-1.8.0" tofile="compiled/packages/ant"/>
97 <delete file="compiled/packages/apache-ant-1.8.0-bin.tar.gz"/>
98
[21630]99
100 <!-- put the uninstaller in place -->
101 <antcall target="insert-and-compile-uninstaller"/>
102
103 <!-- (windows only) -->
[20335]104 <if><bool><equals arg1="${rk.os}" arg2="windows"/></bool>
[21630]105 <!-- insert perl -->
106 <unzip src="${rk.home}/shared/windows/perl.zip" dest="compiled/gs2build/bin/windows"/>
[20335]107 </if>
[21630]108
109 <!-- minify tomcat -->
110 <delete dir="compiled/packages/tomcat/webapps/docs"/>
111 <delete dir="compiled/packages/tomcat/webapps/examples"/>
112
113 <!-- tidy up gli to make it smaller -->
114 <antcall target="gli-tidy-for-dist"><param name="glibasedir" value="compiled/gli"/></antcall>
115
116 <!-- strip out .svn dirs -->
117 <antcall target="strip-svn-dirs"><param name="dir" value="compiled"/></antcall>
118
119 <!-- (linux only) -->
120 <if><bool><equals arg1="${rk.os}" arg2="linux"/></bool>
121 <!-- grab imagemagick binaries -->
122 <delete dir="compiled/gs2build/bin/linux/imagemagick"/>
123 <exec executable="svn">
124 <arg value="export"/>
125 <arg value="${svn.root}/main/${branch.path}/binaries/linux/imagemagick"/>
126 <arg value="compiled/gs2build/bin/linux/imagemagick"/>
127 </exec>
128
129 <!-- grab wv binaries -->
130 <delete dir="compiled/gs2build/bin/linux/wv"/>
131 <exec executable="svn">
132 <arg value="export"/>
133 <arg value="${svn.root}/main/${branch.path}/binaries/linux/wv"/>
134 <arg value="compiled/gs2build/bin/linux/wv"/>
135 </exec>
136 <!-- (mac only) -->
137 <else><if><bool><equals arg1="${rk.os}" arg2="mac"/></bool>
138 <!-- grab imagemagick binaries -->
139 <delete dir="compiled/gs2build/bin/darwin/imagemagick"/>
140 <exec executable="svn">
141 <arg value="export"/>
142 <arg value="${svn.root}/main/${branch.path}/binaries/mac/intel/imagemagick"/>
143 <arg value="compiled/gs2build/bin/darwin/imagemagick"/>
144 </exec>
145
146 <!-- grab ghostscript binaries -->
[21725]147 <delete dir="compiled/gs2build/bin/darwin/ghostscript"/>
[21630]148 <exec executable="svn">
149 <arg value="export"/>
150 <arg value="${svn.root}/main/${branch.path}/binaries/mac/intel/ghostscript"/>
151 <arg value="compiled/gs2build/bin/darwin/ghostscript"/>
152 </exec>
153 </if></else></if>
154
[20335]155 </target>
156
157</project>
Note: See TracBrowser for help on using the repository browser.