diff options
author | obache <obache@pkgsrc.org> | 2012-01-06 13:34:50 +0000 |
---|---|---|
committer | obache <obache@pkgsrc.org> | 2012-01-06 13:34:50 +0000 |
commit | de58b52eacde0a6a7a60b98d20eb35036c86c03d (patch) | |
tree | bc7cb18e128d79b9429c85efb573e71e8985068b | |
parent | 8fd9d2c84990cf211b18d9f08e202667bcb37b38 (diff) | |
download | pkgsrc-de58b52eacde0a6a7a60b98d20eb35036c86c03d.tar.gz |
Apply patches to fix SEGV by GC on Ruby 1.9 for Ruby/GLib2.
Bump PKGREVISION.
-rw-r--r-- | devel/ruby-gnome2-glib/Makefile | 3 | ||||
-rw-r--r-- | meta-pkgs/ruby-gnome2/distinfo | 4 | ||||
-rw-r--r-- | meta-pkgs/ruby-gnome2/patches/patch-glib2_ext_glib2_rbgobj__closure.c | 39 |
3 files changed, 43 insertions, 3 deletions
diff --git a/devel/ruby-gnome2-glib/Makefile b/devel/ruby-gnome2-glib/Makefile index b5efa21d5d3..bb0c32e581f 100644 --- a/devel/ruby-gnome2-glib/Makefile +++ b/devel/ruby-gnome2-glib/Makefile @@ -1,7 +1,8 @@ -# $NetBSD: Makefile,v 1.14 2011/06/12 11:43:33 obache Exp $ +# $NetBSD: Makefile,v 1.15 2012/01/06 13:34:51 obache Exp $ # PKGNAME= ${RUBY_PKGPREFIX}-gnome2-glib-${VERSION} +PKGREVISION= 1 COMMENT= Ruby binding of GLib-2.x CATEGORIES= devel diff --git a/meta-pkgs/ruby-gnome2/distinfo b/meta-pkgs/ruby-gnome2/distinfo index 7f7d1ae5b39..34d49f6aaac 100644 --- a/meta-pkgs/ruby-gnome2/distinfo +++ b/meta-pkgs/ruby-gnome2/distinfo @@ -1,6 +1,6 @@ -$NetBSD: distinfo,v 1.24 2011/10/03 14:19:43 obache Exp $ +$NetBSD: distinfo,v 1.25 2012/01/06 13:34:50 obache Exp $ SHA1 (ruby-gnome2-all-1.0.3.tar.gz) = 2a280760e411e443e4e617ca5345a3301fbd609d RMD160 (ruby-gnome2-all-1.0.3.tar.gz) = bac4a901b3c09f548ced80c2a1cfbea482dc0ead Size (ruby-gnome2-all-1.0.3.tar.gz) = 1141565 bytes -SHA1 (patch-vte_ext_vte_depend) = 291fd3d31ec17342fafdc001abe828551eb398a1 +SHA1 (patch-glib2_ext_glib2_rbgobj__closure.c) = ee99d5f3e4ed67bc1965368da0aa314d1fd2cf57 diff --git a/meta-pkgs/ruby-gnome2/patches/patch-glib2_ext_glib2_rbgobj__closure.c b/meta-pkgs/ruby-gnome2/patches/patch-glib2_ext_glib2_rbgobj__closure.c new file mode 100644 index 00000000000..a42e221c7d5 --- /dev/null +++ b/meta-pkgs/ruby-gnome2/patches/patch-glib2_ext_glib2_rbgobj__closure.c @@ -0,0 +1,39 @@ +$NetBSD: patch-glib2_ext_glib2_rbgobj__closure.c,v 1.1 2012/01/06 13:34:50 obache Exp $ + +* fix SEGV by GC on Ruby 1.9. + https://github.com/ruby-gnome2/ruby-gnome2/commit/b5ca012f55017dff95546d331aa87576432fbc32 + https://github.com/ruby-gnome2/ruby-gnome2/commit/7c712c51181edc73d419007a31064321bd14c929 + +--- glib2/ext/glib2/rbgobj_closure.c.orig 2011-09-18 02:48:35.000000000 +0000 ++++ glib2/ext/glib2/rbgobj_closure.c +@@ -148,8 +148,7 @@ rclosure_unref(GRClosure *rclosure) + g_list_free(rclosure->objects); + rclosure->objects = NULL; + if (!NIL_P(rclosure->rb_holder)) { +- RDATA(rclosure->rb_holder)->dmark = NULL; +- RDATA(rclosure->rb_holder)->dfree = NULL; ++ DATA_PTR(rclosure->rb_holder) = NULL; + rclosure->rb_holder = Qnil; + } + } +@@ -178,13 +177,18 @@ rclosure_invalidate(gpointer data, GClos + static void + gr_closure_holder_mark(GRClosure *rclosure) + { +- rb_gc_mark(rclosure->callback); +- rb_gc_mark(rclosure->extra_args); ++ if (rclosure) { ++ rb_gc_mark(rclosure->callback); ++ rb_gc_mark(rclosure->extra_args); ++ } + } + + static void + gr_closure_holder_free(GRClosure *rclosure) + { ++ if (!rclosure) ++ return; ++ + if (rclosure->count > 0) { + rclosure->count = 1; + |