diff options
author | tnn <tnn> | 2015-02-20 09:38:00 +0000 |
---|---|---|
committer | tnn <tnn> | 2015-02-20 09:38:00 +0000 |
commit | 93e6f4c378991bb27c68e599894cc23dfa28ca00 (patch) | |
tree | 7be56f3ae2449c5261dd0e3cf06c31a5c45b8374 /lang/openjdk8/patches | |
parent | c511f95e5c223ee44b6689cb34a726790537206e (diff) | |
download | pkgsrc-93e6f4c378991bb27c68e599894cc23dfa28ca00.tar.gz |
- Add missing CONFIG_SUB_OVERRIDE
- Run javac compiler in verbose mode so we get some indication of progress
- Fix compile errors when jdk-zero-vm and debug are both enabled
- Fix architecture names for ARM
- Use NetBSD atomic ops implementations on NetBSD/evbarm
- CreateJars.gmk: previous patch expanded to empty command, fix it for real
Diffstat (limited to 'lang/openjdk8/patches')
6 files changed, 101 insertions, 4 deletions
diff --git a/lang/openjdk8/patches/patch-common_autoconf_spec.gmk.in b/lang/openjdk8/patches/patch-common_autoconf_spec.gmk.in index a72a67ae273..f7d10ce8cf0 100644 --- a/lang/openjdk8/patches/patch-common_autoconf_spec.gmk.in +++ b/lang/openjdk8/patches/patch-common_autoconf_spec.gmk.in @@ -1,4 +1,4 @@ -$NetBSD: patch-common_autoconf_spec.gmk.in,v 1.1 2015/02/08 08:41:25 tnn Exp $ +$NetBSD: patch-common_autoconf_spec.gmk.in,v 1.2 2015/02/20 09:38:00 tnn Exp $ --- common/autoconf/spec.gmk.in.orig 2015-02-02 15:31:06.000000000 +0000 +++ common/autoconf/spec.gmk.in @@ -34,7 +34,7 @@ $NetBSD: patch-common_autoconf_spec.gmk.in,v 1.1 2015/02/08 08:41:25 tnn Exp $ # Hotspot sets this variable before reading the SPEC when compiling sa-jdi.jar. Avoid # overriding that value by using ?=. -JAVAC_FLAGS?=@JAVAC_FLAGS@ -+JAVAC_FLAGS?=@JAVAC_FLAGS@ -encoding UTF-8 ++JAVAC_FLAGS?=@JAVAC_FLAGS@ -encoding UTF-8 -verbose -JAVAH=@FIXPATH@ $(BOOT_JDK)/bin/javah +JAVAH=@FIXPATH@ $(BOOT_JDK)/bin/javah $(PKGSRC_BOOT_JDK_TOOLARGS) diff --git a/lang/openjdk8/patches/patch-hotspot_src_cpu_zero_vm_methodHandles__zero.cpp b/lang/openjdk8/patches/patch-hotspot_src_cpu_zero_vm_methodHandles__zero.cpp new file mode 100644 index 00000000000..26e0abbc9ab --- /dev/null +++ b/lang/openjdk8/patches/patch-hotspot_src_cpu_zero_vm_methodHandles__zero.cpp @@ -0,0 +1,16 @@ +$NetBSD: patch-hotspot_src_cpu_zero_vm_methodHandles__zero.cpp,v 1.1 2015/02/20 09:38:00 tnn Exp $ + +Fix zero build w/ debug enabled + +--- hotspot/src/cpu/zero/vm/methodHandles_zero.cpp.orig 2015-02-02 15:32:37.000000000 +0000 ++++ hotspot/src/cpu/zero/vm/methodHandles_zero.cpp +@@ -24,8 +24,8 @@ + */ + + #include "precompiled.hpp" +-#include "interpreter/interpreterGenerator.hpp" + #include "interpreter/interpreter.hpp" ++#include "interpreter/interpreterGenerator.hpp" + #include "memory/allocation.inline.hpp" + #include "prims/methodHandles.hpp" + diff --git a/lang/openjdk8/patches/patch-hotspot_src_cpu_zero_vm_nativeInst__zero.cpp b/lang/openjdk8/patches/patch-hotspot_src_cpu_zero_vm_nativeInst__zero.cpp new file mode 100644 index 00000000000..d9df6bf372a --- /dev/null +++ b/lang/openjdk8/patches/patch-hotspot_src_cpu_zero_vm_nativeInst__zero.cpp @@ -0,0 +1,14 @@ +$NetBSD: patch-hotspot_src_cpu_zero_vm_nativeInst__zero.cpp,v 1.1 2015/02/20 09:38:00 tnn Exp $ + +Fix zero build w/ debug enabled + +--- hotspot/src/cpu/zero/vm/nativeInst_zero.cpp.orig 2015-02-02 15:32:37.000000000 +0000 ++++ hotspot/src/cpu/zero/vm/nativeInst_zero.cpp +@@ -24,6 +24,7 @@ + */ + + #include "precompiled.hpp" ++#include "interpreter/interpreter.hpp" + #include "assembler_zero.inline.hpp" + #include "memory/resourceArea.hpp" + #include "nativeInst_zero.hpp" diff --git a/lang/openjdk8/patches/patch-hotspot_src_os__cpu_bsd__zero_vm_atomic__bsd__zero.inline.hpp b/lang/openjdk8/patches/patch-hotspot_src_os__cpu_bsd__zero_vm_atomic__bsd__zero.inline.hpp new file mode 100644 index 00000000000..f11a702523b --- /dev/null +++ b/lang/openjdk8/patches/patch-hotspot_src_os__cpu_bsd__zero_vm_atomic__bsd__zero.inline.hpp @@ -0,0 +1,47 @@ +$NetBSD: patch-hotspot_src_os__cpu_bsd__zero_vm_atomic__bsd__zero.inline.hpp,v 1.1 2015/02/20 09:38:00 tnn Exp $ + +ARM: Substitute Linux atomic ops with NetBSD atomic ops + +--- hotspot/src/os_cpu/bsd_zero/vm/atomic_bsd_zero.inline.hpp.orig 2015-02-02 15:32:37.000000000 +0000 ++++ hotspot/src/os_cpu/bsd_zero/vm/atomic_bsd_zero.inline.hpp +@@ -112,8 +112,13 @@ static inline int m68k_lock_test_and_set + * + */ + ++#ifdef __NetBSD__ ++#include <sys/atomic.h> ++#define __kernel_cmpxchg(oldval, newval, ptr) ((unsigned int)(oldval) != atomic_cas_uint((volatile unsigned int*)(ptr), (unsigned int)(oldval), (unsigned int)(newval))) ++#else + typedef int (__kernel_cmpxchg_t)(int oldval, int newval, volatile int *ptr); + #define __kernel_cmpxchg (*(__kernel_cmpxchg_t *) 0xffff0fc0) ++#endif + + + +@@ -189,7 +194,7 @@ + + inline intptr_t Atomic::add_ptr(intptr_t add_value, volatile intptr_t* dest) { + #ifdef ARM +- return arm_add_and_fetch(dest, add_value); ++ return arm_add_and_fetch((volatile int*)dest, add_value); + #else + #ifdef M68K + return m68k_add_and_fetch(dest, add_value); +@@ -246,7 +251,7 @@ + inline intptr_t Atomic::xchg_ptr(intptr_t exchange_value, + volatile intptr_t* dest) { + #ifdef ARM +- return arm_lock_test_and_set(dest, exchange_value); ++ return arm_lock_test_and_set((volatile int*)dest, exchange_value); + #else + #ifdef M68K + return m68k_lock_test_and_set(dest, exchange_value); +@@ -286,7 +291,7 @@ + volatile intptr_t* dest, + intptr_t compare_value) { + #ifdef ARM +- return arm_compare_and_swap(dest, compare_value, exchange_value); ++ return arm_compare_and_swap((volatile int*)dest, compare_value, exchange_value); + #else + #ifdef M68K + return m68k_compare_and_swap(dest, compare_value, exchange_value); diff --git a/lang/openjdk8/patches/patch-hotspot_src_os__cpu_bsd__zero_vm_orderAccess__bsd__zero.inline.hpp b/lang/openjdk8/patches/patch-hotspot_src_os__cpu_bsd__zero_vm_orderAccess__bsd__zero.inline.hpp new file mode 100644 index 00000000000..3514e2d3686 --- /dev/null +++ b/lang/openjdk8/patches/patch-hotspot_src_os__cpu_bsd__zero_vm_orderAccess__bsd__zero.inline.hpp @@ -0,0 +1,20 @@ +$NetBSD: patch-hotspot_src_os__cpu_bsd__zero_vm_orderAccess__bsd__zero.inline.hpp,v 1.1 2015/02/20 09:38:00 tnn Exp $ + +ARM: Substitute Linux atomic ops with NetBSD atomic ops + +--- hotspot/src/os_cpu/bsd_zero/vm/orderAccess_bsd_zero.inline.hpp.orig 2015-02-02 15:32:37.000000000 +0000 ++++ hotspot/src/os_cpu/bsd_zero/vm/orderAccess_bsd_zero.inline.hpp +@@ -37,8 +37,13 @@ + * and gcc __sync_synchronize(); implementation does not use the kernel + * helper for all gcc versions so it is unreliable to use as well. + */ ++#ifdef __NetBSD__ ++#include <sys/atomic.h> ++#define __kernel_dmb membar_sync ++#else + typedef void (__kernel_dmb_t) (void); + #define __kernel_dmb (*(__kernel_dmb_t *) 0xffff0fa0) ++#endif + + #define FULL_MEM_BARRIER __kernel_dmb() + #define READ_MEM_BARRIER __kernel_dmb() diff --git a/lang/openjdk8/patches/patch-jdk_make_CreateJars.gmk b/lang/openjdk8/patches/patch-jdk_make_CreateJars.gmk index 1667b7476a2..aa7eabc41ad 100644 --- a/lang/openjdk8/patches/patch-jdk_make_CreateJars.gmk +++ b/lang/openjdk8/patches/patch-jdk_make_CreateJars.gmk @@ -1,4 +1,4 @@ -$NetBSD: patch-jdk_make_CreateJars.gmk,v 1.1 2015/02/12 11:17:17 tnn Exp $ +$NetBSD: patch-jdk_make_CreateJars.gmk,v 1.2 2015/02/20 09:38:00 tnn Exp $ Ensure global tool arguments are used. @@ -9,7 +9,7 @@ Ensure global tool arguments are used. # This is a hack but I don't know how to make this fit into the existing scheme $(PROFILE_VERSION_CLASS_TARGETS): $(PROFILE_VERSION_JAVA_TARGETS) - @$(JAVAC) -d $(@D)/../../ $(@D)/$(VERSION_JAVA_FILE) -+ @$(COMPILE.JAVAC) -d $(@D)/../../ $(@D)/$(VERSION_JAVA_FILE) ++ @$(JAVA) $(NEW_JAVAC) -d $(@D)/../../ $(@D)/$(VERSION_JAVA_FILE) # Support for removing the addPropertyChangeListener and removePropertyChangeListener |