[icedtea-web-1.0] RFC: Add configure output for jre tree detection

Dr Andrew John Hughes ahughes at redhat.com
Tue Feb 1 13:07:24 PST 2011


This is just a simple patch to make the configure additions from Deepak's
previous jre detection addition print some output.

2010-02-01  Andrew John Hughes  <ahughes at redhat.com>

	* configure.ac: Call IT_CHECK_JRE_PREFIX macro
	rather than doing so inline.
	* acinclude.m4
	(IT_CHECK_JRE_PREFIX): Additions from configure.ac
	supplemented with configure output
	(AC_MSG_CHECKING/AC_MSG_RESULT).

Ok for 1.0?
-- 
Andrew :)

Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)

Support Free Java!
Contribute to GNU Classpath and IcedTea
http://www.gnu.org/software/classpath
http://icedtea.classpath.org
PGP Key: 94EFD9D8 (http://subkeys.pgp.net)
Fingerprint = F8EF F1EA 401E 2E60 15FA  7927 142C 2591 94EF D9D8
-------------- next part --------------
diff -r 3bd328e4b515 acinclude.m4
--- a/acinclude.m4	Tue Feb 01 10:53:44 2011 -0500
+++ b/acinclude.m4	Tue Feb 01 21:05:52 2011 +0000
@@ -667,3 +667,16 @@
 fi
 AC_PROVIDE([$0])dnl
 ])
+
+AC_DEFUN_ONCE([IT_CHECK_JRE_PREFIX],[
+# Set JRE prefix based on whether top-level prefix is a JDK dir or a JRE dir
+AC_MSG_CHECKING([whether the chosen prefix contains a jre tree])
+if test -d ${prefix}/jre ; then 
+    JRE_DIR_PREFIX="/jre";
+    AC_MSG_RESULT([yes])
+else
+    JRE_DIR_PREFIX="";
+    AC_MSG_RESULT([no])
+fi ;
+AC_SUBST([JRE_DIR_PREFIX])
+])
diff -r 3bd328e4b515 configure.ac
--- a/configure.ac	Tue Feb 01 10:53:44 2011 -0500
+++ b/configure.ac	Tue Feb 01 21:05:52 2011 +0000
@@ -38,6 +38,7 @@
 IT_GET_PKGVERSION
 IT_OBTAIN_HG_REVISIONS
 IT_CHECK_XULRUNNER_VERSION
+IT_CHECK_JRE_PREFIX
 
 AC_CHECK_LIB(z, main,, [AC_MSG_ERROR("zlib not found - try installing zlib-devel")])
 dnl Check for libX11 headers and libraries.
@@ -78,12 +79,4 @@
 IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef])
 IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE
 
-# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir
-if test -d ${prefix}/jre ; then 
-    JRE_DIR_PREFIX="/jre" ; 
-else
-    JRE_DIR_PREFIX="" ;     
-fi ;
-AC_SUBST([JRE_DIR_PREFIX])
-
 AC_OUTPUT


More information about the distro-pkg-dev mailing list