diff options
author | Omair Majid <[email protected]> | 2011-08-23 10:57:14 -0400 |
---|---|---|
committer | Omair Majid <[email protected]> | 2011-08-23 10:57:14 -0400 |
commit | 84f70c56f4ac150983ac6fda996f140e88be30ae (patch) | |
tree | ddba3c8cfc38adb88f101c434ba2922d19259291 | |
parent | ca57a77f66bbca5e2be1da83868ba0b5daab0ca3 (diff) |
Allow icedtea-web to run with just a JRE
2011-08-23 Omair Majid <[email protected]>
* Makefile.am: Remove JRE. Replace uses with SYSTEM_JRE_DIR instead. Also
replace uses of SYSTEM_JDK_DIR/jre with SYSTEM_JRE_DIR.
* acinclude.m4
(IT_CHECK_FOR_JRE): New macro.
(IT_FIND_JAVA): Require IT_CHECK_FOR_JRE. Use java binary from within the
JRE.
-rw-r--r-- | ChangeLog | 9 | ||||
-rw-r--r-- | Makefile.am | 13 | ||||
-rw-r--r-- | acinclude.m4 | 29 |
3 files changed, 43 insertions, 8 deletions
@@ -1,3 +1,12 @@ +2011-08-23 Omair Majid <[email protected]> + + * Makefile.am: Remove JRE. Replace uses with SYSTEM_JRE_DIR instead. Also + replace uses of SYSTEM_JDK_DIR/jre with SYSTEM_JRE_DIR. + * acinclude.m4 + (IT_CHECK_FOR_JRE): New macro. + (IT_FIND_JAVA): Require IT_CHECK_FOR_JRE. Use java binary from within the + JRE. + 2011-08-22 Saad Mohammad <[email protected]> * netx/net/sourceforge/jnlp/JNLPFile.java: (parse): After the file has been parsed, it calls diff --git a/Makefile.am b/Makefile.am index bd9e841..9b8b1d9 100644 --- a/Makefile.am +++ b/Makefile.am @@ -51,7 +51,6 @@ IT_JAVACFLAGS=$(IT_JAVAC_SETTINGS) -source $(IT_LANGUAGE_SOURCE_VERSION) -target # IllegalAccessException # - we want full privileges # -JRE='"$(SYSTEM_JDK_DIR)/jre"' LAUNCHER_BOOTCLASSPATH="-Xbootclasspath/a:$(datadir)/$(PACKAGE_NAME)/netx.jar$(RHINO_RUNTIME)" PLUGIN_BOOTCLASSPATH='"-Xbootclasspath/a:$(datadir)/$(PACKAGE_NAME)/netx.jar:$(datadir)/$(PACKAGE_NAME)/plugin.jar$(RHINO_RUNTIME)"' @@ -128,7 +127,7 @@ edit_launcher_script = sed \ -e 's|[@]JAVAWS_BIN_LOCATION[@]|$(bindir)/$(javaws)|g' \ -e 's|[@]ITWEB_SETTINGS_BIN_LOCATION[@]|$(bindir)/$(itweb_settings)|g' \ -e 's|[@]JAVA[@]|$(JAVA)|g' \ - -e 's|[@]JRE[@]|$(JRE)|g' + -e 's|[@]JRE[@]|$(SYSTEM_JRE_DIR)|g' # Top-Level Targets # ================= @@ -216,7 +215,7 @@ $(PLUGIN_DIR)/%.o: $(PLUGIN_SRCDIR)/%.cc -DPLUGIN_VERSION="\"$(PLUGIN_VERSION)\"" \ -DPACKAGE_URL="\"$(PACKAGE_URL)\"" \ -DMOZILLA_VERSION_COLLAPSED="$(MOZILLA_VERSION_COLLAPSED)" \ - -DICEDTEA_WEB_JRE=$(JRE) \ + -DICEDTEA_WEB_JRE="\"$(SYSTEM_JRE_DIR)\"" \ -DPLUGIN_BOOTCLASSPATH=$(PLUGIN_BOOTCLASSPATH) \ $(GLIB_CFLAGS) \ $(GTK_CFLAGS) \ @@ -636,13 +635,13 @@ stamps/bootstrap-directory.stamp: stamps/native-ecj.stamp ln -sf $(abs_top_builddir)/javac $(BOOT_DIR)/bin/javac ln -sf $(JAVADOC) $(BOOT_DIR)/bin/javadoc mkdir -p $(BOOT_DIR)/jre/lib && \ - ln -s $(SYSTEM_JDK_DIR)/jre/lib/rt.jar $(BOOT_DIR)/jre/lib && \ - if [ -e $(SYSTEM_JDK_DIR)/jre/lib/jsse.jar ] ; then \ - ln -s $(SYSTEM_JDK_DIR)/jre/lib/jsse.jar $(BOOT_DIR)/jre/lib ; \ + ln -s $(SYSTEM_JRE_DIR)/lib/rt.jar $(BOOT_DIR)/jre/lib && \ + if [ -e $(SYSTEM_JRE_DIR)/lib/jsse.jar ] ; then \ + ln -s $(SYSTEM_JRE_DIR)/lib/jsse.jar $(BOOT_DIR)/jre/lib ; \ else \ ln -s rt.jar $(BOOT_DIR)/jre/lib/jsse.jar ; \ fi - ln -sf $(SYSTEM_JDK_DIR)/jre/lib/$(JRE_ARCH_DIR) \ + ln -sf $(SYSTEM_JRE_DIR)/lib/$(JRE_ARCH_DIR) \ $(BOOT_DIR)/jre/lib/ && \ if ! test -d $(BOOT_DIR)/jre/lib/$(INSTALL_ARCH_DIR); \ then \ diff --git a/acinclude.m4 b/acinclude.m4 index 3c3803b..c5b9f4c 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -64,6 +64,32 @@ AC_DEFUN_ONCE([IT_CHECK_FOR_JDK], AC_SUBST(SYSTEM_JDK_DIR) ]) +AC_DEFUN_ONCE([IT_CHECK_FOR_JRE], +[ + AC_REQUIRE([IT_CHECK_FOR_JDK]) + AC_MSG_CHECKING([for a JRE home directory]) + AC_ARG_WITH([jre-home], + [AS_HELP_STRING([--with-jre-home], + [jre home directory \ + (default is the JRE under the JDK)])], + [ + SYSTEM_JRE_DIR=${withval} + ], + [ + SYSTEM_JRE_DIR= + ]) + if test -z "${SYSTEM_JRE_DIR}" ; then + if test -d "${SYSTEM_JDK_DIR}/jre" ; then + SYSTEM_JRE_DIR="${SYSTEM_JDK_DIR}/jre" + fi + fi + AC_MSG_RESULT(${SYSTEM_JRE_DIR}) + if ! test -d "${SYSTEM_JRE_DIR}"; then + AC_MSG_ERROR("A JRE home directory could not be found.") + fi + AC_SUBST(SYSTEM_JRE_DIR) +]) + AC_DEFUN_ONCE([FIND_JAVAC], [ AC_REQUIRE([IT_CHECK_FOR_JDK]) @@ -592,6 +618,7 @@ AC_DEFUN([IT_SET_ARCH_SETTINGS], AC_DEFUN_ONCE([IT_FIND_JAVA], [ + AC_REQUIRE([IT_CHECK_FOR_JRE]) AC_MSG_CHECKING([for a Java virtual machine]) AC_ARG_WITH([java], [AS_HELP_STRING(--with-java,specify location of the 1.5 java vm)], @@ -599,7 +626,7 @@ AC_DEFUN_ONCE([IT_FIND_JAVA], JAVA="${withval}" ], [ - JAVA=${SYSTEM_JDK_DIR}/bin/java + JAVA="${SYSTEM_JRE_DIR}/bin/java" ]) if ! test -f "${JAVA}"; then AC_PATH_PROG(JAVA, "${JAVA}") |