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

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

made lirk2 work under the new shared code scheme

File size: 4.2 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 </svn>
32 <svn>
33 <checkout url="${svn.root}/indexers/${branch.path}" destPath="${basedir}/gsdl/indexers"/>
34 </svn>
35 <svn>
36 <checkout url="${svn.root}/gli/${branch.path}" destPath="${basedir}/gsdl/gli"/>
37 </svn>
38 </if>
39 </target>
40
41 <target name="add-static-to-configure-in">
42 <if><bool><istrue value="${execute}"/></bool>
43 <rsr file="${basedir}/gsdl/configure.in" pattern="^LDFLAGS=.*$" replacement="LDFLAGS=-static"/>
44 <exec dir="${basedir}/gsdl" executable="autoconf" output="${basedir}/gsdl/configure"><arg value="configure.in"/></exec>
45 </if>
46 </target>
47
48 <target name="set-environment-in-packages-configure">
49 <if><bool><istrue value="${execute}"/></bool>
50 <rsr file="${basedir}/gsdl/packages/configure" pattern="^ENVIRONMENT=.*$" replacement="ENVIRONMENT=&quot;LDFLAGS=-static&quot;"/>
51 </if>
52 </target>
53
54 <target name="run-configure">
55 <if><bool><istrue value="${execute}"/></bool>
56 <exec dir="${basedir}/gsdl" executable="${basedir}/gsdl/configure"/>
57 </if>
58 </target>
59
60 <target name="makefiles-add-static">
61 <if><bool><istrue value="${execute}"/></bool>
62 <rsr file="${basedir}/gsdl/packages/wv/wv-gs/Makefile" pattern="^LDFLAGS =.*$" replacement="LDFLAGS = -static" />
63 <rsr file="${basedir}/gsdl/packages/xlhtml/xlhtml-0.4.9.0/xlhtml/Makefile" pattern="^LDFLAGS =.*$" replacement="LDFLAGS = -static" />
64 <rsr file="${basedir}/gsdl/packages/xlhtml/xlhtml-0.4.9.0/ppthtml/Makefile" pattern="^LDFLAGS =.*$" replacement="LDFLAGS = -static" />
65 <rsr file="${basedir}/gsdl/packages/rtftohtml/rtftohtml_src/Makefile" pattern="(-o rtftohtml.{2}EXEEXT.{1})" replacement="$1 -static" />
66 </if>
67 </target>
68
69 <target name="run-make">
70 <if><bool><istrue value="${execute}"/></bool>
71 <exec dir="${basedir}/gsdl" executable="make"/>
72 </if>
73 </target>
74
75 <target name="fix-wget">
76 <if><bool><istrue value="${execute}"/></bool>
77 <delete file="${basedir}/gsdl/packages/wget/wget-1.9/src/wget"/>
78 <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>
79 </if>
80 </target>
81
82
83 <target name="run-make-install">
84 <if><bool><istrue value="${execute}"/></bool>
85 <exec dir="${basedir}/gsdl" executable="make"><arg value="install"/></exec>
86 </if>
87 </target>
88
89 <target name="copy-library-oai">
90 <if><bool><istrue value="${execute}"/></bool>
91 <exec executable="cp"><arg line="${basedir}/gsdl/cgi-bin/library ${basedir}/gsdl/bin/linux/library"/></exec>
92 <exec executable="cp"><arg line="${basedir}/gsdl/cgi-bin/oaiserver ${basedir}/gsdl/bin/linux/oaiserver"/></exec>
93 </if>
94 </target>
95
96 <target name="strip-execs">
97 <if><bool><istrue value="${execute}"/></bool>
98 <exec dir="${basedir}/gsdl/bin/linux" executable="find">
99 <arg line="! -name . -type f -maxdepth 1 -exec strip {} &#59;"/>
100 </exec>
101 </if>
102 </target>
103
104 <target name="build-demo-collection">
105 <if><bool><istrue value="${execute}"/></bool>
106 <exec dir="${basedir}/gsdl" executable="${lirk2.home}/resources/build-demo.sh"/>
107 </if>
108 </target>
109
110
111
112</project>
Note: See TracBrowser for help on using the repository browser.