/hg/icedtea7: 2 new changesets
andrew at icedtea.classpath.org
andrew at icedtea.classpath.org
Mon May 21 11:18:52 PDT 2012
changeset 70bfc9d0aa81 in /hg/icedtea7
details: http://icedtea.classpath.org/hg/icedtea7?cmd=changeset;node=70bfc9d0aa81
author: Andrew John Hughes <ahughes at redhat.com>
date: Mon May 21 18:43:33 2012 +0100
Support kernels that require PaX marking on the JDK binaries.
2012-05-21 Andrew John Hughes <ahughes at redhat.com>
* AUTHORS: Add Ralph Sennhauser.
2012-02-03 Ralph Sennhauser <sera at gentoo.org>
* Makefile.am:
(ICEDTEA_PATCHES): Add test_gamma patch if
WITH_PAX is set.
(ICEDTEA_BOOT_PATCHES): Only add test_gamma patch
if WITH_PAX is not set.
(icedtea): Run pax-mark-vm on the just-built image.
(icedtea-debug): Likewise.
(icedtea-boot): Likewise.
* acinclude.m4:
(IT_WITH_PAX): Check for a pax command being specified.
* configure.ac:
Call IT_WITH_PAX.
* patches/test_gamma.patch:
Patch to be applied for the main OpenJDK tree when
--with-pax is specified. Stops the test_gamma app being
run, which will fail as the JDK is not yet PaX marked.
* pax-mark-vm.in:
Script to PaX mark a JDK image.
changeset a1aed32a081d in /hg/icedtea7
details: http://icedtea.classpath.org/hg/icedtea7?cmd=changeset;node=a1aed32a081d
author: Andrew John Hughes <ahughes at redhat.com>
date: Mon May 21 19:18:12 2012 +0100
Bring in latest fixes.
2012-05-21 Andrew John Hughes <ahughes at redhat.com>
(JDK_CHANGESET): Bump to bring in the
aliasing and wrap mode fixes.
(JDK_SHA256SUM): Likewise.
diffstat:
AUTHORS | 1 +
ChangeLog | 31 +++++++++++++++++++++++++++++++
Makefile.am | 16 +++++++++++++---
acinclude.m4 | 43 +++++++++++++++++++++++++++++++++++++++++++
configure.ac | 3 +++
patches/test_gamma.patch | 47 +++++++++++++++++++++++++++++++++++++++++++++++
pax-mark-vm.in | 13 +++++++++++++
7 files changed, 151 insertions(+), 3 deletions(-)
diffs (255 lines):
diff -r 9db4ba854770 -r a1aed32a081d AUTHORS
--- a/AUTHORS Thu May 03 00:06:07 2012 +0100
+++ b/AUTHORS Mon May 21 19:18:12 2012 +0100
@@ -30,6 +30,7 @@
Bernhard Rosenkränzer <bero at arklinux.org>
Marc Schoenefeld <mschoene at redhat.com>
Keith Seitz <keiths at redhat.com>
+Ralph Sennhauser <sera at gentoo.org>
Joshua Sumali <jsumali at redhat.com>
Pavel Tisnovsky <ptisnovs at redhat.com>
Christian Thalinger <twisti at complang.tuwien.ac.at>
diff -r 9db4ba854770 -r a1aed32a081d ChangeLog
--- a/ChangeLog Thu May 03 00:06:07 2012 +0100
+++ b/ChangeLog Mon May 21 19:18:12 2012 +0100
@@ -1,3 +1,34 @@
+2012-05-21 Andrew John Hughes <ahughes at redhat.com>
+
+ (JDK_CHANGESET): Bump to bring in the
+ aliasing and wrap mode fixes.
+ (JDK_SHA256SUM): Likewise.
+
+2012-05-21 Andrew John Hughes <ahughes at redhat.com>
+
+ * AUTHORS: Add Ralph Sennhauser.
+
+2012-02-03 Ralph Sennhauser <sera at gentoo.org>
+
+ * Makefile.am:
+ (ICEDTEA_PATCHES): Add test_gamma patch if
+ WITH_PAX is set.
+ (ICEDTEA_BOOT_PATCHES): Only add test_gamma patch
+ if WITH_PAX is not set.
+ (icedtea): Run pax-mark-vm on the just-built image.
+ (icedtea-debug): Likewise.
+ (icedtea-boot): Likewise.
+ * acinclude.m4:
+ (IT_WITH_PAX): Check for a pax command being specified.
+ * configure.ac:
+ Call IT_WITH_PAX.
+ * patches/test_gamma.patch:
+ Patch to be applied for the main OpenJDK tree when
+ --with-pax is specified. Stops the test_gamma app being
+ run, which will fail as the JDK is not yet PaX marked.
+ * pax-mark-vm.in:
+ Script to PaX mark a JDK image.
+
2012-05-02 Andrew John Hughes <ahughes at redhat.com>
Bump to jdk7u4 b13.
diff -r 9db4ba854770 -r a1aed32a081d Makefile.am
--- a/Makefile.am Thu May 03 00:06:07 2012 +0100
+++ b/Makefile.am Mon May 21 19:18:12 2012 +0100
@@ -8,7 +8,7 @@
HOTSPOT_CHANGESET = 5be91de8b779
JAXP_CHANGESET = 10808c0ac008
JAXWS_CHANGESET = 06cd92271215
-JDK_CHANGESET = 9b7558b91244
+JDK_CHANGESET = fd327c7e74da
LANGTOOLS_CHANGESET = 8634c8f95ff7
OPENJDK_CHANGESET = 6670fad22684
@@ -16,7 +16,7 @@
HOTSPOT_SHA256SUM = babb11cf54c6299fe2f0730968316958b71a1dd5e7c2d5d698ac7d905bfc2ccc
JAXP_SHA256SUM = a8c600e3419d8586acb3f7f444bea399aac174d58f2127cb4c0a3ffd3cffdd17
JAXWS_SHA256SUM = f896fbc4dd9eeb68015afe0378638fc646b9b08047cf9c382a33542f44454def
-JDK_SHA256SUM = a449701b9957e1993b4795b7825953eb806b5865a12b165cbcaf62887f83504f
+JDK_SHA256SUM = 4697250c0218be75bac9595e0345cff3bfb7a0f5bd0a9cf0544b75483aec9a1a
LANGTOOLS_SHA256SUM = bad80067828740510fe8f7c430dfb90d1ec1c895a93fa56b16d8223a8c757bd3
OPENJDK_SHA256SUM = 5256c8e7c9144ff8a23e83574a82a42874c4c7722057e8194ceb70fe15a5de06
@@ -276,6 +276,10 @@
ICEDTEA_PATCHES += patches/nss-not-enabled-config.patch
endif
+if WITH_PAX
+ICEDTEA_PATCHES += patches/test_gamma.patch
+endif
+
ICEDTEA_PATCHES += $(DISTRIBUTION_PATCHES)
# Bootstrapping patches
@@ -297,7 +301,6 @@
patches/boot/jar.patch \
patches/boot/symbols.patch \
patches/boot/tobin.patch \
- patches/boot/test_gamma.patch \
patches/boot/tools.jar.patch \
patches/boot/jopt.patch \
patches/boot/jaxp-dependency.patch \
@@ -317,6 +320,10 @@
patches/boot/ecj-autoboxing.patch \
patches/boot/xsltproc.patch
+if !WITH_PAX
+ICEDTEA_BOOT_PATCHES += patches/boot/test_gamma.patch
+endif
+
if CP39408_JAVAH
ICEDTEA_BOOT_PATCHES += patches/boot/pr39408.patch
endif
@@ -1643,6 +1650,7 @@
$(ICEDTEA_ENV) \
-C openjdk/ \
$(ICEDTEA_BUILD_TARGET)
+ $(abs_top_builddir)/pax-mark-vm $(BUILD_OUTPUT_DIR)/j2sdk-image
mkdir -p $(BUILD_OUTPUT_DIR)/j2sdk-image/jre/lib/$(INSTALL_ARCH_DIR)
mkdir -p $(BUILD_OUTPUT_DIR)/j2re-image/lib/$(INSTALL_ARCH_DIR)
mkdir -p $(BUILD_OUTPUT_DIR)/j2sdk-image/jre/lib/ext
@@ -1708,6 +1716,7 @@
$(ICEDTEA_ENV) \
-C openjdk/ \
$(ICEDTEA_DEBUG_BUILD_TARGET)
+ $(abs_top_builddir)/pax-mark-vm $(DEBUG_BUILD_OUTPUT_DIR)/j2sdk-image
mkdir -p $(DEBUG_BUILD_OUTPUT_DIR)/j2sdk-image/jre/lib/$(INSTALL_ARCH_DIR)
mkdir -p $(DEBUG_BUILD_OUTPUT_DIR)/j2re-image/lib/$(INSTALL_ARCH_DIR)
mkdir -p $(DEBUG_BUILD_OUTPUT_DIR)/j2sdk-image/jre/lib/ext
@@ -1796,6 +1805,7 @@
$(ICEDTEA_ENV_BOOT) \
-C openjdk-boot \
$(ICEDTEA_BUILD_TARGET)
+ $(abs_top_builddir)/pax-mark-vm $(BOOT_BUILD_OUTPUT_DIR)/j2sdk-image
@echo "Bootstrapped IcedTea is served:" \
$(BOOT_BUILD_OUTPUT_DIR)
mkdir -p stamps
diff -r 9db4ba854770 -r a1aed32a081d acinclude.m4
--- a/acinclude.m4 Thu May 03 00:06:07 2012 +0100
+++ b/acinclude.m4 Mon May 21 19:18:12 2012 +0100
@@ -2201,3 +2201,46 @@
AM_CONDITIONAL([DOWNLOADING], test x"${enable_downloading}" = "xyes")
AC_SUBST([enable_downloading])
])
+
+AC_DEFUN_ONCE([IT_WITH_PAX],
+[
+ AC_MSG_CHECKING([for pax utility to use])
+ AC_ARG_WITH([pax],
+ [AS_HELP_STRING(--with-pax=COMMAND,the command used for pax marking)],
+ [
+ PAX_COMMAND=${withval}
+ ],
+ [
+ PAX_COMMAND="not specified"
+ ])
+ case "x${PAX_COMMAND}" in
+ xchpax)
+ case "${host_cpu}" in
+ i?86)
+ PAX_COMMAND_ARGS="-msp"
+ ;;
+ *)
+ PAX_COMMAND_ARGS="-m"
+ ;;
+ esac
+ ;;
+ xpaxctl)
+ case "${host_cpu}" in
+ i?86)
+ PAX_COMMAND_ARGS="-msp"
+ ;;
+ *)
+ PAX_COMMAND_ARGS="-m"
+ ;;
+ esac
+ ;;
+ *)
+ PAX_COMMAND="not specified"
+ PAX_COMMAND_ARGS="not specified"
+ ;;
+ esac
+ AM_CONDITIONAL(WITH_PAX, test "x${PAX_COMMAND}" != "xnot specified")
+ AC_MSG_RESULT(${PAX_COMMAND})
+ AC_SUBST(PAX_COMMAND)
+ AC_SUBST(PAX_COMMAND_ARGS)
+])
diff -r 9db4ba854770 -r a1aed32a081d configure.ac
--- a/configure.ac Thu May 03 00:06:07 2012 +0100
+++ b/configure.ac Mon May 21 19:18:12 2012 +0100
@@ -147,6 +147,9 @@
IT_ENABLE_HG
IT_WITH_TZDATA_DIR
+IT_WITH_PAX
+AC_CONFIG_FILES([pax-mark-vm], [chmod +x pax-mark-vm])
+
AC_PATH_TOOL([HG],[hg])
if test "x${enable_hg}" = "xyes"; then
if test "x${HG}" = x; then
diff -r 9db4ba854770 -r a1aed32a081d patches/test_gamma.patch
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/test_gamma.patch Mon May 21 19:18:12 2012 +0100
@@ -0,0 +1,47 @@
+diff -Nru ../openjdk.orig/openjdk/hotspot/make/linux/Makefile openjdk/hotspot/make/linux/Makefile
+--- ../openjdk.orig/openjdk/hotspot/make/linux/Makefile 2009-10-30 17:37:07.000000000 +0000
++++ openjdk/hotspot/make/linux/Makefile 2009-10-30 17:45:40.000000000 +0000
+@@ -287,42 +287,36 @@
+
+ $(TARGETS_C2): $(SUBDIRS_C2)
+ cd $(OSNAME)_$(BUILDARCH)_compiler2/$@ && $(MAKE) $(MFLAGS)
+- cd $(OSNAME)_$(BUILDARCH)_compiler2/$@ && ./test_gamma
+ ifdef INSTALL
+ cd $(OSNAME)_$(BUILDARCH)_compiler2/$@ && $(MAKE) $(MFLAGS) install
+ endif
+
+ $(TARGETS_TIERED): $(SUBDIRS_TIERED)
+ cd $(OSNAME)_$(BUILDARCH)_tiered/$(patsubst %tiered,%,$@) && $(MAKE) $(MFLAGS)
+- cd $(OSNAME)_$(BUILDARCH)_tiered/$(patsubst %tiered,%,$@) && ./test_gamma
+ ifdef INSTALL
+ cd $(OSNAME)_$(BUILDARCH)_tiered/$(patsubst %tiered,%,$@) && $(MAKE) $(MFLAGS) install
+ endif
+
+ $(TARGETS_C1): $(SUBDIRS_C1)
+ cd $(OSNAME)_$(BUILDARCH)_compiler1/$(patsubst %1,%,$@) && $(MAKE) $(MFLAGS)
+- cd $(OSNAME)_$(BUILDARCH)_compiler1/$(patsubst %1,%,$@) && ./test_gamma
+ ifdef INSTALL
+ cd $(OSNAME)_$(BUILDARCH)_compiler1/$(patsubst %1,%,$@) && $(MAKE) $(MFLAGS) install
+ endif
+
+ $(TARGETS_CORE): $(SUBDIRS_CORE)
+ cd $(OSNAME)_$(BUILDARCH)_core/$(patsubst %core,%,$@) && $(MAKE) $(MFLAGS)
+- cd $(OSNAME)_$(BUILDARCH)_core/$(patsubst %core,%,$@) && ./test_gamma
+ ifdef INSTALL
+ cd $(OSNAME)_$(BUILDARCH)_core/$(patsubst %core,%,$@) && $(MAKE) $(MFLAGS) install
+ endif
+
+ $(TARGETS_ZERO): $(SUBDIRS_ZERO)
+ cd $(OSNAME)_$(VARIANTARCH)_zero/$(patsubst %zero,%,$@) && $(MAKE) $(MFLAGS)
+- cd $(OSNAME)_$(VARIANTARCH)_zero/$(patsubst %zero,%,$@) && ./test_gamma
+ ifdef INSTALL
+ cd $(OSNAME)_$(VARIANTARCH)_zero/$(patsubst %zero,%,$@) && $(MAKE) $(MFLAGS) install
+ endif
+
+ $(TARGETS_SHARK): $(SUBDIRS_SHARK)
+ cd $(OSNAME)_$(VARIANTARCH)_shark/$(patsubst %shark,%,$@) && $(MAKE) $(MFLAGS)
+- cd $(OSNAME)_$(VARIANTARCH)_shark/$(patsubst %shark,%,$@) && ./test_gamma
+ ifdef INSTALL
+ cd $(OSNAME)_$(VARIANTARCH)_shark/$(patsubst %shark,%,$@) && $(MAKE) $(MFLAGS) install
+ endif
+
diff -r 9db4ba854770 -r a1aed32a081d pax-mark-vm.in
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/pax-mark-vm.in Mon May 21 19:18:12 2012 +0100
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+# Taken from Gentoo's pax-utils.eclass
+list_paxables() {
+ file "$@" 2> /dev/null | grep -E 'ELF.*(executable|shared object)' | sed -e 's/: .*$//'
+}
+
+if test "@PAX_COMMAND@" != "not specified"; then
+ for paxable in `list_paxables "${1}"/bin/* "${1}"/jre/bin/*`; do
+ echo "PaX mark @PAX_COMMAND_ARGS@ ${paxable}"
+ @PAX_COMMAND@ @PAX_COMMAND_ARGS@ "${paxable}"
+ done
+fi
More information about the distro-pkg-dev
mailing list