[19592] | 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"/>
|
---|
[19615] | 12 | <antcall target="compile-cdrom-wrapper"/>
|
---|
| 13 | <antcall target="create-cdrom-components-archive"/>
|
---|
[19592] | 14 | </target>
|
---|
| 15 |
|
---|
| 16 | <target name="prepare-cdrom-components">
|
---|
[19615] | 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"/>
|
---|
[19592] | 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/**/*"/>
|
---|
[19768] | 35 | <include name="cgi-bin/library.cgi"/>
|
---|
| 36 | <include name="cgi-bin/oaiserver.cgi"/>
|
---|
[19592] | 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 |
|
---|
[19615] | 50 | <!-- jre -->
|
---|
[19592] | 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>
|
---|
[19615] | 53 | <delete file="cdrom/dist/Java/Linux/jre.tar"/>
|
---|
[19592] | 54 |
|
---|
[19615] | 55 | <!-- jar installer -->
|
---|
| 56 | <copy file="installer/cdrom.jar" tofile="cdrom/dist/Java/Jars/linux.jar"/>
|
---|
| 57 |
|
---|
[19592] | 58 |
|
---|
| 59 | </target>
|
---|
| 60 |
|
---|
[19615] | 61 | <target name="compile-cdrom-wrapper">
|
---|
[19596] | 62 | <copy file="${rk.home}/linux/wrapper.cpp" todir="cdrom/build" overwrite="true"/>
|
---|
[19592] | 63 |
|
---|
| 64 | <echo level="info">compile the cdrom wrapper</echo>
|
---|
| 65 | <exec executable="g++" dir="cdrom/build">
|
---|
[19596] | 66 | <arg line="-Wall -static -static-libgcc -c -DCDROM -o wrapper.o wrapper.cpp"/>
|
---|
[19592] | 67 | </exec>
|
---|
| 68 |
|
---|
| 69 | <echo level="info">link the compiled code</echo>
|
---|
| 70 | <exec executable="g++" dir="cdrom/build">
|
---|
[19596] | 71 | <arg line="-static -static-libgcc -o ../dist/Greenstone-${version}-linux wrapper.o"/>
|
---|
[19592] | 72 | </exec>
|
---|
[19615] | 73 |
|
---|
| 74 | </target>
|
---|
| 75 |
|
---|
| 76 | <target name="create-cdrom-components-archive">
|
---|
| 77 | <mkdir dir="products"/>
|
---|
[19592] | 78 | <exec dir="cdrom/dist" executable="bash">
|
---|
| 79 | <arg value="-c"/>
|
---|
| 80 | <arg value="tar -czf ../../products/cdrom-components-${version}-linux.tar.gz *"/>
|
---|
[19615] | 81 | </exec>
|
---|
| 82 | </target>
|
---|
[19592] | 83 |
|
---|
| 84 |
|
---|
| 85 |
|
---|
| 86 | </project>
|
---|