Ignore:
Timestamp:
2007-01-26T11:20:30+13:00 (17 years ago)
Author:
kjdon
Message:

added in some targets for changing the java version that the installation has been set up for - a few jar files need to be there for 1.5 and not 1.4, tomcat needs a compat package for 1.4 but not 1.5

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl3/build.xml

    r13795 r13814  
    408408      <equals arg1="1.5" arg2="${ant.java.version}"/>
    409409    </condition>
    410     <antcall target="rename-xml-jars"/>
    411   </target>
    412  
    413   <target name="rename-xml-jars" if="need.xml.jars">
     410    <antcall target="activate-xml-jars"/>
     411    <antcall target="deactivate-xml-jars"/>
     412  </target>
     413 
     414  <target name="update-java-version" depends="init"
     415    description="Run this target if you have changed the default version of java since installing greenstone3">
     416    <condition property="need.xml.jars">
     417      <equals arg1="1.5" arg2="${ant.java.version}"/>
     418    </condition>
     419    <antcall target="activate-xml-jars"/>
     420    <antcall target="deactivate-xml-jars"/>
     421    <condition property="need.tomcat.compat">
     422      <equals arg1="1.4" arg2="${ant.java.version}"/>
     423    </condition>
     424    <antcall target="install-tomcat-compat"/>
     425    <antcall target="uninstall-tomcat-compat"/>
     426  </target>
     427 
     428  <target name="activate-xml-jars" if="need.xml.jars">
    414429    <copy file="${web.lib}/xalan.jar.tmp" tofile="${web.lib}/xalan.jar"/>
    415430    <copy file="${web.lib}/xercesImpl.jar.tmp" tofile="${web.lib}/xercesImpl.jar"/>
     431  </target>
     432 
     433  <target name="deactivate-xml-jars" unless="need.xml.jars">
     434    <delete file="${web.lib}/xalan.jar"/>
     435    <delete file="${web.lib}/xercesImpl.jar"/>
    416436  </target>
    417437
     
    539559    <copy file="${packages.home}/tomcat-compat/bin/jmx.jar"
    540560      tofile="${packages.home}/tomcat/bin/jmx.jar"/>
     561  </target>
     562  <target name="uninstall-tomcat-compat" unless="need.tomcat.compat">
     563    <delete file="${web.applet}/xml-apis.jar"/>
     564    <delete file="${packages.home}/tomcat/common/endorsed/xml-apis.jar"/>   
     565    <delete file="${web.applet}/xercesImpl.jar"/>
     566    <delete file="${packages.home}/tomcat/common/endorsed/xercesImpl.jar"/>
     567    <delete file="${packages.home}/tomcat/bin/jmx.jar"/>
    541568  </target>
    542569 
Note: See TracChangeset for help on using the changeset viewer.