make bin/shell.sh aware of JAVA_HOME

this is useful e.g. on monk2 where Java 7 is available but isn't
the default JVM.