Code

Fallback to /usr/lib/jvm if JAVA_HOME is not set
authorRuben Kerkhof <ruben@tilaa.nl>
Sun, 18 Nov 2012 10:38:24 +0000 (11:38 +0100)
committerMarc Fournier <marc.fournier@camptocamp.com>
Tue, 28 Apr 2015 05:38:35 +0000 (07:38 +0200)
This makes the java plugin build out of the box
on systems with a JDK installed.
/usr/lib/jvm is the default location for the JDK
on at least Fedora, Red Hat and Debian.

configure.in

index 877ac449146f0645d72b64f5b86ce796535971a0..bc431fec12170fbfabd252cbd5fc2b202f7c464e 100644 (file)
@@ -2004,6 +2004,10 @@ fi
 
 # --with-java {{{
 with_java_home="$JAVA_HOME"
+if test "x$with_java_home" = "x"
+then
+       with_java_home="/usr/lib/jvm"
+fi
 with_java_vmtype="client"
 with_java_cflags=""
 with_java_libs=""