source: release-kits/lirk2/ant-scripts/compile.xml@ 16230

Last change on this file since 16230 was 16230, checked in by oranfry, 16 years ago

tidier svn checkouts

File size: 4.1 KB
Line 
1<?xml version="1.0" encoding="utf-8" ?>
2<project name="lirk2-compile" default="compile">
3
4 <target name="compile">
5
6 <!-- checkout -->
7 <addressedcall target="checkout-gsdl-indexers-gli" />
8
9 <!-- configure -->
10 <addressedcall target="add-static-to-configure-in"/>
11 <addressedcall target="set-environment-in-packages-configure"/>
12 <addressedcall target="run-configure"/>
13 <addressedcall target="makefiles-add-static"/>
14
15 <!-- make -->
16 <addressedcall target="run-make"/>
17 <addressedcall target="fix-wget"/>
18 <addressedcall target="run-make-install"/>
19 <addressedcall target="copy-library-oai"/>
20 <addressedcall target="strip-execs"/>
21
22 <!-- build collections -->
23 <addressedcall target="build-demo-collection" />
24
25 </target>
26
27 <target name="checkout-gsdl-indexers-gli">
28 <if><bool><istrue value="${execute}"/></bool>
29 <svn>
30 <checkout url="${svn.root}/gsdl/${branch.path}" destPath="${basedir}/gsdl"/>
31 <checkout url="${svn.root}/indexers/${branch.path}" destPath="${basedir}/gsdl/indexers"/>
32 <checkout url="${svn.root}/gli/${branch.path}" destPath="${basedir}/gsdl/gli"/>
33 </svn>
34 </if>
35 </target>
36
37 <target name="add-static-to-configure-in">
38 <if><bool><istrue value="${execute}"/></bool>
39 <rsr file="${basedir}/gsdl/configure.in" pattern="^LDFLAGS=.*$" replacement="LDFLAGS=-static"/>
40 <exec dir="${basedir}/gsdl" executable="autoconf" output="${basedir}/gsdl/configure"><arg value="configure.in"/></exec>
41 </if>
42 </target>
43
44 <target name="set-environment-in-packages-configure">
45 <if><bool><istrue value="${execute}"/></bool>
46 <rsr file="${basedir}/gsdl/packages/configure" pattern="^ENVIRONMENT=.*$" replacement="ENVIRONMENT=&quot;LDFLAGS=-static&quot;"/>
47 </if>
48 </target>
49
50 <target name="run-configure">
51 <if><bool><istrue value="${execute}"/></bool>
52 <exec dir="${basedir}/gsdl" executable="${basedir}/gsdl/configure"/>
53 </if>
54 </target>
55
56 <target name="makefiles-add-static">
57 <if><bool><istrue value="${execute}"/></bool>
58 <rsr file="${basedir}/gsdl/packages/wv/wv-gs/Makefile" pattern="^LDFLAGS =.*$" replacement="LDFLAGS = -static" />
59 <rsr file="${basedir}/gsdl/packages/xlhtml/xlhtml-0.4.9.0/xlhtml/Makefile" pattern="^LDFLAGS =.*$" replacement="LDFLAGS = -static" />
60 <rsr file="${basedir}/gsdl/packages/xlhtml/xlhtml-0.4.9.0/ppthtml/Makefile" pattern="^LDFLAGS =.*$" replacement="LDFLAGS = -static" />
61 <rsr file="${basedir}/gsdl/packages/rtftohtml/rtftohtml_src/Makefile" pattern="(-o rtftohtml.{2}EXEEXT.{1})" replacement="$1 -static" />
62 </if>
63 </target>
64
65 <target name="run-make">
66 <if><bool><istrue value="${execute}"/></bool>
67 <exec dir="${basedir}/gsdl" executable="make"/>
68 </if>
69 </target>
70
71 <target name="fix-wget">
72 <if><bool><istrue value="${execute}"/></bool>
73 <delete file="${basedir}/gsdl/packages/wget/wget-1.9/src/wget"/>
74 <exec dir="${basedir}/gsdl/packages/wget/wget-1.9/src" executable="gcc"><arg line="-O2 -Wall -Wno-implicit -o wget cmpt.o connect.o convert.o cookies.o ftp.o ftp-basic.o ftp-ls.o ftp-opie.o hash.o headers.o host.o html-parse.o html-url.o http.o init.o log.o main.o gen-md5.o netrc.o progress.o rbuf.o recur.o res.o retr.o safe-ctype.o snprintf.o gen_sslfunc.o url.o utils.o version.o -lssl -lcrypto -ldl -static"/></exec>
75 </if>
76 </target>
77
78
79 <target name="run-make-install">
80 <if><bool><istrue value="${execute}"/></bool>
81 <exec dir="${basedir}/gsdl" executable="make"><arg value="install"/></exec>
82 </if>
83 </target>
84
85 <target name="copy-library-oai">
86 <if><bool><istrue value="${execute}"/></bool>
87 <exec executable="cp"><arg line="${basedir}/gsdl/cgi-bin/library ${basedir}/gsdl/bin/linux/library"/></exec>
88 <exec executable="cp"><arg line="${basedir}/gsdl/cgi-bin/oaiserver ${basedir}/gsdl/bin/linux/oaiserver"/></exec>
89 </if>
90 </target>
91
92 <target name="strip-execs">
93 <if><bool><istrue value="${execute}"/></bool>
94 <exec dir="${basedir}/gsdl/bin/linux" executable="find">
95 <arg line="! -name . -type f -maxdepth 1 -exec strip {} &#59;"/>
96 </exec>
97 </if>
98 </target>
99
100 <target name="build-demo-collection">
101 <if><bool><istrue value="${execute}"/></bool>
102 <exec dir="${basedir}/gsdl" executable="${lirk2.home}/resources/build-demo.sh"/>
103 </if>
104 </target>
105
106
107
108</project>
Note: See TracBrowser for help on using the repository browser.