JAL-1432 'whats new' and release history
[jalview.git] / build.xml
index 83425ce..3710430 100755 (executable)
--- a/build.xml
+++ b/build.xml
@@ -1,20 +1,21 @@
 <?xml version="1.0"?>
 <!--
- * Jalview - A Sequence Alignment Editor and Viewer (Version 2.7)
- * Copyright (C) 2011 J Procter, AM Waterhouse, J Engelhardt, LM Lui, G Barton, M Clamp, S Searle
+ * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.0b1)
+ * Copyright (C) 2014 The Jalview Authors
  * 
  * This file is part of Jalview.
  * 
  * Jalview is free software: you can redistribute it and/or
  * modify it under the terms of the GNU General Public License 
  * as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
- * 
+ *  
  * Jalview is distributed in the hope that it will be useful, but 
  * WITHOUT ANY WARRANTY; without even the implied warranty 
  * of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
  * PURPOSE.  See the GNU General Public License for more details.
  * 
  * You should have received a copy of the GNU General Public License along with Jalview.  If not, see <http://www.gnu.org/licenses/>.
+ * The Jalview Authors are detailed in the 'AUTHORS' file.
 -->
 <project name="jalviewX" default="usage" basedir=".">
   <!-- we use jalopy to format our sources -->
   </target>
 
   <target name="makefulldist" depends="makedist">
-    <!-- the default keystore details might need to be edited here -->
-    <signjar storepass="${jalview.keystore.pass}" keypass="${jalview.key.pass}" keystore="${jalview.keystore}" alias="${jalview.key}" lazy="false" verbose="false" sigalg="SHA1withRSA">
 
-      <fileset dir="${packageDir}">
-        <include name="*.jar" />
-      </fileset>
-    </signjar>
     <copy todir="${packageDir}">
       <fileset dir="${resourceDir}/images">
         <include name="${WebStartImage}" />
 
     <taskdef classpathref="build.classpath" resource="com/roxes/tools/ant/taskdefs.properties" />
 
-    <!--    codebase="http://www.jalview.org/jalview/webstart" -->
-    <!-- href="jalview.jnlp" prevent hard-wired pickup of jnlp in certain javaws versions -->
-    <jnlp toFile="${packageDir}/jalview.jnlp" codebase="${WebStartLocation}">
-      <information>
-        <title>Jalview</title>
-        <vendor>The Barton Group</vendor>
-        <homepage href="http://www.jalview.org" />
-        <description>Jalview Multiple Alignment Editor</description>
-        <description kind="short">Jalview</description>
-        <icon href="${WebStartImage}" />
-        <offline_allowed />
-      </information>
-      <resources>
-        <j2se version="${j2sev}" initial_heap_size="10M" />
-        <fileset dir="${packageDir}">
-          <include name="jalview.jar" />
-        </fileset>
-        <fileset dir="${packageDir}">
-          <include name="*.jar" />
-          <include name="*_*.jar" />
-          <exclude name="jalview.jar" />
-        </fileset>
-        <property name="jalview.version" value="${JALVIEW_VERSION}" />
-      </resources>
-      <application_desc main_class="jalview.bin.Jalview">
-      </application_desc>
-      <security>
-        <all_permissions />
-      </security>
-    </jnlp>
-    <jnlp toFile="${packageDir}/jalview_1G.jnlp" codebase="${WebStartLocation}">
-      <information>
-        <title>Jalview</title>
-        <vendor>The Barton Group</vendor>
-        <homepage href="http://www.jalview.org" />
-        <description>Jalview Multiple Alignment Editor</description>
-        <description kind="short">Jalview</description>
-        <icon href="${WebStartImage}" />
-        <offline_allowed />
-      </information>
-      <resources>
-        <j2se version="${j2sev}" initial_heap_size="128M" max_heap_size="512M" />
-        <fileset dir="${packageDir}">
-          <include name="jalview.jar" />
-        </fileset>
-        <fileset dir="${packageDir}">
-          <include name="*.jar" />
-          <include name="*_*.jar" />
-          <exclude name="jalview.jar" />
-        </fileset>
-        <property name="jalview.version" value="${JALVIEW_VERSION}" />
-      </resources>
-      <application_desc main_class="jalview.bin.Jalview">
-      </application_desc>
-      <security>
-        <all_permissions />
-      </security>
-    </jnlp>
-    <jnlp toFile="${packageDir}/jalview_2G.jnlp" codebase="${WebStartLocation}">
-      <information>
-        <title>Jalview</title>
-        <vendor>The Barton Group</vendor>
-        <homepage href="http://www.jalview.org" />
-        <description>Jalview Multiple Alignment Editor</description>
-        <description kind="short">Jalview</description>
-        <icon href="${WebStartImage}" />
-        <offline_allowed />
-      </information>
-      <resources>
-        <j2se version="${j2sev}" initial_heap_size="256M" max_heap_size="1024M" />
-        <fileset dir="${packageDir}">
-          <include name="jalview.jar" />
-        </fileset>
-        <fileset dir="${packageDir}">
-          <include name="*.jar" />
-          <include name="*_*.jar" />
-          <exclude name="jalview.jar" />
-        </fileset>
-        <property name="jalview.version" value="${JALVIEW_VERSION}" />
-      </resources>
-      <application_desc main_class="jalview.bin.Jalview">
-      </application_desc>
-      <security>
-        <all_permissions />
-      </security>
-    </jnlp>
-    <!-- finally, need to postprocess to add in associations at end of 'information' element 
+    <!-- create a dummy jar which will eventually contain the jnlp template -->
+    <jar destfile="${packageDir}/jalview_jnlp_vm.jar" index="true">
+          <fileset dir="${packageDir}">
+            <include name="jalview.jar"/>
+          </fileset>
+    </jar>
+       
+       <mkdir dir="${packageDir}/JNLP-INF"/>
+    <antcall target="writejnlpf">
+       <param name="jnlpFile" value="${packageDir}/JNLP-INF/APPLICATION-TEMPLATE.JNLP"/>
+       <param name="inih" value="*" />
+       <param name="maxh" value="*"/>
+    </antcall>
+               
+       <jar destfile="${packageDir}/jalview_jnlp_vm.jar" index="true">
+             <fileset dir="${packageDir}">
+               <include name="JNLP-INF"/>
+             </fileset>
+       </jar>
+    
+       <antcall target="writejnlpf">
+               <param name="jnlpFile" value="${packageDir}/jalview.jnlp"/>
+               <param name="inih" value="10M" />
+         <param name="maxh" value="256M"/>
+       </antcall>
+       
+       <antcall target="writejnlpf">
+         <param name="jnlpFile" value="${packageDir}/jalview_1G.jnlp"/>
+         <param name="inih" value="128M" />
+               <param name="maxh" value="512M"/>
+       </antcall>
+           
+       <antcall target="writejnlpf">
+         <param name="jnlpFile" value="${packageDir}/jalview_2G.jnlp"/>
+         <param name="inih" value="256M" />
+         <param name="maxh" value="1024M"/>
+       </antcall>
+       
+       <!-- finally, need to postprocess to add in associations at end of 'information' element 
                        
                        <xslt in="${packageDir}/jalview_noa_1G.jnlp" out="${packageDir}/jalview_1G.jnlp">
                
     <!--
                                <association mime-type="application-x/ext-file" extensions="fa"/>
         <association mime-type="application-x/ext-file" extensions="fasta"/>
+        <association mime-type="application-x/ext-file" extensions="mfa"/>
         <association mime-type="application-x/ext-file" extensions="fastq"/>
         <association mime-type="application-x/ext-file" extensions="blc"/>
         <association mime-type="application-x/ext-file" extensions="msf"/>
         <association mime-type="application-x/ext-file" extensions="amsa"/>
         <association mime-type="application-x/ext-file" extensions="stk"/>
         <association mime-type="application-x/ext-file" extensions="jar"/>-->
-
+    <!-- and sign the jars -->
+    <!-- the default keystore details might need to be edited here -->
+    <signjar storepass="${jalview.keystore.pass}" keypass="${jalview.key.pass}" keystore="${jalview.keystore}" alias="${jalview.key}" lazy="false" verbose="false" sigalg="SHA1withRSA">
+        <fileset dir="${packageDir}">
+          <include name="*.jar" />
+        </fileset>
+    </signjar>
   </target>
 
   <target name="runenv" depends="init">
     <echo>java -classpath ${run.classpath} jalview.bin.Jalview
       </echo>
   </target>
-
+  <target name="writejnlpf">
+       <presetdef name="jnlpf">
+           <jnlp codebase="${WebStartLocation}">
+             <information>
+               <title>Jalview</title>
+               <vendor>The Barton Group</vendor>
+               <homepage href="http://www.jalview.org" />
+               <description>Jalview Multiple Alignment Editor</description>
+               <description kind="short">Jalview</description>
+               <icon href="${WebStartImage}" />
+               <offline_allowed />
+             </information>
+             <resources>
+               <j2se version="${j2sev}" initial_heap_size="${inih}" max_heap_size="${maxh}" />
+               <fileset dir="${packageDir}">
+                 <include name="jalview.jar" />
+               </fileset>
+               <fileset dir="${packageDir}">
+                 <include name="*.jar" />
+                 <include name="*_*.jar" />
+                 <exclude name="jalview.jar" />
+               </fileset>
+               <property name="jalview.version" value="${JALVIEW_VERSION}" />
+             </resources>
+             <application_desc main_class="jalview.bin.Jalview">
+             </application_desc>
+             <security>
+               <all_permissions />
+             </security>
+           </jnlp>
+           </presetdef>
+
+           <jnlpf toFile="${jnlpFile}"/>
+  </target>
   <target name="buildextclients" depends="init">
     <input message="Building external client source from WSDLs - Do you really want to do this ? (Yy/Nn)" validargs="Y,y,n,N" defaultvalue="N" addproperty="doextbuild.response" />
     <condition property="dontextbuild">