git://source.jalview.org
/
jalview.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
17c1f60
)
JAL-3130 java bash wrapper to choose which java to run (if this is first in path...
author
Ben Soares
<bsoares@dundee.ac.uk>
Mon, 17 Dec 2018 10:37:13 +0000
(10:37 +0000)
committer
Ben Soares
<bsoares@dundee.ac.uk>
Mon, 17 Dec 2018 10:37:13 +0000
(10:37 +0000)
j11jre/bin/java
[new file with mode: 0755]
patch
|
blob
diff --git a/j11jre/bin/java
b/j11jre/bin/java
new file mode 100755
(executable)
index 0000000..
1fff2eb
--- /dev/null
+++ b/
j11jre/bin/java
@@ -0,0
+1,17
@@
+#!/usr/bin/env bash
+
+OS=$(uname)
+
+[ -z $JRE_HOME ] && JRE_HOME=$JAVA_HOME
+BASE_DIR=$(dirname ${0})
+BASE_DIR=${BASE_DIR%/bin}
+
+if [ -z $JRE_HOME ]; then
+ case $OS in
+ Darwin) JRE_HOME=$BASE_DIR/openjdk11_macos ;;
+ Linux) JRE_HOME=$BASE_DIR/openjdk11_linux ;;
+ esac
+fi
+
+echo $JRE_HOME/bin/java ${@}
+$JRE_HOME/bin/java ${@}