[tomcat8] 01/03: Search for OpenJDK 8 and Oracle JDKs when starting the server
Emmanuel Bourg
ebourg-guest at moszumanska.debian.org
Mon May 26 10:23:48 UTC 2014
This is an automated email from the git hooks/post-receive script.
ebourg-guest pushed a commit to branch master
in repository tomcat8.
commit d6820589c76ec5e9f36a2e76fe829f653e00ec35
Author: Emmanuel Bourg <ebourg at apache.org>
Date: Mon May 26 12:13:35 2014 +0200
Search for OpenJDK 8 and Oracle JDKs when starting the server
---
debian/changelog | 6 ++++++
debian/tomcat8.init | 36 ++++++++++++++++++------------------
2 files changed, 24 insertions(+), 18 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 31ef501..98b942a 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+tomcat8 (8.0.8-2) UNRELEASED; urgency=medium
+
+ * Search for OpenJDK 8 and Oracle JDKs when starting the server
+
+ -- Emmanuel Bourg <ebourg at apache.org> Mon, 26 May 2014 12:13:02 +0200
+
tomcat8 (8.0.8-1) unstable; urgency=medium
* New upstream release
diff --git a/debian/tomcat8.init b/debian/tomcat8.init
index 8617479..774c08a 100644
--- a/debian/tomcat8.init
+++ b/debian/tomcat8.init
@@ -53,32 +53,32 @@ fi
TOMCAT8_USER=tomcat8
TOMCAT8_GROUP=tomcat8
-# this is a work-around until there is a suitable runtime replacement
+# this is a work-around until there is a suitable runtime replacement
# for dpkg-architecture for arch:all packages
-# this function sets the variable OPENJDKS
-find_openjdks()
+# this function sets the variable JDK_DIRS
+find_jdks()
{
- for jvmdir in /usr/lib/jvm/java-8-openjdk-*
+ for java_version in 9 8 7
+ do
+ for jvmdir in /usr/lib/jvm/java-${java_version}-openjdk-* \
+ /usr/lib/jvm/jdk-${java_version}-oracle-* \
+ /usr/lib/jvm/jre-${java_version}-oracle-*
do
- if [ -d "${jvmdir}" -a "${jvmdir}" != "/usr/lib/jvm/java-8-openjdk-common" ]
- then
- OPENJDKS="${OPENJDKS} ${jvmdir}"
- fi
- done
- for jvmdir in /usr/lib/jvm/java-7-openjdk-*
- do
- if [ -d "${jvmdir}" -a "${jvmdir}" != "/usr/lib/jvm/java-7-openjdk-common" ]
- then
- OPENJDKS=$jvmdir
- fi
+ if [ -d "${jvmdir}" ]
+ then
+ JDK_DIRS="${JDK_DIRS} ${jvmdir}"
+ fi
done
+ done
+
+ # Add older non multi arch installations
+ JDK_DIRS="${JDK_DIRS} /usr/lib/jvm/java-7-oracle"
}
-OPENJDKS=""
-find_openjdks
# The first existing directory is used for JAVA_HOME (if JAVA_HOME is not
# defined in $DEFAULT)
-JDK_DIRS="/usr/lib/jvm/default-java ${OPENJDKS} /usr/lib/jvm/java-7-openjdk /usr/lib/jvm/java-7-oracle"
+JDK_DIRS="/usr/lib/jvm/default-java"
+find_jdks
# Look for the right JVM to use
for jdir in $JDK_DIRS; do
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/tomcat8.git
More information about the pkg-java-commits
mailing list