+2019-07-01 (pre 2.11.0 release)
+Notes below are out of date, but might be useful for future development with Java 11
+
+Presently the Java 11 build of Jalview treats all libraries as libraries on the classpath, and does not use them as modules. The Java 11 JRE prepped for future release is a standard AdoptOpenJDK release (possibly repackaged for getdown/install4j to use).
+
+At time of writing, the JRE cannot be updated over the air on macOS platform due to a limitation of getdown's unpackaging system only using jars and hence cannot work with symbolic links. There is a symbolic link that is essential (as a symbolic link) in the macOS distribution (Contents/MacOS/libjli.dylib -> ../Home/lib/jli/libjli.dylib). Without this, the install4j launcher will not work. Some work has started on incorporating tar capabilities in getdown using the apache-commons-compress library, though this is not complete.
+
+Future releases might incorporate Java 11 modules into a bespoke Java 11 JRE that can be updated over the air via getdown.This could reduce the size of the distribution but will absolutely need the bespoke JRE. This would mean Jalview being restricted to platforms that we (can) support, or distributing the modules as libraries in a second distribution (the shadowJar distribution).
+
+build.gradle is written to support compilation of either Java 1.8 or Java 11 compatible bytecode. Please note that the compilation (and therefore build) process REQUIRES a Java 11 (or above) JDK. This is because there is Java 11 specific code in some Jalview classes (devolved into separate classes which fail "gracefully" when read by a Java 1.8 JRE).
+Java 11 is therefore the default build target, but can be changed simply by specifying the property JAVA_VERSION=1.8 (e.g.
+
+gradle compileJava -PJAVA_VERSION=1.8
+
+). Some different versions of supporting libraries are used between Java 1.8 and 11 builds, and can be found in j8lib and j11lib folders respectively. Note that there are a number of extra libraries used in the Java 11 distribution which are present in the Java 1.8 JRE but not distributed with the Java 11 JRE.
+
+Also see doc/building.md or doc/building.html
+
+
+
+
+Old notes:
+
Java 11 module replacements
As Java 11 no longer ships with Java EE libraries, which were standard in Java 8, and available (modularised, through the --add-modules CLI mechanism) in Java 9 and 10, third party replacement libraries for these libraries/modules have to be found.
To create a Java 11 JRE in j11jre/openjdk11_platform (or whatever you wish to call it).
You can point JAVA_HOME at the JDK11 of a different platform, so long as the jlink in your path is to the jlink for the platform you're running on.
-
Licensing information for each library is given below:
-JGoogleAnalytics_0.3.jar APL 2.0 License - http://code.google.com/p/jgoogleanalytics/
-Jmol-14.6.4_2016.10.26.jar GPL/LGPLv2 http://sourceforge.net/projects/jmol/files/
-VARNAv3-93.jar GPL licenced software by K�vin Darty, Alain Denise and Yann Ponty. http://varna.lri.fr
+j8lib:
+
activation.jar
apache-mime4j-0.6.jar
axis.jar
-castor-1.1-cycle-xml.jar
+biojava-core-4.1.0.jar LGPLv2.1 - latest license at https://github.com/biojava/biojava/blob/master/LICENSE
+biojava-ontology-4.1.0.jar LGPLv2.1 - latest license at https://github.com/biojava/biojava/blob/master/LICENSE
commons-codec-1.3.jar
-commons-discovery.jar
+commons-compress-1.18.jar
commons-logging-1.1.1.jar
-commons-logging.jar
-commons-net-3.3.jar
-groovy-all-2.4.6-indy.jar APL 2.0 License - downloaded and extracted from https://dl.bintray.com/groovy/maven/apache-groovy-binary-2.4.6.zip
+getdown-core.jar Getdown license - https://github.com/threerings/getdown/blob/master/LICENSE
+groovy-all-2.4.12-indy.jar APL 2.0 License - downloaded and extracted from https://dl.bintray.com/groovy/maven/apache-groovy-binary-2.4.6.zip
+htsjdk-2.12.0.jar built from maven master at https://github.com/samtools/htsjdk MIT License to Broad Institute
httpclient-4.0.3.jar
httpcore-4.0.1.jar
httpmime-4.0.3.jar
+intervalstore-v1.0.jar
+jabaws-min-client-2.2.0.jar
+java-json.jar
jaxrpc.jar
+jersey-client-1.19.4.jar CDDL 1.1 + GPL2 w/ CPE - http://glassfish.java.net/public/CDDL+GPL_1_1.html
+jersey-core-1.19.4.jar CDDL 1.1 + GPL2 w/ CPE - http://glassfish.java.net/public/CDDL+GPL_1_1.html
+jersey-json-1.19.4.jar CDDL 1.1 + GPL2 w/ CPE - http://glassfish.java.net/public/CDDL+GPL_1_1.html
+jetty-http-9.2.10.v20150310.jar
+jetty-io-9.2.10.v20150310.jar
+jetty-server-9.2.10.v20150310.jar
+jetty-util-9.2.10.v20150310.jar
+jfreesvg-2.1.jar GPL v3 licensed library from the JFree suite - http://www.jfree.org/jfreesvg/
+JGoogleAnalytics_0.3.jar APL 2.0 License - http://code.google.com/p/jgoogleanalytics/
jhall.jar
-jswingreader-0.3.jar : Apache license - built from http://jswingreader.sourceforge.net/ svn/trunk v12
+Jmol-14.6.4_2016.10.26.jar GPL/LGPLv2 http://sourceforge.net/projects/jmol/files/
+json_simple-1.1.jar Apache 2.0 license - downloaded from https://code.google.com/p/json-simple/downloads/list (will move to 1.1.1 version when jalview is mavenised and osgi-ised)
+jsoup-1.8.1.jar
+jsr311-api-1.1.1.jar
+jswingreader-0.3.jar Apache license - built from http://jswingreader.sourceforge.net/ svn/trunk v12
+libquaqua64-8.0.jnilib.jar quaqua: v.8.0 (latest stable) by Randel S Hofer. LGPL and BSD Modified license: downloaded from http://www.randelshofer.ch/quaqua/
+libquaqua-8.0.jnilib.jar quaqua: v.8.0 (latest stable) by Randel S Hofer. LGPL and BSD Modified license: downloaded from http://www.randelshofer.ch/quaqua/
log4j-1.2.8.jar
mail.jar
-miglayout-4.0-swing.jar BSD http://www.migcalendar.com/miglayout/versions/4.0/license.txt
-min-jaba-client.jar
+miglayout-4.0-swing.jar BSD - http://www.migcalendar.com/miglayout/versions/4.0/license.txt
+quaqua-filechooser-only-8.0.jar quaqua: v.8.0 (latest stable) by Randel S Hofer. LGPL and BSD Modified license: downloaded from http://www.randelshofer.ch/quaqua/
regex.jar
saaj.jar
+servlet-api-3.1.jar
+slf4j-api-1.7.7.jar
+slf4j-log4j12-1.7.7.jar
vamsas-client.jar
+VAqua5-patch.jar This is a patched version of VAqua v5 (latest stable) by Alan Snyder et al. GPLv3 with Classpath exception, also includes contributions from Quaqua: http://violetlib.org/vaqua/overview.html - see doc/patching-vaqua.txt for patch details, and http://issues.jalview.org/browse/JAL-2988 for details of the bug that the patch addresses.
+VARNAv3-93.jar GPL licenced software by K�vin Darty, Alain Denise and Yann Ponty - http://varna.lri.fr
wsdl4j.jar
xercesImpl.jar
xml-apis.jar
-json_simple-1.1.jar : Apache 2.0 license : downloaded from https://code.google.com/p/json-simple/downloads/list (will move to 1.1.1 version when jalview is mavenised and osgi-ised)
-jfreesvg-2.1.jar : GPL v3 licensed library from the JFree suite: http://www.jfree.org/jfreesvg/
-
-quaqua: v.8.0 (latest stable) by Randel S Hofer. LGPL and BSD Modified license: downloaded from http://www.randelshofer.ch/quaqua/
-
-vaqua5-patch: This is a patched version of VAqua v5 (latest stable) by Alan Snyder et al. GPLv3 with Classpath exception, also includes contributions from Quaqua: http://violetlib.org/vaqua/overview.html - see doc/patching-vaqua.txt for patch details, and http://issues.jalview.org/browse/JAL-2988 for details of the bug that the patch addresses.
-
-lib/htsjdk-2.12.jar: built from maven master at https://github.com/samtools/htsjdk MIT License to Broad Institute
-
-lib/biojava-core-4.1.0.jar LGPLv2.1 - latest license at https://github.com/biojava/biojava/blob/master/LICENSE
-
-lib/biojava-ontology-4.1.0.jar LGPLv2.1 - latest license at https://github.com/biojava/biojava/blob/master/LICENSE
Libraries for Test Suite
-utils/classgraph-4.1.6.jar: BSD License - allows recovery of classpath for programmatic construction of a Java command line to launch Jalview
- version 4.1.6 downloaded from https://mvnrepository.com/artifact/io.github.classgraph/classgraph/4.1.6
+utils/axis-ant.jar
+utils/ant-contrib-1.0b3.jar
+utils/hamcrest-core-1.3.jar
+utils/roxes-ant-tasks-1.2-2004-01-30.jar
+utils/proguard_5.3.3.jar
+utils/jhindexer.jar
+utils/junit-4.12.jar
+utils/jhall.jar
+utils/classgraph-4.1.6.jar BSD License - allows recovery of classpath for programmatic construction of a Java command line to launch Jalview version 4.1.6 downloaded from https://mvnrepository.com/artifact/io.github.classgraph/classgraph/4.1.6
+utils/testnglibs/guava-base-r03.jar
+utils/testnglibs/guava-collections-r03.jar
+utils/testnglibs/bsh-2.0b4.jar
+utils/testnglibs/snakeyaml.jar
+utils/testnglibs/testng-sources.jar
+utils/testnglibs/testng.jar
+utils/testnglibs/junit-4.12.jar
+utils/testnglibs/jcommander.jar
+utils/wsdl4j.jar
Additional dependencies
examples/javascript/jshashtable-2.1.js : Apache License
examples/javascript/facebox-1.3.js : MTI License - http://www.opensource.org/licenses/mit-license.php
+
+New in j11lib:
+
+FastInfoset.jar CDDL Version 1.1 - https://javaee.github.io/metro-fi/LICENSE
+getdown-core.jar Getdown license - https://github.com/threerings/getdown/blob/master/LICENSE
+groovy-*2.5.7.jar Apache License, Version 2.0 - http://www.apache.org/licenses/LICENSE-2.0.html
+istack-commons-runtime.jar CDDL Version 1.1 - https://glassfish.java.net/public/CDDL+GPL_1_1.html
+javax.activation-api-1.2.0.jar CDDL/GPLv2+CE - https://github.com/javaee/activation/blob/master/LICENSE.txt
+javax.annotation-api-1.3.2.jar CDDL + GPLv2 with classpath exception - https://github.com/javaee/javax.annotation/blob/master/LICENSE
+javax.jws-api-1.1.jar CDDL + GPLv2 with classpath exception - https://glassfish.dev.java.net/nonav/public/CDDL+GPL.html
+javax.servlet-api-4.0.1.jar CDDL + GPLv2 with classpath exception - https://oss.oracle.com/licenses/CDDL+GPL-1.1
+javax.xml.rpc-api-1.1.2.jar CDDL + GPLv2 with classpath exception - https://oss.oracle.com/licenses/CDDL+GPL-1.1
+javax.xml.soap-api.jar CDDL + GPLv2 with classpath exception - https://github.com/javaee/javax.xml.soap/blob/master/LICENSE
+jaxb-api-2.3.1.jar CDDL 1.1 + GPL2 w/ CPE - https://oss.oracle.com/licenses/CDDL+GPL-1.1
+jaxb-runtime-2.3.2.jar Eclipse Distribution License - v 1.0 - http://www.eclipse.org/org/documents/edl-v10.php
+jaxws-api-2.3.1.jar CDDL + GPLv2 with classpath exception - https://github.com/javaee/jax-ws-spec/blob/master/LICENSE.md
+Jmol-14.6.4_2016.10.26-no_netscape.jar GPL/LGPLv2 http://sourceforge.net/projects/jmol/files/
+jsr311-api-1.1.1.jar CDDL License - http://www.opensource.org/licenses/cddl1.php
+mimepull-1.9.11.jar Eclipse Distribution License - v 1.0 - http://www.eclipse.org/org/documents/edl-v10.php
+policy-2.7.6.jar Eclipse Distribution License - v 1.0 - http://www.eclipse.org/org/documents/edl-v10.php
+slf4j-api-1.7.26.jar MIT License - https://opensource.org/licenses/mit-license.php
+slf4j-log4j12-1.7.26.jar MIT License - https://opensource.org/licenses/mit-license.php
+stax-ex-1.8.1.jar Eclipse Distribution License - v 1.0 - http://www.eclipse.org/org/documents/edl-v10.php
+stax2-api-4.2.jar The BSD License - http://www.opensource.org/licenses/bsd-license.php
+streambuffer-1.5.7.jar Eclipse Distribution License - v 1.0 - http://www.eclipse.org/org/documents/edl-v10.php
+txw2-2.3.2.jar Eclipse Distribution License - v 1.0 - http://www.eclipse.org/org/documents/edl-v10.php
+wsdl4j-1.6.3.jar CPL - http://www.opensource.org/licenses/cpl1.0.txt
+
getdownLauncher = jalviewDir + '/' + getdown_launcher
getdownFilesDir = jalviewDir + '/' + getdown_files_dir + '/' + JAVA_VERSION + '/'
getdownFilesInstallDir = getdownFilesDir+"/"+getdown_install_dir
+ /* compile without modules -- using classpath libraries
modules_compileClasspath = fileTree(dir: "$jalviewDir/$j11modDir", include: ["*.jar"])
modules_runtimeClasspath = modules_compileClasspath
+ */
gitHash = ""
gitBranch = ""
}
getdown_alt_java_max_version = getdown_alt_java11_max_version
getdown_alt_multi_java_location = getdown_alt_java11_txt_multi_java_location
eclipse_java_runtime_name = "JavaSE-11"
+ /* compile without modules -- using classpath libraries
additional_compiler_args += [
'--module-path', ext.modules_compileClasspath.asPath,
'--add-modules', j11modules
]
+ */
} else if (JAVA_VERSION.equals("12") || JAVA_VERSION.equals("13")) {
JAVA_INTEGER_VERSION = JAVA_VERSION
libDir = j11libDir
getdown_alt_java_max_version = getdown_alt_java11_max_version
getdown_alt_multi_java_location = getdown_alt_java11_txt_multi_java_location
eclipse_java_runtime_name = "JavaSE-11"
+ /* compile without modules -- using classpath libraries
additional_compiler_args += [
'--module-path', ext.modules_compileClasspath.asPath,
'--add-modules', j11modules
]
+ */
} else {
throw new GradleException("JAVA_VERSION=$JAVA_VERSION not currently supported by Jalview")
}
outputs.file(helplinkscheckertouchfile)
}
+// import the pubhtmlhelp target
+ant.properties.basedir = "$jalviewDir"
+ant.properties.helpBuildDir = jalviewDirAbsolutePath+"/$classes/$helpDir"
+ant.importBuild "$utilsDir/publishHelp.xml"
+
+
task cleanPackageDir(type: Delete) {
delete fileTree("$jalviewDir/$packageDir").include("*.jar")
}
delete install4jConf
}
+task sourceDist (type: Tar) {
+
+ def VERSION_UNDERSCORES = JALVIEW_VERSION.replaceAll("\\.", "_")
+ archiveFileName = project.name + "_" + VERSION_UNDERSCORES + ".tar.gz"
+
+ compression Compression.GZIP
+
+ from jalviewDir
+ into project.name
+
+
+ exclude (".*")
+ exclude ("**/.*")
+ exclude ("*.class")
+ exclude ("**/*.class")
+ include (eclipse_extra_jdt_prefs_file)
+ include ("AUTHORS")
+ include ("CITATION")
+ include ("FEATURETODO")
+ include ("JAVA-11-README")
+ include ("FEATURETODO")
+ include ("LICENSE")
+ include ("README")
+ include ("RELEASE")
+ include ("THIRDPARTYLIBS")
+ include ("build.gradle")
+ include ("gradle.properties")
+ include ("$sourceDir/*.java")
+ include ("$sourceDir/**/*.java")
+ include ("$sourceDir/**/*.cdr")
+ include ("$j8libDir/**/*.jar")
+ include ("$j11libDir/**/*.jar")
+ include ("$resourceDir/**/*")
+ include ("$helpDir/**/*")
+ include ("$schemaDir/**/*")
+ include ("$utilsDir/**/*")
+ include ("$docDir/**/*")
+ include ("$examplesDir/**/*")
+ include ("getdown/**/*")
+ //include ("jalview-jalopy.xml")
+ //include ("JalviewApplet.jpx")
+ //include ("JalviewX.jpx")
+ //include ("nbbuild.xml")
+ //include ("nbproject/genfiles.properties")
+ //include ("nbproject/project.properties")
+ //include ("nbproject/project.xml")
+
+ exclude ("appletlib")
+ exclude ("**/*locales")
+ exclude ("*locales/**")
+ exclude ("utils/InstallAnywhere")
+ exclude (libDir)
+ exclude (getdown_files_dir)
+ exclude (getdown_website_dir)
+
+ // exluding these as not using jars as modules yet
+ exclude ("$j11modDir/**/*.jar")
+
+}
+
+task helppages {
+ dependsOn copyHelp
+ dependsOn pubhtmlhelp
+
+ inputs.dir("$classes/$helpDir")
+ outputs.file("build/distribution/help/helpTOC.html")
+}
--- /dev/null
+## this command gets a list of jars in j11lib/ that are not present or different content in lib/. The output is below.
+#for y in j11lib/*.jar; do x=${y##*/}; if [ \! -e ./lib/$x ] || ! diff ./lib/$x $y; then echo $y; fi; done
+#
+j11lib/FastInfoset.jar
+j11lib/getdown-core.jar
+j11lib/groovy-2.5.7.jar
+j11lib/groovy-ant-2.5.7.jar
+j11lib/groovy-bsf-2.5.7.jar
+j11lib/groovy-cli-commons-2.5.7.jar
+j11lib/groovy-cli-picocli-2.5.7.jar
+j11lib/groovy-console-2.5.7.jar
+j11lib/groovy-datetime-2.5.7.jar
+j11lib/groovy-dateutil-2.5.7.jar
+j11lib/groovy-docgenerator-2.5.7.jar
+j11lib/groovy-groovydoc-2.5.7.jar
+j11lib/groovy-groovysh-2.5.7.jar
+j11lib/groovy-jaxb-2.5.7.jar
+j11lib/groovy-jmx-2.5.7.jar
+j11lib/groovy-json-2.5.7.jar
+j11lib/groovy-json-direct-2.5.7.jar
+j11lib/groovy-jsr223-2.5.7.jar
+j11lib/groovy-macro-2.5.7.jar
+j11lib/groovy-nio-2.5.7.jar
+j11lib/groovy-servlet-2.5.7.jar
+j11lib/groovy-sql-2.5.7.jar
+j11lib/groovy-swing-2.5.7.jar
+j11lib/groovy-templates-2.5.7.jar
+j11lib/groovy-test-2.5.7.jar
+j11lib/groovy-test-junit5-2.5.7.jar
+j11lib/groovy-testng-2.5.7.jar
+j11lib/groovy-xml-2.5.7.jar
+j11lib/istack-commons-runtime.jar
+j11lib/javax.activation-MODULE.jar
+j11lib/javax.annotation-api-MODULE.jar
+j11lib/javax.jws-api-1.1.jar
+j11lib/javax.servlet-api-MODULE.jar
+j11lib/javax.xml.rpc-api-1.1.2.jar
+j11lib/javax.xml.soap-api.jar
+j11lib/jaxb-api-java9.jar
+j11lib/jaxb-runtime.jar
+j11lib/jaxws-api.jar
+j11lib/jersey-client-1.19.1.jar
+j11lib/jersey-core-1.19.1.jar
+j11lib/jersey-json-1.19.1.jar
+j11lib/jsr311-api-1.1.1.jar
+j11lib/mimepull.jar
+j11lib/policy.jar
+j11lib/stax-ex.jar
+j11lib/stax2-api-MODULE.jar
+j11lib/streambuffer.jar
+j11lib/txw2.jar
+j11lib/wsdl4j-MODULE.jar
These normally take around 5 - 10 minutes to complete and outputs its full results into
the `tests/` folder. A summary of results should appear in your console.
+You can run different defined groups of tests with
+
+```bash
+gradle test -PtestngGroups=Network
+```
+
+Available groups are Functional (default), Network, External.
+
### Installer packaging with *install4j*
---
-[Jalview Development Team](mailto:help@jalview.org)
\ No newline at end of file
+[Jalview Development Team](mailto:help@jalview.org)
resourceDir = resources
helpParentDir = help
helpDir = help
+helpOutputDir = build/distribution/help
docDir = doc
sourceDir = src
schemaDir = schemas
classesDir = classes
+examplesDir = examples
clover = false
use_clover = false
cloverClassesDir = clover-classes
--- /dev/null
+<project name="Publish Help Webpages for Jalview" default="pubhtmlhelp">
+
+<target name="pubhtmlhelp">
+ <property name="appletHelpDir" value="../build/distribution/help"/>
+ <!-- finally, publish the help files -->
+ <javac srcdir="." destdir="." includes="help2Website.java"/>
+ <java fork="true" dir="${helpBuildDir}" classpath="." classname="help2Website"/>
+ <delete dir="${appletHelpDir}"/>
+ <copy preservelastmodified="true" overwrite="true"
+ todir="${appletHelpDir}">
+ <fileset dir="${helpBuildDir}">
+ <include name="*htm*"/>
+ <include name="icons/**.*"/>
+ <include name="html/**/*.*"/>
+ <exclude name="**/CVS"/>
+ <exclude name="CVS"/>
+ </fileset>
+ </copy>
+ <replace dir="${appletHelpDir}">
+ <include name="**/*.htm*"/>
+ <replacetoken><![CDATA[</body>]]></replacetoken>
+ <replacevalue><![CDATA[
+<script type="text/javascript">
+ var gaJsHost = (("https:" == document.location.protocol) ?
+ "https://ssl." : "http://www.");
+ document.write(unescape("%3Cscript src=\'" + gaJsHost +
+ "google-analytics.com/ga.js\' type=\'text/javascript\'%3E%3C/script%3E"));
+</script>
+<script type="text/javascript">
+try{
+ var pageTracker = _gat._getTracker("'UA-9060947-1'");
+ pageTracker._trackPageview();
+} catch(err) {}
+</script>
+</body>
+]]></replacevalue>
+</replace>
+<echo file="${appletHelpDir}/help.html">
+<![CDATA[<html><head>
+<title>Jalview Documentation</title>
+</head>
+<frameset cols="300,*">
+<frame src="helpTOC.html" name=tocframe scrolling=yes >
+<frame src="html/index.html" name=bodyframe >
+<noframes><body>
+This page requires a browser that supports frames.
+<script type="text/javascript">
+ var gaJsHost = (("https:" == document.location.protocol) ?
+ "https://ssl." : "http://www.");
+ document.write(unescape("%3Cscript src=\'" + gaJsHost +
+ "google-analytics.com/ga.js\' type=\'text/javascript\'%3E%3C/script%3E"));
+</script>
+<script type="text/javascript">
+try{
+ var pageTracker = _gat._getTracker("'UA-9060947-1'");
+ pageTracker._trackPageview();
+} catch(err) {}
+</script></body>
+<noframes></frameset>
+</html>
+]]></echo>
+
+ </target>
+</project>