-if [ "x$javadir" = x ]; then
- fail "could not find java runtime system
- please check that $yppdir/java points to your Java installation"
+javadir="${yppjava#/bin/java}"
+if [ -x "$javadir/jre/bin/java" ]; then
+ echo " java/ points to the jre, good"
+else
+ echo " java/ has just the executable bin/java, trying readlink"
+ absjava=`readlink -f "$yppjava"`
+ echo " abs. java: \"$absjava\""
+ case "$absjava" in
+ */jre/bin/java)
+ echo " found jre directory, good"
+ javadir="${absjava%/jre/bin/java}"
+ ;;
+ *)
+ nojre "java binary not in jre dir"
+ ;;
+ esac