root/release-kits/sork3/ant-scripts/create-sourcecode-component.xml @ 20533

Revision 20533, 1.3 KB (checked in by oranfry, 11 years ago)

changes to the sork3 logic

Line 
1<?xml version="1.0" encoding="utf-8" ?>
2<!-- this is in a separate file because <import> can only load files that exist before build starts. This separate project is exeuted using <ant> AFTER greenstone3 has been checked out, to allow us to import the source-fileset.xml file -->
3<project name="create-sourcecode-component" default="csc">
4    <echo>basedir: ${basedir}</echo>
5
6    <import file="${basedir}/distributions/${dist.dirname}/resources/xml/components.xml"/>
7    <import file="${basedir}/distributions/${dist.dirname}/resources/xml/executables.xml"/>
8
9    <target name="create-sourcecode-component">
10
11        <copy todir="distributions/source-component">
12            <fileset dir="distributions/${dist.dirname}">
13                <patternset refid="greenstone3.source.component"/>
14            </fileset>
15        </copy>
16
17        <!-- fix permissions -->
18        <chmod perm="775">
19            <fileset dir="distributions/source-component"><patternset refid="greenstone3.source.executables"/></fileset>
20        </chmod>
21
22        <!-- archive it -->
23        <delete file="products/Greenstone-${version}-source-component.zip"/>
24        <zip destfile="products/Greenstone-${version}-source-component.zip" basedir="distributions/source-component" includes="**/*"/>
25        <exec dir="distributions/source-component" executable="bash">
26            <arg value="-c"/>
27            <arg value="tar -czf ../../products/Greenstone-${version}-source-component.tar.gz *"/>
28        </exec>
29    </target>
30
31
32</project>
Note: See TracBrowser for help on using the browser.