diff options
author | Joe Marcus Clarke <marcus@FreeBSD.org> | 2002-11-11 19:50:48 +0000 |
---|---|---|
committer | Joe Marcus Clarke <marcus@FreeBSD.org> | 2002-11-11 19:50:48 +0000 |
commit | 156030da7284e767b20cae7d0cd9116bbac22743 (patch) | |
tree | 85766f1d8ca301feaa6df8579f45bc598279bc1d /x11-toolkits/py-gtk2 | |
parent | Chase the shared lib versions of gal and gtkhtml. (diff) |
* Fix a crash in pygtk_generic_cell_renderer_get_size(). [1]
* Add an option to enable or disable pthread support.
PR: 45150
Submitted by: Marc Recht <marc@informatik.uni-bremen.de>
Obtained from: pygtk CVS [1]
Notes
Notes:
svn path=/head/; revision=69922
Diffstat (limited to 'x11-toolkits/py-gtk2')
-rw-r--r-- | x11-toolkits/py-gtk2/Makefile | 14 | ||||
-rw-r--r-- | x11-toolkits/py-gtk2/files/patch-ltmain.sh | 19 | ||||
-rw-r--r-- | x11-toolkits/py-gtk2/files/patch-pygtkcellrenderer.c | 38 |
3 files changed, 71 insertions, 0 deletions
diff --git a/x11-toolkits/py-gtk2/Makefile b/x11-toolkits/py-gtk2/Makefile index 5df66d0ee0de..1b1fb14ee3ac 100644 --- a/x11-toolkits/py-gtk2/Makefile +++ b/x11-toolkits/py-gtk2/Makefile @@ -6,6 +6,7 @@ PORTNAME= gtk PORTVERSION= 1.99.13 +PORTREVISION= 1 CATEGORIES= x11-toolkits python MASTER_SITES= ${MASTER_SITE_GNOME} MASTER_SITE_SUBDIR= sources/pygtk/1.99 @@ -29,6 +30,19 @@ USE_LIBTOOL= yes EG_SRC_DIR= ${WRKSRC}/examples EG_DST_DIR= ${PREFIX}/share/examples/py-gtk +# +# Use the same way as the Python port to determine if we want +# threading support. +# +LIBC_R!= /sbin/ldconfig -r | grep c_r || true +.if (${LIBC_R} != "") && !defined(WITHOUT_THREADS) +CONFIGURE_ARGS+= --enable-thread +CFLAGS+= ${PTHREAD_CFLAGS} +CONFIGURE_ENV+= LDFLAGS="${PTHREAD_LIBS} ${LDFLAGS}" +.else +CONFIGURE_ARGS+= --disable-thread +.endif + .if !defined(BATCH) && !defined(PACKAGE_BUILDING) pre-build: @${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL diff --git a/x11-toolkits/py-gtk2/files/patch-ltmain.sh b/x11-toolkits/py-gtk2/files/patch-ltmain.sh new file mode 100644 index 000000000000..1eb4ba921278 --- /dev/null +++ b/x11-toolkits/py-gtk2/files/patch-ltmain.sh @@ -0,0 +1,19 @@ +--- ltmain.sh.orig Mon May 27 06:33:15 2002 ++++ ltmain.sh Fri Nov 8 20:57:04 2002 +@@ -1073,8 +1073,16 @@ + continue + ;; + ++ -pthread) ++ compile_command="$compile_command -pthread" ++ finalize_command="$finalize_command -pthread" ++ compiler_flags="$compiler_flags -pthread" ++ continue ++ ;; ++ + -module) + module=yes ++ build_old_libs=no + continue + ;; + diff --git a/x11-toolkits/py-gtk2/files/patch-pygtkcellrenderer.c b/x11-toolkits/py-gtk2/files/patch-pygtkcellrenderer.c new file mode 100644 index 000000000000..d2d2460207e6 --- /dev/null +++ b/x11-toolkits/py-gtk2/files/patch-pygtkcellrenderer.c @@ -0,0 +1,38 @@ +--- ./gtk/pygtkcellrenderer.c.orig Sat Jul 20 07:37:29 2002 ++++ ./gtk/pygtkcellrenderer.c Fri Nov 8 21:01:20 2002 +@@ -94,6 +94,7 @@ + gint *height) + { + PyObject *self, *py_ret, *py_widget, *py_cell_area; ++ gint my_x, my_y, my_width, my_height; + + g_return_if_fail(PYGTK_IS_GENERIC_CELL_RENDERER (cell)); + +@@ -117,13 +118,26 @@ + Py_DECREF(py_widget); + Py_DECREF(py_cell_area); + +- if (!PyArg_ParseTuple(py_ret, "iiii", x_offset, y_offset, width, height)) { ++ if (!PyArg_ParseTuple(py_ret, "iiii", ++ &my_x, &my_y, &my_width, &my_height)) { + PyErr_Clear(); + Py_DECREF(py_ret); + g_warning("could not parse return value of get_size() method. " + "Should be of form (x_offset, y_offset, width, height)"); + return; + } ++ ++ if (x_offset) ++ *x_offset = my_x; ++ ++ if (y_offset) ++ *y_offset = my_y; ++ ++ if (width) ++ *width = my_width; ++ ++ if (height) ++ *height = my_height; + /* success */ + } + |