diff options
author | Pacho Ramos <pacho@gentoo.org> | 2011-02-03 21:43:07 +0000 |
---|---|---|
committer | Pacho Ramos <pacho@gentoo.org> | 2011-02-03 21:43:07 +0000 |
commit | c30997ba05dabc1f5d644aebbefb6bd6eedf620a (patch) | |
tree | 88fddafc07a63a01d86867f99f379086f24be665 /dev-python/pygtk | |
parent | Version bump. Update to EAPI 4 and add myself as maintainer. (diff) | |
download | gentoo-2-c30997ba05dabc1f5d644aebbefb6bd6eedf620a.tar.gz gentoo-2-c30997ba05dabc1f5d644aebbefb6bd6eedf620a.tar.bz2 gentoo-2-c30997ba05dabc1f5d644aebbefb6bd6eedf620a.zip |
Fix 100% CPU load when apps receive SIGCHLD, bug #353599 by Antoine Martin.
(Portage version: 2.1.9.35/cvs/Linux x86_64)
Diffstat (limited to 'dev-python/pygtk')
-rw-r--r-- | dev-python/pygtk/ChangeLog | 8 | ||||
-rw-r--r-- | dev-python/pygtk/files/pygtk-2.22.0-wakeupfd-fix.patch | 26 | ||||
-rw-r--r-- | dev-python/pygtk/pygtk-2.22.0-r1.ebuild | 102 |
3 files changed, 135 insertions, 1 deletions
diff --git a/dev-python/pygtk/ChangeLog b/dev-python/pygtk/ChangeLog index aae8e92a5675..3e1a22eb76ee 100644 --- a/dev-python/pygtk/ChangeLog +++ b/dev-python/pygtk/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for dev-python/pygtk # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-python/pygtk/ChangeLog,v 1.245 2011/01/19 20:12:48 eva Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-python/pygtk/ChangeLog,v 1.246 2011/02/03 21:43:07 pacho Exp $ + +*pygtk-2.22.0-r1 (03 Feb 2011) + + 03 Feb 2011; Pacho Ramos <pacho@gentoo.org> +pygtk-2.22.0-r1.ebuild, + +files/pygtk-2.22.0-wakeupfd-fix.patch: + Fix 100% CPU load when apps receive SIGCHLD, bug #353599 by Antoine Martin. 19 Jan 2011; Gilles Dartiguelongue <eva@gentoo.org> pygtk-2.17.0.ebuild, pygtk-2.22.0.ebuild, +files/pygtk-2.22.0-disable-broken-tests.patch: diff --git a/dev-python/pygtk/files/pygtk-2.22.0-wakeupfd-fix.patch b/dev-python/pygtk/files/pygtk-2.22.0-wakeupfd-fix.patch new file mode 100644 index 000000000000..3e5cd4553185 --- /dev/null +++ b/dev-python/pygtk/files/pygtk-2.22.0-wakeupfd-fix.patch @@ -0,0 +1,26 @@ +From 4cbd3c031289775f365c247f949d91facac4ba82 Mon Sep 17 00:00:00 2001 +From: Dieter Verfaillie <dieterv@optionexplicit.be> +Date: Thu, 03 Feb 2011 12:44:10 +0000 +Subject: Fix pygtk_main_watch_check, copied from pygobject/glib/pygmainloop.c:pyg_signal_watch_check. + +Fixes bug 640738 and 638780. +--- +diff --git a/gtk/gtk.override b/gtk/gtk.override +index 75018f4..94309a6 100644 +--- a/gtk/gtk.override ++++ b/gtk/gtk.override +@@ -1151,9 +1151,10 @@ pygtk_main_watch_check(GSource *source) + #ifdef HAVE_PYSIGNAL_SETWAKEUPFD + PySignalWatchSource *real_source = (PySignalWatchSource *)source; + GPollFD *poll_fd = &real_source->fd; +- int data_size = 0; ++ unsigned char dummy; ++ gssize ret; + if (poll_fd->revents & G_IO_IN) +- data_size = read(poll_fd->fd, 0, 1); ++ ret = read(poll_fd->fd, &dummy, 1); + #endif + + state = pyg_gil_state_ensure(); +-- +cgit v0.8.3.1 diff --git a/dev-python/pygtk/pygtk-2.22.0-r1.ebuild b/dev-python/pygtk/pygtk-2.22.0-r1.ebuild new file mode 100644 index 000000000000..d57e646af761 --- /dev/null +++ b/dev-python/pygtk/pygtk-2.22.0-r1.ebuild @@ -0,0 +1,102 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-python/pygtk/pygtk-2.22.0-r1.ebuild,v 1.1 2011/02/03 21:43:07 pacho Exp $ + +EAPI="3" +GCONF_DEBUG="no" +PYTHON_DEPEND="2:2.5" +SUPPORT_PYTHON_ABIS="1" +RESTRICT_PYTHON_ABIS="2.4 3.* *-jython" +PYTHON_EXPORT_PHASE_FUNCTIONS="1" + +inherit alternatives autotools eutils flag-o-matic gnome.org python virtualx + +DESCRIPTION="GTK+2 bindings for Python" +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 examples" + +RDEPEND=">=dev-libs/glib-2.8:2 + >=x11-libs/pango-1.16 + >=dev-libs/atk-1.12 + >=x11-libs/gtk+-2.22:2 + >=gnome-base/libglade-2.5 + >=dev-python/pycairo-1.0.2 + >=dev-python/pygobject-2.21.3:2 + dev-python/numpy" + +DEPEND="${RDEPEND} + doc? ( + dev-libs/libxslt + >=app-text/docbook-xsl-stylesheets-1.70.1 ) + >=dev-util/pkgconfig-0.9" + +src_prepare() { + # Fix declaration of codegen in .pc + epatch "${FILESDIR}/${PN}-2.13.0-fix-codegen-location.patch" + + # Broken test, upstream bug #636589 + epatch "${FILESDIR}/${PN}-2.22.0-disable-broken-tests.patch" + + # Fix 100% CPU load when apps receive SIGCHLD, bug #353599 + epatch "${FILESDIR}/${PN}-2.22.0-wakeupfd-fix.patch" + + # Disable pyc compiling + mv "${S}"/py-compile "${S}"/py-compile.orig + ln -s $(type -P true) "${S}"/py-compile + + AT_M4DIR="m4" eautoreconf + + python_copy_sources +} + +src_configure() { + use hppa && append-flags -ffunction-sections + python_src_configure $(use_enable doc docs) --enable-thread +} + +src_test() { + unset DBUS_SESSION_BUS_ADDRESS + + testing() { + cd tests + export XDG_CONFIG_HOME="${T}/$(PYTHON --ABI)" + Xemake check-local + } + python_execute_function -s testing +} + +src_install() { + python_src_install + python_clean_installation_image + dodoc AUTHORS ChangeLog INSTALL MAPPING NEWS README THREADS TODO || die + + if use examples; then + rm examples/Makefile* + insinto /usr/share/doc/${PF} + doins -r examples || die + fi +} + +pkg_postinst() { + python_mod_optimize gtk-2.0 + + create_symlinks() { + alternatives_auto_makesym $(python_get_sitedir)/pygtk.py pygtk.py-[0-9].[0-9] + alternatives_auto_makesym $(python_get_sitedir)/pygtk.pth pygtk.pth-[0-9].[0-9] + } + python_execute_function create_symlinks +} + +pkg_postrm() { + python_mod_cleanup gtk-2.0 + + create_symlinks() { + alternatives_auto_makesym $(python_get_sitedir)/pygtk.py pygtk.py-[0-9].[0-9] + alternatives_auto_makesym $(python_get_sitedir)/pygtk.pth pygtk.pth-[0-9].[0-9] + } + python_execute_function create_symlinks +} |