From 17c1f608bfa58caabfeaaebe3688889e20449e43 Mon Sep 17 00:00:00 2001 From: Ben Soares Date: Mon, 17 Dec 2018 10:34:21 +0000 Subject: [PATCH] JAL-3130 Some fixes to ant build xml, and the modules list file creation (to remove trailing newline) so it can be used with module-less AdoptOpenJDK barebones JRE --- build-j11.xml | 6 ++++++ modules | 2 +- utils/jdeps_jlink_all.sh | 4 ++-- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/build-j11.xml b/build-j11.xml index 6ed0b0f..4bc58b4 100755 --- a/build-j11.xml +++ b/build-j11.xml @@ -324,6 +324,9 @@ + + + @@ -332,6 +335,7 @@ + @@ -344,6 +348,7 @@ + @@ -351,6 +356,7 @@ + diff --git a/modules b/modules index 356b1a6..6ab8594 100644 --- a/modules +++ b/modules @@ -1 +1 @@ -com.sun.istack.runtime,com.sun.xml.bind,com.sun.xml.fastinfoset,com.sun.xml.streambuffer,com.sun.xml.txw2,com.sun.xml.ws.policy,java.activation,java.annotation,java.base,java.compiler,java.datatransfer,java.desktop,java.logging,java.management,java.management.rmi,java.naming,java.prefs,java.rmi,java.scripting,java.security.sasl,java.sql,java.xml,java.xml.bind,java.xml.soap,java.xml.ws,javax.jws,jdk.httpserver,jdk.jsobject,jdk.unsupported,jdk.xml.dom,org.jvnet.mimepull,org.jvnet.staxex +com.sun.istack.runtime,com.sun.xml.bind,com.sun.xml.fastinfoset,com.sun.xml.streambuffer,com.sun.xml.txw2,com.sun.xml.ws.policy,java.activation,java.annotation,java.base,java.compiler,java.datatransfer,java.desktop,java.logging,java.management,java.management.rmi,java.naming,java.prefs,java.rmi,java.scripting,java.security.sasl,java.sql,java.xml,java.xml.bind,java.xml.soap,java.xml.ws,javax.jws,jdk.httpserver,jdk.jsobject,jdk.unsupported,jdk.xml.dom,org.jvnet.mimepull,org.jvnet.staxex \ No newline at end of file diff --git a/utils/jdeps_jlink_all.sh b/utils/jdeps_jlink_all.sh index 1474fb1..9f79d2d 100755 --- a/utils/jdeps_jlink_all.sh +++ b/utils/jdeps_jlink_all.sh @@ -10,7 +10,7 @@ # creates file modules.new which is comma-separated list of modules needed, can be used like this in jlink argument # and a java 11 JRE in j11jre/jre-new -( for x in lib/*.jar j11lib/*.jar dist/jalview.jar; do echo $x >&2; jdeps --list-deps --module-path j11lib $x | grep -v Warning: | grep -v "JDK removed" | sed -e 's/^ *//;s/\/.*//;s/$/,/;'; done ) | sort -u | perl -p -e 'chomp;' | sed -e 's/,$//;' > modules.new +( for x in lib/*.jar j11lib/*.jar dist/jalview.jar; do echo $x >&2; jdeps --list-deps --module-path j11lib $x | grep -v Warning: | grep -v "JDK removed" | sed -e 's/^ *//;s/\/.*//;s/$/,/;'; done ) | sort -u | perl -p -e 'chomp;' | perl -p -e 's/,$//;chomp;' > modules.new if [ x$JAVA_HOME != x ]; then jlink --no-header-files --no-man-pages --strip-debug --module-path "$JAVA_HOME/jmods:j11lib" --add-modules `cat modules.new` --compress=2 --output j11jre/jre-new @@ -20,4 +20,4 @@ fi # or if you're in a hurry for a one-liner... -#jlink --no-header-files --no-man-pages --strip-debug --module-path "$JAVA_HOME/jmods:j11lib" --add-modules ` ( for x in lib/*.jar j11lib/*.jar dist/jalview.jar; do echo $x >&2; jdeps --list-deps --module-path j11mod $x | grep -v "Warning:" | grep -v "JDK removed" | sed -e 's/^ *//;s/\/.*//;s/$/,/;'; done ) | sort -u | perl -p -e 'chomp;' | sed -e 's/,$//;' ` --compress=2 --output j11jre/jre-new +#jlink --no-header-files --no-man-pages --strip-debug --module-path "$JAVA_HOME/jmods:j11lib" --add-modules ` ( for x in lib/*.jar j11lib/*.jar dist/jalview.jar; do echo $x >&2; jdeps --list-deps --module-path j11mod $x | grep -v "Warning:" | grep -v "JDK removed" | sed -e 's/^ *//;s/\/.*//;s/$/,/;'; done ) | sort -u | perl -p -e 'chomp;' | perl -p -e 's/,$//;chomp;' ` --compress=2 --output j11jre/jre-new -- 1.7.10.2