source: release-kits/lirk2/ant-scripts/create-cdrom-components.xml@ 19768

Last change on this file since 19768 was 19768, checked in by oranfry, 15 years ago

library.cgi and oaiserver.cgi are os-specific so put them in cdrom components

File size: 2.7 KB
Line 
1<project name="lirk2-create-cdrom-components">
2
3 <!--
4 cd components
5 produce components for cdrom distributions, to be picked up and used by cdrk2 release kit
6 split components into linux only files (linux) and general files (all)
7 -->
8
9 <target name="create-cdrom-components">
10 <antcall target="compile-cdrom-installer"/> <!-- from init -->
11 <antcall target="prepare-cdrom-components"/>
12 <antcall target="compile-cdrom-wrapper"/>
13 <antcall target="create-cdrom-components-archive"/>
14 </target>
15
16 <target name="prepare-cdrom-components">
17 <delete dir="cdrom"/>
18 <mkdir dir="cdrom/build"/>
19 <mkdir dir="cdrom/dist/Software"/>
20 <mkdir dir="cdrom/dist/Java/Linux"/>
21 <mkdir dir="cdrom/dist/Java/Jars"/>
22
23 <!-- core -->
24 <mkdir dir="cdrom/dist/Software/core/all"/>
25 <mkdir dir="cdrom/dist/Software/core/linux"/>
26 <copy todir="cdrom/dist/Software/core/all" overwrite="true">
27 <fileset dir="components/tmp/core"/>
28 </copy>
29 <move todir="cdrom/dist/Software/core/linux" overwrite="true">
30 <fileset dir="cdrom/dist/Software/core/all">
31 <include name="bin/linux"/>
32 <include name="bin/linux/**/*"/>
33 <include name="bin/windows"/>
34 <include name="bin/windows/**/*"/>
35 <include name="cgi-bin/library.cgi"/>
36 <include name="cgi-bin/oaiserver.cgi"/>
37 <include name="apache-httpd/**/*"/>
38 <include name="*.sh"/>
39 <include name="*.csh"/>
40 <include name="*.bash"/>
41 </fileset>
42 </move>
43
44 <!-- imagemagick (completely linux specific) -->
45 <mkdir dir="cdrom/dist/Software/imagemagick/linux"/>
46 <copy todir="cdrom/dist/Software/imagemagick/linux" overwrite="true">
47 <fileset dir="components/tmp/imagemagick"/>
48 </copy>
49
50 <!-- jre -->
51 <exec dir="cdrom/dist/Java/Linux" executable="${lirk2.home}/linux/jre_bin"/>
52 <exec dir="cdrom/dist/Java/Linux" executable="tar"><arg value="-xf"/><arg value="jre.tar"/></exec>
53 <delete file="cdrom/dist/Java/Linux/jre.tar"/>
54
55 <!-- jar installer -->
56 <copy file="installer/cdrom.jar" tofile="cdrom/dist/Java/Jars/linux.jar"/>
57
58
59 </target>
60
61 <target name="compile-cdrom-wrapper">
62 <copy file="${rk.home}/linux/wrapper.cpp" todir="cdrom/build" overwrite="true"/>
63
64 <echo level="info">compile the cdrom wrapper</echo>
65 <exec executable="g++" dir="cdrom/build">
66 <arg line="-Wall -static -static-libgcc -c -DCDROM -o wrapper.o wrapper.cpp"/>
67 </exec>
68
69 <echo level="info">link the compiled code</echo>
70 <exec executable="g++" dir="cdrom/build">
71 <arg line="-static -static-libgcc -o ../dist/Greenstone-${version}-linux wrapper.o"/>
72 </exec>
73
74 </target>
75
76 <target name="create-cdrom-components-archive">
77 <mkdir dir="products"/>
78 <exec dir="cdrom/dist" executable="bash">
79 <arg value="-c"/>
80 <arg value="tar -czf ../../products/cdrom-components-${version}-linux.tar.gz *"/>
81 </exec>
82 </target>
83
84
85
86</project>
Note: See TracBrowser for help on using the repository browser.