summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dev-python/pygobject/ChangeLog7
-rw-r--r--dev-python/pygobject/Manifest11
-rw-r--r--dev-python/pygobject/files/pygobject-2.26.0-disabled-threads.patch81
-rw-r--r--dev-python/pygobject/pygobject-2.26.0-r1.ebuild10
4 files changed, 100 insertions, 9 deletions
diff --git a/dev-python/pygobject/ChangeLog b/dev-python/pygobject/ChangeLog
index e4588d2a12b3..25f9cda1eb5e 100644
--- a/dev-python/pygobject/ChangeLog
+++ b/dev-python/pygobject/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for dev-python/pygobject
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-python/pygobject/ChangeLog,v 1.107 2011/01/27 19:05:25 pacho Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-python/pygobject/ChangeLog,v 1.108 2011/01/28 19:39:18 pacho Exp $
+
+ 28 Jan 2011; Pacho Ramos <pacho@gentoo.org> pygobject-2.26.0-r1.ebuild,
+ +files/pygobject-2.26.0-disabled-threads.patch:
+ Fix building without threads and dependency on python (thanks a lot to
+ Arfrever Frehtes Taifersar Arahesis for his help).
27 Jan 2011; Pacho Ramos <pacho@gentoo.org> pygobject-2.26.0-r1.ebuild:
dev-python/pygobject always needs python with threads support as reported by
diff --git a/dev-python/pygobject/Manifest b/dev-python/pygobject/Manifest
index 15bbbf103e69..5bd81e5881bb 100644
--- a/dev-python/pygobject/Manifest
+++ b/dev-python/pygobject/Manifest
@@ -9,6 +9,7 @@ AUX pygobject-2.20.0-automagic-introspection.patch 867 RMD160 13c58bcba041b93fa1
AUX pygobject-2.20.0-tmpdir-makefile.patch 1817 RMD160 6e2032012f65a74ed140f777e0e7d5addfbc5c1f SHA1 ea47d992fed96f2cea63543232cc3b9ed9e160a9 SHA256 88245480666f05f302a6abd3ef52d8e3a581a2842774f52a484a02d2ea389699
AUX pygobject-2.21.4-make_check.patch 1694 RMD160 d9485a3ae24b1d68cdc7ce46276617554d0ae856 SHA1 a5be94fe784317d057bfcfdc6f2ef51196b4af95 SHA256 431af0993c2c03c043fd6f1b48b74e9bb84de302af88ea6dc9f0eb85397fcbde
AUX pygobject-2.26.0-disable-non-working-tests.patch 6372 RMD160 c2c0a4503a57c8ebb7406a2a382761216b3c82b9 SHA1 d9042ea99b13c0552c45735375f32d2a6acb45a8 SHA256 7441538523a626bd0ea436dfd46a12e7caa83cffa1d1ddc14ac3190be331ad35
+AUX pygobject-2.26.0-disabled-threads.patch 2173 RMD160 a331157022bfe29bd41b40440d89498401bd5832 SHA1 1d4a2ef7c7455cf370e9d1e6d74abe4ab6fd03a9 SHA256 cdac5ca2a9f88748d7d3bb704d93881b6267d2578cdf50129309668bce54c909
AUX pygobject-2.26.0-make_check.patch 2392 RMD160 b1b396b1504bca96982718ea23400cf19d431ba1 SHA1 42dd409d977ba90d615fec8b89d3a92e17ad0c1f SHA256 60ef6e56bebcd33e61dcf90586cc115303181c0e5b72ba19579e4104aa7d6e79
AUX pygobject-2.26.0-nocrash.patch 460 RMD160 ac94453bbb5d1782ba690f313e041e0c65172b41 SHA1 471cc171e72ce6192632cd0865f910c1d7d23495 SHA256 15456f8d2a1d21beb1c201ca12b988fc9009fda88a33c35e2d90c57e519dfbd3
DIST pygobject-2.20.0.tar.bz2 666287 RMD160 5e3a8c976b3047b0dd9c492c8344ccd0ca77d3fd SHA1 a5954262051f376983bef6cc0e3fd1b0ca1824f7 SHA256 41e923a3f4426a3e19f6d154c424e3dac6f39defca77af602ac6272ce270fa81
@@ -17,14 +18,14 @@ DIST pygobject-2.26.0.tar.bz2 808427 RMD160 dd164d29232509f729fe7f766b18d1985eca
EBUILD pygobject-2.20.0-r1.ebuild 3322 RMD160 8923310f87a64912bc703acea596a3a97388ebe5 SHA1 9d904bbf6bce792aee4aa5ed9c8142ef98fed05f SHA256 20d266ac0a973272a989e7e31c15b938f47d3a6e1849f985feae437ecbb4be91
EBUILD pygobject-2.20.0.ebuild 3249 RMD160 2be4c5b7bd333eb6b09def3d44d19c43fba03498 SHA1 5e95d5c4bf7abf160cbc19387ec03081a4d05052 SHA256 07ba4beb90b6adb6c07ba1e590003a7f9fde11a0f219ba06b8da0e8aa665c340
EBUILD pygobject-2.21.5.ebuild 3381 RMD160 57fc789714323d07753a54a68ca0bd5e349a4212 SHA1 9947575b7cac884b8d02f0b7845e19c13a69efa7 SHA256 af843b08c7d3483b8b967e5adcc7867aa5d1d94c89ce5373066183cca37ec7aa
-EBUILD pygobject-2.26.0-r1.ebuild 3723 RMD160 eba87b180cd45bd354bf6c2d9c5709c856f79359 SHA1 a68a5ff1b879e39c25610c9ab56e5684e8f3d21c SHA256 ca92ed113156f5892474d19a8477dbc78a7bf75b27e69c0b25ef70975cf1dd24
+EBUILD pygobject-2.26.0-r1.ebuild 3837 RMD160 507036d7d0430ba27e55b024fc8512a7ec3de89c SHA1 f16059f885beb323f087cedefd97b0f0dfbcb67e SHA256 cdb4853e828f09a2feb1a9e5fa1ed7a382598169508ed2acb6058db51294258f
EBUILD pygobject-2.26.0.ebuild 3422 RMD160 7ad7046dc98cec41b74b0ff6b76cdfdd6f48016a SHA1 c1528500a4087e43cbf21eac450571147bbeede2 SHA256 c7f599545d7bc6ab1308d31e67c015e6450a75fd20da18ae1dcf2d67c4c487e3
-MISC ChangeLog 16046 RMD160 2dfab39ef23c56cc546f560c782ac65430b7c8ce SHA1 3e66907edf9dba1cd6c31fddf6e1a1dcdb422e37 SHA256 cc70c7b72a368b020360404588559081a9f36030c410ce3f9270721a61387121
+MISC ChangeLog 16297 RMD160 213430476df60477bae1a0994fbe9663047e5dba SHA1 2764e28d699527332e82c9601d02e01913847fd0 SHA256 3e65b6395b3c474648e814143b9efe071c5d15a6408e201cff4b5c7eda73fbc1
MISC metadata.xml 382 RMD160 6b39793f627fa71b2e71979d910f944dec3d2c07 SHA1 cc1fb99567697670ace85665a1a45a90bcd6d23d SHA256 9dc0bee05a8cffd8bdd29bc2b30a1aebe7ac319af5afdac9618f26a9943f14e5
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.16 (GNU/Linux)
-iEYEARECAAYFAk1BwfsACgkQCaWpQKGI+9RF1ACcCZhmX3Uln57LUkDVUDeNCF01
-jGUAnRanlPnAM8RJYXFgepGcJ1ILvWnE
-=Nn8q
+iEYEARECAAYFAk1DG2wACgkQCaWpQKGI+9TJWwCfXI4Q4JjX4cEmgvIDWiYN8Ym+
+lLkAoIN3PtT+FYDaNQMmHg4a5MRjDykr
+=V962
-----END PGP SIGNATURE-----
diff --git a/dev-python/pygobject/files/pygobject-2.26.0-disabled-threads.patch b/dev-python/pygobject/files/pygobject-2.26.0-disabled-threads.patch
new file mode 100644
index 000000000000..e9f3a4e09c54
--- /dev/null
+++ b/dev-python/pygobject/files/pygobject-2.26.0-disabled-threads.patch
@@ -0,0 +1,81 @@
+From a4b210d69c832629894090b7154ae194209b0c60 Mon Sep 17 00:00:00 2001
+From: Arnaud Charlet <charlet@adacore.com>
+Date: Tue, 18 Jan 2011 17:31:29 +0000
+Subject: Disable calls to PyGILState_* when threads are disabled
+
+Since threads may also be disabled in Python too, those symbols may not
+be resolved.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=374603
+---
+diff --git a/glib/pyglib.c b/glib/pyglib.c
+index 8163e88..1e024c2 100644
+--- a/glib/pyglib.c
++++ b/glib/pyglib.c
+@@ -94,7 +94,11 @@ pyglib_gil_state_ensure(void)
+ if (!_PyGLib_API->threads_enabled)
+ return PyGILState_LOCKED;
+
++#ifdef DISABLE_THREADING
++ return PyGILState_LOCKED;
++#else
+ return PyGILState_Ensure();
++#endif
+ }
+
+ void
+@@ -105,7 +109,9 @@ pyglib_gil_state_release(PyGILState_STATE state)
+ if (!_PyGLib_API->threads_enabled)
+ return;
+
++#ifndef DISABLE_THREADING
+ PyGILState_Release(state);
++#endif
+ }
+
+ /**
+@@ -171,13 +177,19 @@ _pyglib_notify_on_enabling_threads(PyGLibThreadsEnabledFunc callback)
+ int
+ pyglib_gil_state_ensure_py23 (void)
+ {
++#ifdef DISABLE_THREADING
++ return 0;
++#else
+ return PyGILState_Ensure();
++#endif
+ }
+
+ void
+ pyglib_gil_state_release_py23 (int flag)
+ {
++#ifndef DISABLE_THREADING
+ PyGILState_Release(flag);
++#endif
+ }
+
+ /**
+diff --git a/gobject/pygobject-private.h b/gobject/pygobject-private.h
+index ae4cfe1..a928cb1 100644
+--- a/gobject/pygobject-private.h
++++ b/gobject/pygobject-private.h
+@@ -32,12 +32,18 @@ extern struct _PyGObject_Functions pygobject_api_functions;
+
+ #define pyg_threads_enabled (pygobject_api_functions.threads_enabled)
+
++#ifdef DISABLE_THREADING
++#define pyg_gil_state_ensure() 0
++#define pyg_gil_state_release(state) G_STMT_START { \
++ } G_STMT_END
+
++#else
+ #define pyg_gil_state_ensure() (pygobject_api_functions.threads_enabled? (PyGILState_Ensure()) : 0)
+ #define pyg_gil_state_release(state) G_STMT_START { \
+ if (pygobject_api_functions.threads_enabled) \
+ PyGILState_Release(state); \
+ } G_STMT_END
++#endif
+
+ #define pyg_begin_allow_threads \
+ G_STMT_START { \
+--
+cgit v0.8.3.1
diff --git a/dev-python/pygobject/pygobject-2.26.0-r1.ebuild b/dev-python/pygobject/pygobject-2.26.0-r1.ebuild
index 8b26ff5b1030..3bdeed882783 100644
--- a/dev-python/pygobject/pygobject-2.26.0-r1.ebuild
+++ b/dev-python/pygobject/pygobject-2.26.0-r1.ebuild
@@ -1,13 +1,13 @@
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-python/pygobject/pygobject-2.26.0-r1.ebuild,v 1.4 2011/01/27 19:05:25 pacho Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-python/pygobject/pygobject-2.26.0-r1.ebuild,v 1.5 2011/01/28 19:39:18 pacho Exp $
EAPI="2"
GCONF_DEBUG="no"
SUPPORT_PYTHON_ABIS="1"
PYTHON_DEPEND="2:2.5"
RESTRICT_PYTHON_ABIS="2.4 3.* *-jython"
-PYTHON_USE_WITH="threads" # Needed until upstream bug 640748 is fixed
+PYTHON_USE_WITH="threads="
inherit alternatives autotools gnome2 python virtualx
@@ -17,7 +17,7 @@ HOMEPAGE="http://www.pygtk.org/"
LICENSE="LGPL-2.1"
SLOT="2"
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
-IUSE="doc cairo examples +introspection libffi test"
+IUSE="doc cairo examples +introspection libffi test threads"
RDEPEND=">=dev-libs/glib-2.22.4:2
!<dev-python/pygtk-2.13
@@ -41,6 +41,7 @@ pkg_setup() {
$(use_enable doc docs)
$(use_enable cairo)
$(use_enable introspection)
+ $(use_enable threads thread)
$(use_with libffi ffi)"
}
@@ -62,6 +63,9 @@ src_prepare() {
# Fix crash in instance property; bug# 344459
epatch "${FILESDIR}/${PN}-2.26.0-nocrash.patch"
+ # Disable calls to PyGILState_* when threads are disabled
+ epatch "${FILESDIR}/${PN}-2.26.0-disabled-threads.patch"
+
# disable pyc compiling
mv py-compile py-compile.orig
ln -s $(type -P true) py-compile