summaryrefslogtreecommitdiff
blob: 3f38eebbe413259ee780b35c0fac4eba8bccec5e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-python/pyqwt/pyqwt-5.1.0.ebuild,v 1.2 2009/12/27 14:04:22 yngwin Exp $

EAPI=2
inherit eutils python toolchain-funcs

MY_P="PyQwt-${PV}"
S="${WORKDIR}/${MY_P}/configure"

DESCRIPTION="Python bindings for the Qwt library"
SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.gz"
HOMEPAGE="http://pyqwt.sourceforge.net/"
SLOT="5"
LICENSE="GPL-2"
KEYWORDS="~amd64 ~ia64 ~x86"
IUSE="debug doc examples svg"

RDEPEND="=x11-libs/qwt-5.1*[svg?]
	dev-python/PyQt4
	dev-python/numpy"
DEPEND="${DEPEND}
	<dev-python/sip-4.9"

src_configure() {
	# the -j option can be buggy
	python_version
	"${python}" configure.py \
		--disable-numarray \
		--disable-numeric \
		-I/usr/include/qwt5 \
		-lqwt \
		|| die "python configure.py failed"
}

src_install() {
	python_need_rebuild
	emake DESTDIR="${D}" install || die "emake install failed"
	cd ..
	dodoc ANNOUNCEMENT-${PV} CHANGES-${PV} README
	if use doc; then
		insinto /usr/share/doc/${PF}/html
		doins -r Doc/html || die
	fi
	if use examples ; then
		insinto /usr/share/doc/${PF}/examples
		doins qt4examples/* || die
	fi
}