summaryrefslogtreecommitdiff
path: root/user/java-common/java-common.trigger
diff options
context:
space:
mode:
Diffstat (limited to 'user/java-common/java-common.trigger')
-rw-r--r--user/java-common/java-common.trigger13
1 files changed, 13 insertions, 0 deletions
diff --git a/user/java-common/java-common.trigger b/user/java-common/java-common.trigger
new file mode 100644
index 000000000..6d0613d48
--- /dev/null
+++ b/user/java-common/java-common.trigger
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+if [ -x /usr/lib/jvm/forced-jvm ]; then
+ ln -sfn forced-jvm default-jvm
+ exit 0
+fi
+
+cd /usr/lib/jvm
+LATEST=`ls -d java-* | sort -r | head -1`
+if [ "$LATEST" ]; then
+ ln -sfn $LATEST default-jvm
+fi
+