2015-04-08 16:23:29 +03:00
|
|
|
# Copyright 1999-2015 Gentoo Foundation
|
2014-06-28 17:54:24 +04:00
|
|
|
# Distributed under the terms of the GNU General Public License v2
|
2015-08-11 00:17:55 +03:00
|
|
|
# $Id$
|
2014-06-28 17:54:24 +04:00
|
|
|
|
|
|
|
EAPI=5
|
2015-04-08 16:23:29 +03:00
|
|
|
PYTHON_COMPAT=( python3_{3,4} )
|
2014-06-28 17:54:24 +04:00
|
|
|
|
|
|
|
inherit distutils-r1
|
|
|
|
|
|
|
|
DESCRIPTION="Python package to handle polygonal shapes in 2D"
|
|
|
|
HOMEPAGE="http://www.j-raedler.de/projects/polygon"
|
2014-07-07 10:31:30 +04:00
|
|
|
SRC_URI="https://www.bitbucket.org/jraedler/${PN}3/downloads/Polygon3-${PV}.zip"
|
2014-06-28 17:54:24 +04:00
|
|
|
|
|
|
|
LICENSE="LGPL-2"
|
|
|
|
SLOT="3"
|
2014-08-14 23:05:46 +04:00
|
|
|
IUSE="examples"
|
2014-12-08 02:57:30 +03:00
|
|
|
KEYWORDS="amd64 ppc x86"
|
2014-06-28 17:54:24 +04:00
|
|
|
|
|
|
|
DEPEND="app-arch/unzip"
|
|
|
|
|
|
|
|
S=${WORKDIR}/Polygon3-${PV}
|
|
|
|
|
2014-08-14 23:05:46 +04:00
|
|
|
DOCS=( doc/{Polygon.txt,Polygon.pdf} )
|
2014-06-28 17:54:24 +04:00
|
|
|
|
2014-08-14 23:05:46 +04:00
|
|
|
python_prepare_all() {
|
|
|
|
if use examples; then
|
|
|
|
mkdir examples || die
|
|
|
|
mv doc/{Examples.py,testpoly.gpf} examples || die
|
|
|
|
fi
|
|
|
|
distutils-r1_python_prepare_all
|
|
|
|
}
|
|
|
|
|
|
|
|
python_test() {
|
|
|
|
${PYTHON} test/Test.py || die "Tests failed under ${EPYTHON}"
|
|
|
|
}
|
|
|
|
|
|
|
|
python_install_all() {
|
|
|
|
use examples && local EXAMPLES=( examples/. )
|
|
|
|
distutils-r1_python_install_all
|
2014-06-28 17:54:24 +04:00
|
|
|
}
|