summaryrefslogtreecommitdiff
path: root/devel
diff options
context:
space:
mode:
authorwiz <wiz@pkgsrc.org>2014-10-29 17:01:09 +0000
committerwiz <wiz@pkgsrc.org>2014-10-29 17:01:09 +0000
commit4d842e95da1d7bb45e3ae8364a80213787bb9058 (patch)
tree38d82236c7fdf01eb1ece4113eded6122bb5b603 /devel
parent124e28b7303ba6aec36f4400cdb1cb305406ecdd (diff)
downloadpkgsrc-4d842e95da1d7bb45e3ae8364a80213787bb9058.tar.gz
Add patch from enami@ resolving issues with link_map chain which
caused problems with guile-2. Bump PKGREVISION.
Diffstat (limited to 'devel')
-rw-r--r--devel/boehm-gc/Makefile3
-rw-r--r--devel/boehm-gc/distinfo3
-rw-r--r--devel/boehm-gc/patches/patch-dyn__load.c33
3 files changed, 37 insertions, 2 deletions
diff --git a/devel/boehm-gc/Makefile b/devel/boehm-gc/Makefile
index 0bbdd6decd7..d2010f61c2a 100644
--- a/devel/boehm-gc/Makefile
+++ b/devel/boehm-gc/Makefile
@@ -1,7 +1,8 @@
-# $NetBSD: Makefile,v 1.78 2014/06/15 14:19:07 wiz Exp $
+# $NetBSD: Makefile,v 1.79 2014/10/29 17:01:09 wiz Exp $
DISTNAME= gc-7.4.2
PKGNAME= ${DISTNAME:S/gc/boehm-gc/}
+PKGREVISION= 1
CATEGORIES= devel
MASTER_SITES= http://www.hboehm.info/gc/gc_source/
diff --git a/devel/boehm-gc/distinfo b/devel/boehm-gc/distinfo
index 6430f62bb0c..8e8a345f938 100644
--- a/devel/boehm-gc/distinfo
+++ b/devel/boehm-gc/distinfo
@@ -1,5 +1,6 @@
-$NetBSD: distinfo,v 1.51 2014/06/15 14:19:07 wiz Exp $
+$NetBSD: distinfo,v 1.52 2014/10/29 17:01:09 wiz Exp $
SHA1 (gc-7.4.2.tar.gz) = cd4a54620c38a2c361b3ee99dd134dbffb57c313
RMD160 (gc-7.4.2.tar.gz) = 106bda88d4e47c32f5ba4137c82fa173313d09a9
Size (gc-7.4.2.tar.gz) = 1082597 bytes
+SHA1 (patch-dyn__load.c) = cd224eb9e31deba2f5a29f3202d8ef130e8fdaae
diff --git a/devel/boehm-gc/patches/patch-dyn__load.c b/devel/boehm-gc/patches/patch-dyn__load.c
new file mode 100644
index 00000000000..2bbe97fde67
--- /dev/null
+++ b/devel/boehm-gc/patches/patch-dyn__load.c
@@ -0,0 +1,33 @@
+$NetBSD: patch-dyn__load.c,v 1.1 2014/10/29 17:01:09 wiz Exp $
+
+Current GC_FirstDLOpenedLinkMap() for NetBSD calls dlinfo(RTLD_SELF,
+RTLD_DI_LINKMAP, &lm) to find link_map. So it will find link_map of
+libgc.
+
+With guile's case, libgc is link to libguile and libguile is linked to
+the guile command, so libgc is not the first one in the link_map chain.
+
+That's why, data section of libguile, where scm_protects exists, isn't
+added to GC root and GC_is_visible fails.
+
+--- dyn_load.c.orig 2014-06-03 06:08:02.000000000 +0000
++++ dyn_load.c
+@@ -687,8 +687,16 @@ GC_FirstDLOpenedLinkMap(void)
+ if( cachedResult == 0 ) {
+ # if defined(NETBSD) && defined(RTLD_DI_LINKMAP)
+ struct link_map *lm = NULL;
+- if (!dlinfo(RTLD_SELF, RTLD_DI_LINKMAP, &lm))
+- cachedResult = lm;
++ if (!dlinfo(RTLD_SELF, RTLD_DI_LINKMAP, &lm) && lm != NULL) {
++ /*
++ * Now, lm points link_map object of libgc. Since it
++ * might not be the first dynamically linked object,
++ * try to find it (object next to the main object).
++ */
++ while (lm->l_prev)
++ lm = lm->l_prev;
++ cachedResult = lm->l_next;
++ }
+ # else
+ int tag;
+ for( dp = _DYNAMIC; (tag = dp->d_tag) != 0; dp++ ) {