root/release-kits/mark2/ant-scripts/compile.xml @ 17268

Revision 17268, 3.1 KB (checked in by oranfry, 11 years ago)

compile search4j in release process and started standardising java installtion

Line 
1<?xml version="1.0" encoding="utf-8" ?>
2<project name="mark2-compile" default="compile">
3
4    <target name="compile">
5
6        <!-- checkout -->
7        <antcall target="checkout-gsdl-gli" />
8       
9        <!-- configure -->
10        <antcall target="run-configure"/>
11        <antcall target="tweak-makefiles"/>
12
13        <!-- make -->
14        <antcall target="run-make"/>
15        <antcall target="run-make-install"/>
16        <antcall target="copy-library-oai"/>
17        <antcall target="strip-execs"/>
18
19        <!-- search4j -->
20        <antcall target="compile-search4j" /> <!-- from rk2-targets -->
21
22        <!-- uninstaller -->
23        <antcall target="compile-uninstaller" /> <!-- from rk2-targets -->
24
25        <!-- build collections -->
26        <antcall target="build-demo-collection" />
27
28    </target>
29
30    <target name="checkout-gsdl-gli">
31        <svn javahl="false">
32            <checkout url="${svn.root}/gsdl/${branch.path}" destPath="${basedir}/gsdl"/>
33            <checkout url="${svn.root}/gli/${branch.path}" destPath="${basedir}/gsdl/gli"/>
34        </svn>
35    </target>
36
37    <target name="run-configure">
38        <exec dir="${basedir}/gsdl" executable="${basedir}/gsdl/configure">
39            <arg line="--with-gdbm=${mark2.home}/mac/${processor}/gdbm"/>
40        </exec>
41    </target>
42
43    <target name="tweak-makefiles">
44        <rsr file="${basedir}/gsdl/runtime-src/src/recpt/Makefile" pattern="^(LIBS =.*)-L${mark2.home}/mac/${processor}/gdbm/lib -lgdbm(.*)$" replacement="$1${mark2.home}/mac/${processor}/gdbm/lib/libgdbm.a$2" />
45        <rsr file="${basedir}/gsdl/runtime-src/src/oaiservr/Makefile" pattern="^(LIBS =.*)-L${mark2.home}/mac/${processor}/gdbm/lib -lgdbm(.*)$" replacement="$1${mark2.home}/mac/${processor}/gdbm/lib/libgdbm.a$2" />
46        <rsr file="${basedir}/gsdl/common-src/src/gdbmedit/db2txt/Makefile" pattern="^(LIBS =.*)-L${mark2.home}/mac/${processor}/gdbm/lib -lgdbm(.*)$" replacement="$1${mark2.home}/mac/${processor}/gdbm/lib/libgdbm.a$2" />
47        <rsr file="${basedir}/gsdl/common-src/src/gdbmedit/txt2db/Makefile" pattern="^(LIBS =.*)-L${mark2.home}/mac/${processor}/gdbm/lib -lgdbm(.*)$" replacement="$1${mark2.home}/mac/${processor}/gdbm/lib/libgdbm.a$2" />
48        <rsr file="${basedir}/gsdl/runtime-src/src/recpt/Makefile" pattern="^(LIBS =.*)-L(.)\(PACKAGES_DIR\)/expat/lib -lexpat(.*)$" replacement="$1$2(PACKAGES_DIR)/expat/lib/libexpat.a$3" />
49        <rsr file="${basedir}/gsdl/runtime-src/src/oaiservr/Makefile" pattern="^(LIBS =.*)-L(.)\(PACKAGES_DIR\)/expat/lib -lexpat(.*)$" replacement="$1$2(PACKAGES_DIR)/expat/lib/libexpat.a$3" />
50    </target>
51
52    <target name="run-make">
53        <exec dir="${basedir}/gsdl" executable="make"/>
54    </target>
55
56    <target name="run-make-install">
57        <exec dir="${basedir}/gsdl" executable="make"><arg value="install"/></exec>
58    </target>
59
60    <target name="copy-library-oai">
61        <exec executable="cp"><arg line="${basedir}/gsdl/cgi-bin/library ${basedir}/gsdl/bin/darwin/library"/></exec>
62        <exec executable="cp"><arg line="${basedir}/gsdl/cgi-bin/oaiserver ${basedir}/gsdl/bin/darwin/oaiserver"/></exec>
63    </target>
64
65    <target name="strip-execs">
66        <exec dir="${basedir}/gsdl/bin/darwin" executable="find">
67            <arg line=". ! -name . -type f -maxdepth 1 -exec strip {} &#59;"/>
68        </exec>
69    </target>
70
71    <target name="build-demo-collection">
72        <exec dir="${basedir}/gsdl" executable="${mark2.home}/resources/build-demo.sh"/>
73    </target>
74
75</project>
Note: See TracBrowser for help on using the browser.