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

Last change on this file since 19938 was 19938, checked in by oranfry, 12 years ago

it's all good stuff

File size: 3.0 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/Jars"/>
21
22 <!-- core -->
23 <mkdir dir="cdrom/dist/Software/core/all"/>
24 <mkdir dir="cdrom/dist/Software/core/linux"/>
25 <copy todir="cdrom/dist/Software/core/all" overwrite="true">
26 <fileset dir="components/tmp/core"/>
27 </copy>
28 <move todir="cdrom/dist/Software/core/linux" overwrite="true">
29 <fileset dir="cdrom/dist/Software/core/all">
30 <include name="bin/linux"/>
31 <include name="bin/linux/**/*"/>
32 <include name="bin/windows"/>
33 <include name="bin/windows/**/*"/>
34 <include name="cgi-bin/library.cgi"/>
35 <include name="cgi-bin/oaiserver.cgi"/>
36 <include name="apache-httpd/**/*"/>
37 <include name="*.sh"/>
38 <include name="*.csh"/>
39 <include name="*.bash"/>
40 </fileset>
41 </move>
42
43 <!-- delete the httpd manual to save space -->
44 <delete dir="cdrom/dist/Software/core/linux/apache-httpd/linux/manual"/>
45
46 <!-- imagemagick (completely linux specific) -->
47 <mkdir dir="cdrom/dist/Software/imagemagick/linux"/>
48 <copy todir="cdrom/dist/Software/imagemagick/linux" overwrite="true">
49 <fileset dir="components/tmp/imagemagick"/>
50 </copy>
51
52 <!-- jre -->
53 <mkdir dir="cdrom/dist/Java/Linux"/>
54 <exec executable="cp">
55 <arg value="${lirk2.home}/linux/jre_bin"/>
56 <arg value="cdrom/dist/Java/Linux"/>
57 </exec>
58 <!--
59 <exec dir="cdrom/dist/Java/Linux" executable="${lirk2.home}/linux/jre_bin"/>
60 <exec dir="cdrom/dist/Java/Linux" executable="tar"><arg value="-xf"/><arg value="jre.tar"/></exec>
61 <delete file="cdrom/dist/Java/Linux/jre.tar"/>
62 -->
63
64 <!-- jar installer -->
65 <copy file="installer/cdrom.jar" tofile="cdrom/dist/Java/Jars/linux.jar"/>
66
67
68 </target>
69
70 <target name="compile-cdrom-wrapper">
71 <copy file="${rk.home}/linux/wrapper.cpp" todir="cdrom/build" overwrite="true"/>
72
73 <echo level="info">compile the cdrom wrapper</echo>
74 <exec executable="g++" dir="cdrom/build">
75 <arg line="-Wall -static -static-libgcc -c -DCDROM -o wrapper.o wrapper.cpp"/>
76 </exec>
77
78 <echo level="info">link the compiled code</echo>
79 <exec executable="g++" dir="cdrom/build">
80 <arg line="-static -static-libgcc -o ../dist/Greenstone-${version}-linux wrapper.o"/>
81 </exec>
82
83 </target>
84
85 <target name="create-cdrom-components-archive">
86 <mkdir dir="products"/>
87 <exec dir="cdrom/dist" executable="bash">
88 <arg value="-c"/>
89 <arg value="tar -czf ../../products/cdrom-components-${version}-linux.tar.gz *"/>
90 </exec>
91 </target>
92
93
94
95</project>
Note: See TracBrowser for help on using the repository browser.