Show
Ignore:
Timestamp:
26.01.2010 14:44:30 (10 years ago)
Author:
oranfry
Message:

tidy up for greenstone3, and made wrap shared

Location:
main/trunk/release-kits/kits
Files:
4 removed
4 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/release-kits/kits/rk2/ant-scripts/build.xml

    r21623 r21630  
    99 
    1010<project name="rk2-build" default="rk2"> 
     11 
     12    <property name="version.major" value="2"/> 
    1113 
    1214    <!-- IMPORT OTHER ANT SCRIPTS --> 
     
    2628    <target name="rk2" depends="init,gs2-init,compile,create-components,create-installer,wrap,create-cdrom-components"/> 
    2729 
    28     <target name="properties"> 
    29         <echo>Required Properties:</echo> 
    30         <echo>version             the version string for the release</echo> 
    31         <echo/> 
    32         <echo>Optional Properties:</echo> 
    33         <echo>branch.path         the branch of Greenstone to make a release of. Eg: tags/2.81. Default: trunk.</echo> 
    34         <echo>branch.revision     the revision of Greenstone to make a release of. Eg: 18273. Default: HEAD.</echo> 
    35         <echo/> 
    36     </target> 
    37  
    38     <!-- TODO: Move the targets below to the xml file that calls it --> 
    39  
    40     <target name="create-binary-zip-unix"> 
    41         <property name="binzip.dir" value="distributions/Greenstone-${version}-${os.suffix}-binary"/> 
    42  
    43         <delete dir="${binzip.dir}"/> 
    44         <exec dir="${basedir}" executable="cp"><arg line="-r distributions/web ${binzip.dir}"/></exec> 
    45  
    46         <!-- delete sourcecode --> 
    47         <delete dir="${binzip.dir}/common-src"/> 
    48         <delete dir="${binzip.dir}/build-src"/> 
    49         <delete dir="${binzip.dir}/runtime-src"/> 
    50  
    51         <!-- delete loose files --> 
    52         <delete> 
    53             <fileset 
    54                 dir="${binzip.dir}" 
    55                 includes="README*.txt,Uninstall.sh,uninst.jar,acconfig.h,aclocal.m4,config.guess,config.sub,configtest.pl,configure,configure.in,install-sh,Makefile.in,micotest.cpp,config.h.in" 
    56                 excludes="READMEen.txt"/> 
    57         </delete> 
    58  
    59     </target> 
    60  
    61     <target name="dist-unzip-packages"> 
    62         <untar src="${basedir}/distributions/web/common-src/packages/sqlite/sqlite-amalgamation-3.5.9.tar.gz" dest="${basedir}/distributions/web/common-src/packages/sqlite" compression="gzip"/> 
    63         <delete file="${basedir}/distributions/web/common-src/packages/sqlite/sqlite-amalgamation-3.5.9.tar.gz"/> 
    64     </target> 
    65  
    66     <target name="copy-greenstone2-installer-files"> 
    67         <!-- the installer descriptors --> 
    68         <copy todir="installer" file="${rk.home}/kits/rk2/installer/antinstall-config.xml" overwrite="true"/> 
    69         <copy todir="installer" file="${rk.home}/kits/rk2/installer/build.xml" overwrite="true"/> 
    70     </target> 
     30    <!-- target to show properties in rk2-build.properties --> 
     31    <target name="properties" depends="core-properties"/> 
    7132 
    7233</project> 
  • main/trunk/release-kits/kits/rk3/ant-scripts/build.xml

    r20543 r21630  
    1010<project name="rk3-build" default="rk3"> 
    1111 
    12     <!-- CONSTANTS --> 
    13  
    14     <!-- for the benefit of the shared scripts, set release-kit home --> 
    15     <property name="rk.name" value="rk3"/> 
    16     <property name="rk.home" value="${rk3.home}" /> 
     12    <property name="version.major" value="3"/> 
    1713 
    1814    <!-- IMPORT OTHER ANT SCRIPTS --> 
    19     <import file="../core/ant-scripts/init.xml"/> 
    20     <import file="../core/ant-scripts/operations-on-gli.xml"/> 
    21     <import file="../greenstone3/ant-scripts/rk3-targets.xml"/> 
     15    <import file="${rk.home}/shared/core/ant-scripts/init.xml"/> 
     16    <import file="${rk.home}/shared/core/ant-scripts/operations-on-gli.xml"/> 
     17    <import file="${rk.home}/shared/greenstone2/ant-scripts/rk3-targets.xml"/> 
    2218 
    2319    <import file="compile.xml"/> 
    24     <import file="create-distribution.xml"/> 
    25     <import file="create-installer.xml"/> 
     20    <import file="${rk.home}/shared/core/ant-scripts/create-installer.xml"/> 
    2621    <import file="wrap.xml"/> 
    2722 
     
    2924    <target name="rk3" depends="init,gs3-init"> 
    3025        <antcall target="compile"/> 
    31         <antcall target="create-distribution"/> 
    32         <ant inheritRefs="true" dir="." antfile="${rk3.home}/ant-scripts/create-components.xml" target="create-components"/> 
     26        <ant inheritRefs="true" dir="." antfile="${rk.home}/kits/${rk.name}/ant-scripts/create-components.xml" target="create-components"/> 
    3327        <antcall target="create-installer"/> 
    3428        <antcall target="wrap"/> 
    35         <antcall target="create-minimal-distribution"/> 
    36  
    3729    </target> 
    3830 
    39     <target name="properties"> 
    40         <echo>Required Properties:</echo> 
    41         <echo>version             the version string for the release</echo> 
    42         <echo/> 
    43         <echo>Optional Properties:</echo> 
    44         <echo>branch.path         the branch of Greenstone3 to make a release of. Eg: tags/2.81. Default: trunk.</echo> 
    45         <echo>branch.revision     the revision of Greenstone3 to make a release of. Eg: 18273. Default: HEAD.</echo> 
    46         <echo/> 
    47     </target> 
     31    <!-- target to show properties in rk3-build.properties --> 
     32    <target name="properties" depends="core-properties"/> 
    4833 
     34    <!-- create the property set to be forwarded to greenstone3 --> 
     35    <propertyset id="forward.properties"> 
     36        <propertyref prefix="forward."/> 
     37        <mapper type="glob" from="forward.*" to="*"/> 
     38        <propertyref name="app.version"/> 
     39        <propertyref name="branch.path"/> 
     40        <propertyref name="branch.revision"/> 
     41    </propertyset> 
    4942 
    5043</project> 
  • main/trunk/release-kits/kits/rk3/ant-scripts/compile.xml

    r20335 r21630  
    33 
    44    <target name="compile"> 
    5         <antcall target="checkout-greenstone3"/> 
     5 
     6        <!-- checkout greenstone3 --> 
     7        <exec executable="svn"> 
     8            <arg value="checkout"/> 
     9            <arg value="${svn.root}/main/${branch.path}/greenstone3"/> 
     10            <arg value="compiled"/> 
     11            <arg value="-r"><arg value="${branch.revision}"/> 
     12        </exec> 
     13 
     14        <!-- run greenstone3's ant prepare --> 
    615        <ant dir="compiled" inheritAll="false"> 
    716            <target name="prepare"/> 
    817            <propertyset refid="forward.properties"/> 
    918        </ant> 
    10         <antcall target="greenstone3-set-version-numbers"> 
    11             <param name="greenstone3basedir" value="compiled"/> 
    12         </antcall> 
    13         <antcall target="gli-set-version-numbers"> 
    14             <param name="glibasedir" value="compiled/gli"/> 
    15         </antcall> 
    16         <antcall target="gsdl-set-version-numbers"> 
    17             <param name="gsdl.basedir" value="compiled/gs2build"/> 
    18         </antcall> 
     19 
     20        <!-- set all version numbers --> 
     21        <antcall target="greenstone3-set-version-numbers"><param name="greenstone3basedir" value="compiled"/></antcall> 
     22        <antcall target="gli-set-version-numbers"><param name="glibasedir" value="compiled/gli"/></antcall> 
     23        <antcall target="gsdl-set-version-numbers"><param name="gsdl.basedir" value="compiled/gs2build"/></antcall> 
     24 
     25        <!-- run greenstone3's ant install and ant dist-tidy --> 
    1926        <ant dir="compiled" inheritAll="false"> 
    2027            <target name="install"/> 
     
    2229            <propertyset refid="forward.properties"/> 
    2330        </ant> 
    24         <antcall target="insert-xml-parser"/> 
    25         <antcall target="insert-ant"/> 
    26         <antcall target="insert-documented-examples"/> 
    27         <antcall target="compile-uninstaller" /> 
    28         <antcall target="prepare-documentation"/> 
    2931 
    30         <!-- windows only --> 
     32        <!-- insert an xml parser --> 
     33        <copy todir="compiled/gs2build/perllib/cpan"> 
     34            <fileset dir="${rk.home}/shared/greenstone3" includes="XML-Parser/**/*"/> 
     35        </copy> 
     36 
     37        <!-- TODO: insert-ant --> 
     38 
     39        <!-- put the uninstaller in place --> 
     40        <antcall target="insert-and-compile-uninstaller"/> 
     41 
     42        <!-- (windows only) --> 
    3143        <if><bool><equals arg1="${rk.os}" arg2="windows"/></bool> 
    32             <antcall target="insert-windows-perl"> 
    33                 <param name="todir" value="compiled/gs2build/bin/windows"/> 
    34             </antcall> 
    35             <antcall target="insert-windows-icon"/> 
     44            <!-- insert perl --> 
     45            <unzip src="${rk.home}/shared/windows/perl.zip" dest="compiled/gs2build/bin/windows"/> 
    3646        </if> 
     47 
     48        <!-- minify tomcat --> 
     49        <delete dir="compiled/packages/tomcat/webapps/docs"/> 
     50        <delete dir="compiled/packages/tomcat/webapps/examples"/> 
     51 
     52        <!-- tidy up gli to make it smaller --> 
     53        <antcall target="gli-tidy-for-dist"><param name="glibasedir" value="compiled/gli"/></antcall> 
     54 
     55        <!-- strip out .svn dirs --> 
     56        <antcall target="strip-svn-dirs"><param name="dir" value="compiled"/></antcall> 
     57 
     58        <!-- (linux only) --> 
     59        <if><bool><equals arg1="${rk.os}" arg2="linux"/></bool> 
     60            <!-- grab imagemagick binaries --> 
     61            <delete dir="compiled/gs2build/bin/linux/imagemagick"/> 
     62            <exec executable="svn"> 
     63                <arg value="export"/> 
     64                <arg value="${svn.root}/main/${branch.path}/binaries/linux/imagemagick"/> 
     65                <arg value="compiled/gs2build/bin/linux/imagemagick"/> 
     66            </exec> 
     67 
     68            <!-- grab wv binaries --> 
     69            <delete dir="compiled/gs2build/bin/linux/wv"/> 
     70            <exec executable="svn"> 
     71                <arg value="export"/> 
     72                <arg value="${svn.root}/main/${branch.path}/binaries/linux/wv"/> 
     73                <arg value="compiled/gs2build/bin/linux/wv"/> 
     74            </exec> 
     75        <!-- (mac only) --> 
     76        <else><if><bool><equals arg1="${rk.os}" arg2="mac"/></bool> 
     77            <!-- grab imagemagick binaries --> 
     78            <delete dir="compiled/gs2build/bin/darwin/imagemagick"/> 
     79            <exec executable="svn"> 
     80                <arg value="export"/> 
     81                <arg value="${svn.root}/main/${branch.path}/binaries/mac/intel/imagemagick"/> 
     82                <arg value="compiled/gs2build/bin/darwin/imagemagick"/> 
     83            </exec> 
     84 
     85            <!-- grab ghostscript binaries --> 
     86            <delete dir="compiled/gs2build/bin/darwin/imagemagick"/> 
     87            <exec executable="svn"> 
     88                <arg value="export"/> 
     89                <arg value="${svn.root}/main/${branch.path}/binaries/mac/intel/ghostscript"/> 
     90                <arg value="compiled/gs2build/bin/darwin/ghostscript"/> 
     91            </exec> 
     92        </if></else></if> 
     93 
    3794    </target> 
    3895 
  • main/trunk/release-kits/kits/rk3/ant-scripts/create-components.xml

    r21311 r21630  
    22<project name="rk3-create-components"> 
    33 
    4     <import file="${basedir}/distributions/web/resources/xml/components.xml"/> 
     4    <import file="${basedir}/compiled/resources/xml/components.xml"/> 
    55    <import file="${rk.home}/core/ant-scripts/init.xml"/> 
    6  
    7     <!-- create components from the distributions folder --> 
    86 
    97    <target name="create-components"> 
    108 
    11         <antcall target="prepare-component"><param name="component" value="core"/></antcall> 
    12         <antcall target="compress-component"><param name="component" value="core"/></antcall> 
     9        <!-- core --> 
     10        <antcall target="create-component"><param name="component" value="core"/></antcall> 
    1311 
    14         <antcall target="prepare-component"><param name="component" value="tomcat"/></antcall> 
    15         <antcall target="compress-component"><param name="component" value="tomcat"/></antcall> 
     12        <!-- tomcat --> 
     13        <antcall target="create-component"><param name="component" value="tomcat"/></antcall> 
    1614 
    17         <antcall target="prepare-component"><param name="component" value="imagemagick"/></antcall> 
    18         <antcall target="compress-component"><param name="component" value="imagemagick"/></antcall> 
     15        <!-- imageagick --> 
     16        <antcall target="create-component"><param name="component" value="imagemagick"/></antcall> 
    1917 
    20         <!-- windows and mac only --> 
     18        <!-- (windows and mac only) --> 
    2119        <if><bool><or><equals arg1="${rk.os}" arg2="windows"/><equals arg1="${rk.os}" arg2="mac"/></or></bool> 
    22             <antcall target="prepare-component"><param name="component" value="ghostscript"/></antcall> 
    23             <antcall target="compress-component"><param name="component" value="ghostscript"/></antcall> 
     20            <!-- ghostscript --> 
     21            <antcall target="create-component"><param name="component" value="ghostscript"/></antcall> 
    2422        </if> 
    2523