Gentoo Archives: gentoo-commits

From: "Marien Zwart (marienz)" <marienz@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-python/twisted: twisted-12.2.0.ebuild ChangeLog
Date: Thu, 27 Sep 2012 18:14:48
Message-Id: 20120927181432.8D9C221600@flycatcher.gentoo.org
1 marienz 12/09/27 18:14:32
2
3 Modified: ChangeLog
4 Added: twisted-12.2.0.ebuild
5 Log:
6 Bump to 12.2.0 (bug #423777) with some test-related ebuild improvements.
7
8 (Portage version: 2.2.0_alpha133/cvs/Linux x86_64)
9
10 Revision Changes Path
11 1.156 dev-python/twisted/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-python/twisted/ChangeLog?rev=1.156&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-python/twisted/ChangeLog?rev=1.156&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-python/twisted/ChangeLog?r1=1.155&r2=1.156
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/dev-python/twisted/ChangeLog,v
20 retrieving revision 1.155
21 retrieving revision 1.156
22 diff -u -r1.155 -r1.156
23 --- ChangeLog 9 May 2012 00:02:50 -0000 1.155
24 +++ ChangeLog 27 Sep 2012 18:14:32 -0000 1.156
25 @@ -1,6 +1,13 @@
26 # ChangeLog for dev-python/twisted
27 # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/dev-python/twisted/ChangeLog,v 1.155 2012/05/09 00:02:50 aballier Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/dev-python/twisted/ChangeLog,v 1.156 2012/09/27 18:14:32 marienz Exp $
30 +
31 +*twisted-12.2.0 (27 Sep 2012)
32 +
33 + 27 Sep 2012; Marien Zwart <marienz@g.o>
34 + +files/twisted-12.1.0-remove-tests-conch-dependency.patch,
35 + +twisted-12.2.0.ebuild:
36 + Bump to 12.2.0 (bug #423777) with some test-related ebuild improvements.
37
38 08 May 2012; Alexis Ballier <aballier@g.o> twisted-12.0.0.ebuild:
39 keyword ~amd64-fbsd
40 @@ -672,4 +679,3 @@
41
42
43 Ebuild submitted by Gontran Zepeda <gontran@×××××××.net>.
44 -
45
46
47
48 1.1 dev-python/twisted/twisted-12.2.0.ebuild
49
50 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-python/twisted/twisted-12.2.0.ebuild?rev=1.1&view=markup
51 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-python/twisted/twisted-12.2.0.ebuild?rev=1.1&content-type=text/plain
52
53 Index: twisted-12.2.0.ebuild
54 ===================================================================
55 # Copyright 1999-2012 Gentoo Foundation
56 # Distributed under the terms of the GNU General Public License v2
57 # $Header: /var/cvsroot/gentoo-x86/dev-python/twisted/twisted-12.2.0.ebuild,v 1.1 2012/09/27 18:14:32 marienz Exp $
58
59 EAPI="4"
60 PYTHON_DEPEND="2"
61 SUPPORT_PYTHON_ABIS="1"
62 RESTRICT_PYTHON_ABIS="3.* *-jython"
63 # A couple of failures (refcounting, version-checking), but sufficiently
64 # functional to be useful, so restrict just the tests.
65 PYTHON_TESTS_RESTRICTED_ABIS="*-pypy-*"
66 MY_PACKAGE="Core"
67
68 inherit eutils twisted versionator
69
70 DESCRIPTION="An asynchronous networking framework written in Python"
71
72 LICENSE="MIT"
73 SLOT="0"
74 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~ia64-hpux ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
75 IUSE="crypt gtk serial"
76
77 DEPEND="net-zope/zope-interface
78 crypt? ( >=dev-python/pyopenssl-0.10 )
79 gtk? ( dev-python/pygtk:2 )
80 serial? ( dev-python/pyserial )"
81 RDEPEND="${DEPEND}"
82
83 # Needed to make the sendmsg extension work
84 # (see http://twistedmatrix.com/trac/ticket/5701 )
85 PYTHON_CFLAGS=("2.* + -fno-strict-aliasing")
86
87 DOCS="CREDITS NEWS README"
88
89 src_prepare(){
90 distutils_src_prepare
91
92 # Give a load-sensitive test a better chance of succeeding.
93 epatch "${FILESDIR}/${PN}-2.1.0-echo-less.patch"
94
95 # Skip a test if twisted conch is not available
96 # (see Twisted ticket #5703)
97 epatch "${FILESDIR}/twisted-12.1.0-remove-tests-conch-dependency.patch"
98
99 # Respect TWISTED_DISABLE_WRITING_OF_PLUGIN_CACHE variable.
100 epatch "${FILESDIR}/${PN}-9.0.0-respect_TWISTED_DISABLE_WRITING_OF_PLUGIN_CACHE.patch"
101
102 if [[ "${EUID}" -eq 0 ]]; then
103 # Disable tests failing with root permissions.
104 sed \
105 -e "s/test_newPluginsOnReadOnlyPath/_&/" \
106 -e "s/test_deployedMode/_&/" \
107 -i twisted/test/test_plugin.py
108 fi
109 }
110
111 src_test() {
112 testing() {
113 local exit_status="0"
114 "$(PYTHON)" setup.py build -b "build-${PYTHON_ABI}" install --root="${T}/tests-${PYTHON_ABI}" --no-compile || die "Installation of tests failed with $(python_get_implementation_and_version)"
115
116 pushd "${T}/tests-${PYTHON_ABI}${EPREFIX}$(python_get_sitedir)" > /dev/null || die
117
118 # Skip broken tests.
119 sed -e "s/test_buildAllTarballs/_&/" -i twisted/python/test/test_release.py || die "sed failed"
120
121 # http://twistedmatrix.com/trac/ticket/5375
122 sed -e "/class ZshIntegrationTestCase/,/^$/d" -i twisted/scripts/test/test_scripts.py || die "sed failed"
123
124 # tap2rpm is already skipped if rpm is not installed, but fails for me on a Gentoo box with it present.
125 # I currently lack the cycles to track this failure down.
126 rm twisted/scripts/test/test_tap2rpm.py
127
128 # Prevent it from pulling in plugins from already installed twisted packages.
129 rm -f twisted/plugins/__init__.py
130
131 # An empty file doesn't work because the tests check for doc strings in all packages.
132 echo "'''plugins stub'''" > twisted/plugins/__init__.py || die
133
134 if ! PYTHONPATH="." "${T}/tests-${PYTHON_ABI}${EPREFIX}/usr/bin/trial" twisted; then
135 if [[ -n "${TWISTED_DEBUG_TESTS}" ]]; then
136 die "Tests failed with $(python_get_implementation_and_version)"
137 else
138 exit_status="1"
139 fi
140 fi
141
142 popd > /dev/null || die
143 return "${exit_status}"
144 }
145 python_execute_function testing
146 }
147
148 src_install() {
149 distutils_src_install
150 python_clean_installation_image
151
152 python_generate_wrapper_scripts -E -f -q "${ED}usr/bin/trial"
153
154 postinstallational_preparation() {
155 touch "${ED}$(python_get_sitedir)/Twisted-${PV}-py$(python_get_version).egg-info"
156
157 # Delete dropin.cache to avoid collisions.
158 # dropin.cache is regenerated in pkg_postinst().
159 rm -f "${ED}$(python_get_sitedir)/twisted/plugins/dropin.cache"
160 }
161 python_execute_function -q postinstallational_preparation
162
163 # Don't install index.xhtml page.
164 doman doc/man/*.?
165 insinto /usr/share/doc/${PF}
166 doins -r $(find doc -mindepth 1 -maxdepth 1 -not -name man)
167
168 newconfd "${FILESDIR}/twistd.conf" twistd
169 newinitd "${FILESDIR}/twistd.init" twistd
170 }