1 # Copyright 1999-2019 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
6 PYTHON_COMPAT=( python3_{5,6} )
9 inherit distutils-r1 virtualx
14 DESCRIPTION="Toolkit for building high-level compound widgets in Python using the Tkinter module"
15 HOMEPAGE="http://pmw.sourceforge.net/"
16 SRC_URI="mirror://pypi/${MY_PN:0:1}/${MY_PN}/${MY_P}.tar.gz"
20 KEYWORDS="alpha amd64 ia64 ppc sparc x86 ~amd64-linux ~x86-linux ~x64-macos ~x86-macos"
21 IUSE="doc examples test"
23 DEPEND="!dev-python/pmw:0"
25 # https://sourceforge.net/p/pmw/bugs/39/
28 S="${WORKDIR}/${MY_P}"
31 distutils-r1_python_prepare
36 VIRTUALX_COMMAND="${PYTHON}"
37 cd "${BUILD_DIR}/lib/Pmw/Pmw_${PV//./_}/" || die
38 cp tests/{flagup.bmp,earthris.gif} . || die
39 for test in tests/*_test.py; do
40 echo "running test "$test
41 PYTHONPATH=tests:../../ virtualmake $test || die
45 python_install_all() {
46 local DIR="Pmw/Pmw_${PV//./_}"
48 use doc && HTML_DOCS=( "${DIR}"/doc/. )
49 use examples && EXAMPLES=( "${DIR}"/demos/. )
51 distutils-r1_python_install_all