diff options
author | marino <marino> | 2012-11-22 11:02:05 +0000 |
---|---|---|
committer | marino <marino> | 2012-11-22 11:02:05 +0000 |
commit | 4bf10c1ad4e6f80150746827c36408899f4838ae (patch) | |
tree | d22f36b77e8118c37f7b154f989eec3fcb42342a /lang | |
parent | ef0ef1af321e55323b7104c748566d8573951be8 (diff) | |
download | pkgsrc-4bf10c1ad4e6f80150746827c36408899f4838ae.tar.gz |
lang/openjdk7: return NULL, not bool, for pointers
Patches taken from upstream, source listed in patch comments.
Patch replaces return value "false" with "NULL"
Fixes build on gcc 4.7.x
Diffstat (limited to 'lang')
-rw-r--r-- | lang/openjdk7/distinfo | 4 | ||||
-rw-r--r-- | lang/openjdk7/patches/patch-hotspot_src_share_vm_oops_constantPoolOop.cpp | 19 | ||||
-rw-r--r-- | lang/openjdk7/patches/patch-hotspot_src_share_vm_opto_loopnode.cpp | 19 |
3 files changed, 41 insertions, 1 deletions
diff --git a/lang/openjdk7/distinfo b/lang/openjdk7/distinfo index bed4bc6f875..8f8012c9767 100644 --- a/lang/openjdk7/distinfo +++ b/lang/openjdk7/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.19 2012/11/03 20:03:02 joerg Exp $ +$NetBSD: distinfo,v 1.20 2012/11/22 11:02:05 marino Exp $ SHA1 (openjdk7/61e08e67b176.tar.bz2) = 3db5488f3c0ea1b9c83a74632d300d8717c9b478 RMD160 (openjdk7/61e08e67b176.tar.bz2) = c0dd67a6ae982f09b3675c164b5decab4f7e140f @@ -91,3 +91,5 @@ SHA1 (patch-bl) = a3b3bd6007c83664538baf401447fd0df9f4143b SHA1 (patch-bm) = 40c83ad219f529c3ca130547560681ab57b44bf8 SHA1 (patch-bn) = 5b34da35e39e08c935c805b5ef7b2c8cc8d285da SHA1 (patch-hotspot_make_bsd_makefiles_defs.make) = bc339888ede68ada2682b803420a7c9515e5578f +SHA1 (patch-hotspot_src_share_vm_oops_constantPoolOop.cpp) = 1eeca23f0baddf94c369ddd4d4dc91802d7c1e2a +SHA1 (patch-hotspot_src_share_vm_opto_loopnode.cpp) = 05a564d96659d2a2546029bdad49cd718f867a81 diff --git a/lang/openjdk7/patches/patch-hotspot_src_share_vm_oops_constantPoolOop.cpp b/lang/openjdk7/patches/patch-hotspot_src_share_vm_oops_constantPoolOop.cpp new file mode 100644 index 00000000000..bbaf806dcfa --- /dev/null +++ b/lang/openjdk7/patches/patch-hotspot_src_share_vm_oops_constantPoolOop.cpp @@ -0,0 +1,19 @@ +$NetBSD: patch-hotspot_src_share_vm_oops_constantPoolOop.cpp,v 1.1 2012/11/22 11:02:05 marino Exp $ + +Patch taken from upstream: +SUBJ: Don't return booleans from methods returning pointers +http://hg.openjdk.java.net/hsx/hotspot-rt/hotspot/rev/f457154eee8b + +Fixes build on gcc 4.7 + +--- hotspot/src/share/vm/oops/constantPoolOop.cpp.orig 2011-06-27 16:14:04.000000000 +0000 ++++ hotspot/src/share/vm/oops/constantPoolOop.cpp +@@ -269,7 +269,7 @@ klassOop constantPoolOopDesc::klass_ref_ + methodOop constantPoolOopDesc::method_at_if_loaded(constantPoolHandle cpool, + int which, Bytecodes::Code invoke_code) { + assert(!constantPoolCacheOopDesc::is_secondary_index(which), "no indy instruction here"); +- if (cpool->cache() == NULL) return false; // nothing to load yet ++ if (cpool->cache() == NULL) return NULL; // nothing to load yet + int cache_index = which - CPCACHE_INDEX_TAG; + if (!(cache_index >= 0 && cache_index < cpool->cache()->length())) { + if (PrintMiscellaneous && (Verbose||WizardMode)) { diff --git a/lang/openjdk7/patches/patch-hotspot_src_share_vm_opto_loopnode.cpp b/lang/openjdk7/patches/patch-hotspot_src_share_vm_opto_loopnode.cpp new file mode 100644 index 00000000000..9c07c661220 --- /dev/null +++ b/lang/openjdk7/patches/patch-hotspot_src_share_vm_opto_loopnode.cpp @@ -0,0 +1,19 @@ +$NetBSD: patch-hotspot_src_share_vm_opto_loopnode.cpp,v 1.1 2012/11/22 11:02:05 marino Exp $ + +Patch taken from upstream: +SUBJ: Don't return booleans from methods returning pointers +http://hg.openjdk.java.net/hsx/hotspot-rt/hotspot/rev/f457154eee8b + +Fixes build on gcc 4.7 + +--- hotspot/src/share/vm/opto/loopnode.cpp.orig 2011-06-27 16:14:21.000000000 +0000 ++++ hotspot/src/share/vm/opto/loopnode.cpp +@@ -893,7 +893,7 @@ Node *LoopLimitNode::Identity( PhaseTran + Node* CountedLoopNode::match_incr_with_optional_truncation( + Node* expr, Node** trunc1, Node** trunc2, const TypeInt** trunc_type) { + // Quick cutouts: +- if (expr == NULL || expr->req() != 3) return false; ++ if (expr == NULL || expr->req() != 3) return NULL; + + Node *t1 = NULL; + Node *t2 = NULL; |