Show
Ignore:
Timestamp:
14.04.2008 12:11:39 (12 years ago)
Author:
kjdon
Message:

changed nocvs.mode to nosvn.mode; added a distclean target and the necessary supporting targets. change basedir/web to web.home in the flax targets; removed some commented out stuff

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • greenstone3/trunk/build.xml

    r15183 r15185  
    307307    description="Configure the installation. Includes setting up config files. Should be re-run if you change the build.properties file."/> 
    308308 
    309   <target name="clean" depends="init,clean-packages,clean-core,clean-gs2building" 
     309  <target name="clean" depends="init,clean-packages,clean-core,clean-gs2building,clean-gdbm" 
    310310    description="Remove all old compiled code. Includes core, packages and gs2building if necessary"/> 
     311   
     312  <target name="distclean" depends="init,distclean-packages,clean-core,distclean-gs2building,distclean-gdbm" 
     313    description="Remove all compiled code and also any Makefiles etc generated during configure-c++. Includes core, packages, gs2building as necessary"/> 
    311314   
    312315  <target name="compile" depends="init,compile-web,compile-packages,compile-core,compile-gs2building" 
     
    314317   
    315318  <target name="update" depends="init,svnupdate,clean,configure,configure-c++,compile"  
    316     description="Update (thru Subversion) all the source (including core, packages and gs2building), then clean, configure and recompile."/> 
     319    description="Update (thru Subversion) all the source (including core, packages and gs2building), then clean, configure and recompile. To do this without any SVN updates, run it like 'ant -Dnosvn.mode=yes update'"/> 
    317320 
    318321  <target name="start" depends="init,start-tomcat" 
     
    368371  </target> 
    369372 
    370   <!--  <target name="check-cvsroot"> 
    371   <condition property="svnroot.notset"> 
    372   <or> 
    373   <not> 
    374   <isset property="env.CVSROOT"/> 
    375             </not> 
    376   <equals arg1="" arg2="${env.CVSROOT}"/> 
    377       </or> 
    378     </condition> 
    379   <fail if="cvsroot.notset" message="You need to set the CVSROOT variable"/> 
    380   </target> --> 
    381373 
    382374  <!-- this sets up some initial properties --> 
     
    817809  <!-- core targets refer to the core gsdl3 java src --> 
    818810   
    819   <target name="prepare-core" unless="nocvs.mode"> 
     811  <target name="prepare-core" unless="nosvn.mode"> 
    820812    <!-- just get rid of empty directories--> 
    821813    <svn> 
     
    829821    description="Update only the Greenstone core" /> 
    830822   
    831   <target name="svnupdate-core" unless="nocvs.mode"> 
     823  <target name="svnupdate-core" unless="nosvn.mode"> 
    832824 
    833825    <svn> 
     
    936928  <target name="prepare-packages" depends="init,prepare-indexers"/> 
    937929   
    938   <target name="checkout-indexers" depends="init" if="independent-indexers" unless="nocvs.mode"> 
    939     <!--  <target name="checkout-indexers" depends="check-svnroot,init" if="independent-indexers" unless="nocvs.mode"> --> 
     930  <target name="checkout-indexers" depends="init" if="independent-indexers" unless="nosvn.mode"> 
    940931    <svn> 
    941932      <checkout url="${svn.root}/indexers/${branch.path}" dest="${src.packages.home}/indexers" revision="${branch.revision}"/> 
     
    950941    description="Update only the source packages"/> 
    951942 
    952   <target name="svnupdate-packages" unless="nocvs.mode">  
     943  <target name="svnupdate-packages" unless="nosvn.mode">  
    953944    <svn> 
    954945      <update dir="${src.packages.home}"/> 
     
    10091000 
    10101001  </target> 
     1002  <target name="distclean-packages" depends="init,distclean-javagdbm,distclean-indexers" description="Distclean only the packages"/> 
     1003 
     1004  <target name="distclean-javagdbm" depends="init"> 
     1005    <exec executable="make" os="${os.unix}" 
     1006      dir="${javagdbm.home}"> 
     1007      <arg value="distclean"/> 
     1008    </exec> 
     1009  </target> 
     1010   
     1011  <target name="distclean-indexers" depends="init" if="independent-indexers"> 
     1012    <exec executable="make" os="${os.unix}" 
     1013      dir="${indexers.home}"> 
     1014      <arg value="distclean"/> 
     1015    </exec> 
     1016    <exec executable="${indexers.home}/winMake.bat" os="${os.windows}" 
     1017      dir="${indexers.home}"> 
     1018      <arg value="clean"/> 
     1019    </exec> 
     1020 
     1021  </target> 
    10111022   
    10121023  <target name="compile-packages" description="Compile only the source packages"> 
     
    10911102    description="Update only the Greenstone 2 building components"/> 
    10921103 
    1093   <target name="svnupdate-gs2building" if="collection.building.enabled" depends="init,svnupdate-gs2build,svnupdate-gli" unless="nocvs.mode"> 
    1094   </target> 
    1095  
    1096   <target name="svnupdate-gs2build" if="collection.building.enabled" depends="init" unless="nocvs.mode"> 
     1104  <target name="svnupdate-gs2building" if="collection.building.enabled" depends="init,svnupdate-gs2build,svnupdate-gli" unless="nosvn.mode"> 
     1105  </target> 
     1106 
     1107  <target name="svnupdate-gs2build" if="collection.building.enabled" depends="init" unless="nosvn.mode"> 
    10971108    <!-- please keep this function in sync with checkout-gs2build --> 
    10981109 
     
    11681179  </target> 
    11691180   
    1170   <target name="svnupdate-gli" if="collection.building.enabled" depends="init" unless="nocvs.mode"> 
     1181  <target name="svnupdate-gli" if="collection.building.enabled" depends="init" unless="nosvn.mode"> 
    11711182    <svn> 
    11721183      <update dir="${gli.home}" revision="${branch.revision}"/> 
     
    11761187  <target name="prepare-gs2building" depends="init,prepare-gs2build,prepare-gli" if="collection.building.enabled"> 
    11771188  </target> 
    1178   <target name="checkout-gs2build" depends="init" if="collection.building.enabled" unless="nocvs.mode"> 
     1189  <target name="checkout-gs2build" depends="init" if="collection.building.enabled" unless="nosvn.mode"> 
    11791190    <!-- please keep this function in sync with update-gs2build --> 
    11801191    <echo>checking out gs2build</echo> 
     
    12641275 
    12651276  <target name="checkout-winbin" depends="init" if="current.os.iswindows"  
    1266     unless="nocvs.mode"> 
     1277    unless="nosvn.mode"> 
    12671278    <svn> 
    12681279      <checkout url="${svn.root}/other-projects/trunk/winbin" destPath="${basedir}/winbin" revision="${branch.revision}"/> 
     
    12701281  </target> 
    12711282 
    1272   <target name="update-winbin" depends="init" if="current.os.iswindows" unless="nocvs.mode"> 
     1283  <target name="update-winbin" depends="init" if="current.os.iswindows" unless="nosvn.mode"> 
    12731284    <svn> 
    12741285      <update dir="winbin"/> 
     
    13591370  </target> 
    13601371   
    1361   <!--  <target name="checkout-gli" depends="check-cvsroot,init" if="collection.building.enabled" unless="nocvs.mode"> --> 
    1362   <target name="checkout-gli" depends="init" if="collection.building.enabled" unless="nocvs.mode"> 
     1372  <target name="checkout-gli" depends="init" if="collection.building.enabled" unless="nosvn.mode"> 
    13631373    <echo>checking out gli</echo> 
    13641374    <svn> 
     
    14111421  </target> 
    14121422   
     1423  <target name="distclean-gs2building" depends="init,clean-gli,clean-gs2build,distclean-gs2build"  
     1424    description="Distclean only the Greenstone 2 building components"  
     1425    if="collection.building.enabled"/> 
     1426 
    14131427  <target name="distclean-gs2build" depends="init" if="collection.building.enabled"> 
    1414     <!-- gs2build --> 
    1415     <!--linux:  --> 
    14161428    <exec executable="make" os="${os.unix}" dir="${gs2build.home}"> 
    14171429      <arg value="distclean"/> 
    14181430    </exec> 
    1419     <!-- windows: -->     
    14201431  </target> 
    14211432   
     
    15231534    </echo> 
    15241535  </target> 
     1536 
     1537  <!-- ======================== FLAX Targets ========================= --> 
    15251538  <target name="prepare-flax" description="check out flax source code from another repository" if="install.flax"> 
    15261539    <echo>checking out flax ...</echo> 
    15271540    <mkdir dir="${basedir}/src/java/org/flax"/> 
    15281541    <mkdir dir="${basedir}/src/java/org/greenstone/gsdl3/flax"/> 
    1529     <mkdir dir="${basedir}/web/WEB-INF/classes/flax"/> 
    1530     <mkdir dir="${basedir}/web/interfaces/flax"/> 
    1531     <mkdir dir="${basedir}/web/sites/flax"/> 
     1542    <mkdir dir="${web.home}/WEB-INF/classes/flax"/> 
     1543    <mkdir dir="${web.home}/interfaces/flax"/> 
     1544    <mkdir dir="${web.home}/sites/flax"/> 
    15321545    <mkdir dir="${basedir}/flax-resources"/> 
    15331546    <mkdir dir="${basedir}/flax-lib"/> 
     
    15381551    destPath="${basedir}/src/java/org/greenstone/gsdl3/flax"/> 
    15391552      <checkout url="${flax.svn.root}/flax1.0/trunk/web/WEB-INF/classes/flax/"  
    1540     destPath="${basedir}/web/WEB-INF/classes/flax"/> 
     1553    destPath="${web.home}/WEB-INF/classes/flax"/> 
    15411554      <checkout url="${flax.svn.root}/flax1.0/trunk/web/interfaces/flax/"  
    1542     destPath="${basedir}/web/interfaces/flax"/> 
     1555    destPath="${web.home}/interfaces/flax"/> 
    15431556      <checkout url="${flax.svn.root}/flax1.0/trunk/web/sites/flax/"  
    1544     destPath="${basedir}/web/sites/flax"/> 
     1557    destPath="${web.home}/sites/flax"/> 
    15451558      <checkout url="${flax.svn.root}/flax1.0/trunk/flax-resources" 
    15461559    destPath="${basedir}/flax-resources"/> 
     
    15491562    </svn> 
    15501563    <echo>prepare flax files...</echo> 
    1551     <move file="${basedir}/web/WEB-INF/web.xml" tofile="${basedir}/web/WEB-INF/web.xml.greenstone3backup"/> 
     1564    <move file="${web.home}/WEB-INF/web.xml" tofile="${web.home}/WEB-INF/web.xml.greenstone3backup"/> 
    15521565    <antcall target="flax-copy-files" /> 
    15531566    <antcall target="unzip-flax-collections" /> 
     
    15601573      <update dir="${basedir}/src/java/org/flax"/> 
    15611574      <update dir="${basedir}/src/java/org/greenstone/gsdl3/flax"/> 
    1562       <update dir="${basedir}/web/WEB-INF/classes/flax"/> 
    1563       <update dir="${basedir}/web/interfaces/flax"/> 
    1564       <update dir="${basedir}/web/sites/flax"/> 
     1575      <update dir="${web.home}/WEB-INF/classes/flax"/> 
     1576      <update dir="${web.home}/interfaces/flax"/> 
     1577      <update dir="${web.home}/sites/flax"/> 
    15651578    </svn> 
    15661579    <antcall target="flax-copy-files" /> 
     
    15691582 
    15701583  <target name="unzip-flax-collections" > 
    1571     <property name="coll.dir" value="${basedir}/web/sites/flax/collect"/> 
     1584    <property name="coll.dir" value="${web.home}/sites/flax/collect"/> 
    15721585    <unzip dest="${coll.dir}">   
    15731586      <fileset dir="${coll.dir}"> 
     
    15811594 
    15821595  <target name="unzip-flax-resources" > 
    1583     <property name="classes.dir" value="${basedir}/web//WEB-INF/classes/flax"/> 
     1596    <property name="classes.dir" value="${web.home}/WEB-INF/classes/flax"/> 
    15841597    <unzip dest="${classes.dir}">   
    15851598      <fileset dir="${classes.dir}"> 
     
    15941607  <target name="flax-copy-files" description="copy some flax files into the appropriate greenstone3 directories"> 
    15951608    <echo>copying flax files ...</echo> 
    1596     <copy file="${basedir}/web/WEB-INF/classes/flax/web.xml" todir="${basedir}/web/WEB-INF" overwrite="true" /> 
     1609    <copy file="${web.home}/WEB-INF/classes/flax/web.xml" todir="${web.home}/WEB-INF" overwrite="true" /> 
    15971610    <!-- A configuration file containing web service binding information for the axis engine --> 
    1598     <copy file="${basedir}/web/WEB-INF/classes/flax/server-config.wsdd" todir="${basedir}/web/WEB-INF" overwrite="true" /> 
     1611    <copy file="${web.home}/WEB-INF/classes/flax/server-config.wsdd" todir="${web.home}/WEB-INF" overwrite="true" /> 
    15991612    <copy file="${basedir}/flax-resources/flax-build.xml" todir="${basedir}" overwrite="true" /> 
    1600     <copy file="${basedir}/flax-lib/opennlp-tools-1.3.0.jar" todir="${basedir}/web/WEB-INF/lib" overwrite="true" />     
    1601   </target> 
    1602   <!--install gdbm stuff --> 
    1603  
    1604   <!-- downloads the gdbm library --> 
     1613    <copy file="${basedir}/flax-lib/opennlp-tools-1.3.0.jar" todir="${web.home}/WEB-INF/lib" overwrite="true" />     
     1614  </target> 
     1615 
     1616 
     1617  <!-- ======================== GDBM Targets ========================= --> 
     1618 
    16051619  <target name="prepare-gdbm" depends="init" if="install.gdbm"> 
    16061620    <get src="http://www.greenstone.org/gs3files/gdbm-1.8.3.tar.gz" 
     
    16291643  </target>  
    16301644 
     1645  <target name="distclean-gdbm" depends="init"  if="install.gdbm">    
     1646    <echo>distclean GDBM</echo> 
     1647    <exec executable="make" os="${os.unix},${os.mac}" dir="${gdbm.home}" > 
     1648      <arg value="distclean"/> 
     1649    </exec> 
     1650  </target>  
     1651 
    16311652  <target name="compile-gdbm" depends="init"  if="install.gdbm">    
    16321653    <echo>compile GDBM</echo> 
     
    16371658  </target>  
    16381659 
    1639  
    1640  
    16411660</project> 
    16421661