changeset 2583:9f42ba0226e1

PR1137: Allow JARs to be optionally compressed by setting COMPRESS_JARS 2012-08-22 Andrew John Hughes <gnu_andrew@member.fsf.org> PR1137: Allow JARs to be optionally compressed by setting COMPRESS_JARS * Makefile.am: (ICEDTEA_ENV): Add COMPRESS_JARS="true" if ENABLE_JAR_COMPRESSION is set. * NEWS: Updated. * acinclude.m4: Add IT_ENABLE_JAR_COMPRESSION macro. * configure.ac: Include new macro.
author Andrew John Hughes <gnu_andrew@member.fsf.org>
date Wed, 22 Aug 2012 23:30:06 +0100
parents 000df05fbd54
children 7c4551c5d837
files ChangeLog Makefile.am NEWS acinclude.m4 configure.ac
diffstat 5 files changed, 43 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Wed Aug 22 21:21:57 2012 +0100
+++ b/ChangeLog	Wed Aug 22 23:30:06 2012 +0100
@@ -1,5 +1,17 @@
-2012-08-16  Andrew John Hughes  <gnu_andrew@member.fsf.org>
-
+2012-08-22  Andrew John Hughes  <gnu_andrew@member.fsf.org>
+
+	PR1137: Allow JARs to be optionally compressed by
+	setting COMPRESS_JARS
+	* Makefile.am:
+	(ICEDTEA_ENV): Add COMPRESS_JARS="true" if
+	ENABLE_JAR_COMPRESSION is set.
+	* NEWS: Updated.
+	* acinclude.m4: Add IT_ENABLE_JAR_COMPRESSION macro.
+	* configure.ac: Include new macro.
+
+2012-08-22  Andrew John Hughes  <gnu_andrew@member.fsf.org>
+
+	PR1095: Add configure option for -Werror
 	* Makefile.am:
 	(ICEDTEA_PATCHES): Add -Werror patches
 	from IcedTea7 HEAD.  Drop ecj-opts patch
--- a/Makefile.am	Wed Aug 22 21:21:57 2012 +0100
+++ b/Makefile.am	Wed Aug 22 23:30:06 2012 +0100
@@ -573,6 +573,11 @@
 	COMPILE_AGAINST_SYSCALLS="true"
 endif
 
+if ENABLE_JAR_COMPRESSION
+ICEDTEA_ENV += \
+	COMPRESS_JARS="true"
+endif
+
 # OpenJDK boot build environment.
 ICEDTEA_ENV_BOOT = $(ICEDTEA_ENV) \
 	BOOTCLASSPATH_CLS_RT="-bootclasspath $(CLS_DIR_BOOT):$(RUNTIME)" \
--- a/NEWS	Wed Aug 22 21:21:57 2012 +0100
+++ b/NEWS	Wed Aug 22 23:30:06 2012 +0100
@@ -19,6 +19,7 @@
   - PR1119: Only add classes to rt-source-files.txt if the class (or one or more of its methods/fields)
     are actually missing from the boot JDK
   - PR1095: Add configure option for -Werror
+  - PR1137: Allow JARs to be optionally compressed by setting COMPRESS_JARS
 * JamVM
   - ARMv6 armhf: Changes for Raspbian (Raspberry Pi)
   - PPC: Don't use lwsync if it isn't supported
--- a/acinclude.m4	Wed Aug 22 21:21:57 2012 +0100
+++ b/acinclude.m4	Wed Aug 22 23:30:06 2012 +0100
@@ -2378,3 +2378,25 @@
   AC_MSG_RESULT([$enable_werror])
   AM_CONDITIONAL([ENABLE_WERROR], test x"${enable_werror}" = "xyes")
 ])
+
+AC_DEFUN([IT_ENABLE_JAR_COMPRESSION],
+[
+  AC_MSG_CHECKING([whether to enable JAR compression])
+  AC_ARG_ENABLE([jar-compression],
+                [AS_HELP_STRING(--enable-jar-compression,compress built jars [[default=yes]])],
+  [
+    case "${enableval}" in
+      no)
+        enable_jar_compression=no
+        ;;
+      *)
+        enable_jar_compression=yes
+        ;;
+    esac
+  ],
+  [
+    enable_jar_compression=yes
+  ])
+  AC_MSG_RESULT([$enable_jar_compression])
+  AM_CONDITIONAL([ENABLE_JAR_COMPRESSION], test x"${enable_jar_compression}" = "xyes")
+])
--- a/configure.ac	Wed Aug 22 21:21:57 2012 +0100
+++ b/configure.ac	Wed Aug 22 23:30:06 2012 +0100
@@ -153,6 +153,7 @@
 
 IT_DISABLE_OPTIMIZATIONS
 IT_ENABLE_WERROR
+IT_ENABLE_JAR_COMPRESSION
 IT_SET_SHARK_BUILD
 IT_ENABLE_ZERO_BUILD
 IT_CHECK_ADDITIONAL_VMS