Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 416479 | Differences between
and this patch

Collapse All | Expand All

(-)../mwlib.orig/mwlib-0.13.7.ebuild (-14 / +49 lines)
Lines 2-13 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-python/mwlib/mwlib-0.13.6.ebuild,v 1.1 2012/04/19 09:54:31 patrick Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-python/mwlib/mwlib-0.13.6.ebuild,v 1.1 2012/04/19 09:54:31 patrick Exp $
4
4
5
EAPI="3"
5
EAPI="4"
6
PYTHON_DEPEND="2:2.5"
6
PYTHON_DEPEND="2:2.6"
7
SUPPORT_PYTHON_ABIS="1"
7
SUPPORT_PYTHON_ABIS="1"
8
RESTRICT_PYTHON_ABIS="2.4 2.5 3.* 2.7-pypy-* *-jython"
8
RESTRICT_PYTHON_ABIS="3.* *-pypy-* *-jython"
9
DISTUTILS_SRC_TEST="py.test"
9
DISTUTILS_SRC_TEST=py.test
10
inherit distutils
10
inherit distutils eutils
11
11
12
DESCRIPTION="Tools for parsing Mediawiki content to other formats"
12
DESCRIPTION="Tools for parsing Mediawiki content to other formats"
13
HOMEPAGE="http://code.pediapress.com/wiki/wiki http://pypi.python.org/pypi/mwlib"
13
HOMEPAGE="http://code.pediapress.com/wiki/wiki http://pypi.python.org/pypi/mwlib"
Lines 16-47 Link Here
16
LICENSE="BSD"
16
LICENSE="BSD"
17
SLOT="0"
17
SLOT="0"
18
KEYWORDS="~amd64 ~x86"
18
KEYWORDS="~amd64 ~x86"
19
IUSE=""
19
IUSE="doc"
20
20
21
RDEPEND="dev-lang/perl
21
RDEPEND="dev-python/imaging
22
	>=dev-python/flup-1.0
23
	dev-python/imaging
24
	>=dev-python/lockfile-0.8
25
	dev-python/lxml
22
	dev-python/lxml
26
	=dev-python/odfpy-0.9*
23
	=dev-python/odfpy-0.9*
27
	>=dev-python/pyPdf-1.12
24
	>=dev-python/pyPdf-1.12
28
	>=dev-python/pyparsing-1.4.11
25
	>=dev-python/pyparsing-1.4.11
29
	>=dev-python/timelib-0.2
26
	>=dev-python/timelib-0.2
30
	>=dev-python/twisted-9.0.0-r1
31
	>=dev-python/twisted-web-9.0.0
32
	>=dev-python/webob-0.9
33
	virtual/latex-base
27
	virtual/latex-base
34
	|| ( dev-lang/python:2.7 dev-lang/python:2.6 >=dev-python/simplejson-1.3 )"
28
	|| ( dev-lang/python:2.7 dev-lang/python:2.6 >=dev-python/simplejson-2.5 )
29
	dev-python/gevent
30
	>=dev-python/bottle-0.10
31
	dev-python/apipkg
32
	>=dev-python/qserve-0.2.7
33
	dev-python/roman
34
	>=dev-python/py-1.4
35
	dev-python/sqlite3dbm"
35
DEPEND="${RDEPEND}
36
DEPEND="${RDEPEND}
37
	app-arch/unzip
38
	doc? ( dev-python/sphinx )
36
	dev-python/setuptools"
39
	dev-python/setuptools"
37
40
38
PYTHON_CFLAGS=("2.* + -fno-strict-aliasing")
41
PYTHON_CFLAGS=("2.* + -fno-strict-aliasing")
39
42
40
src_prepare() {
43
src_prepare() {
44
	# mwlib.apipkg is actually used.
45
	sed -e 's/, "apipkg"//' -i setup.py
46
41
	distutils_src_prepare
47
	distutils_src_prepare
48
	# Disable test which requires installed mw-zip script.
49
	rm -f tests/test_nuwiki.py
50
	rm -f tests/test_redirect.py
51
	rm -f tests/test_zipwiki.py
52
	epatch "${FILESDIR}"/test.patch
42
}
53
}
43
54
44
src_compile() {
55
src_compile() {
45
	distutils_src_compile
56
	distutils_src_compile
46
	use doc && emake -C  docs html
57
	use doc && emake -C  docs html
47
}
58
}
59
60
src_test() {
61
	# Though DISTUTILS_SRC_TEST=py.test ought work, it errors out.  This works
62
	testing() {
63
	local exit_status=0
64
#	PYTHONPATH="$(find build-${PYTHON_ABI} -name mwlib)}/":$PYTHONPATH/test
65
	for test in tests/test_*.py
66
	do
67
		py.test $test -v || exit_status=1
68
	done
69
	return $exit_status
70
	}
71
	python_execute_function testing
72
}
73
74
src_install() {
75
	distutils_src_install
76
	if use doc; then
77
		dohtml -r docs/_build/html/
78
		docompress -x usr/share/doc/${P}/doctrees/
79
		insinto usr/share/doc/${P}/
80
		doins -r docs/_build/doctrees
81
	fi
82
}

Return to bug 416479