2022-02-09 23:02:03 +01:00
|
|
|
# Copyright 2016-2022 Gentoo Authors
|
2020-12-08 17:10:46 +01:00
|
|
|
# Distributed under the terms of the GNU General Public License v2
|
|
|
|
|
2021-07-10 19:09:23 +02:00
|
|
|
EAPI="8"
|
2020-12-08 17:10:46 +01:00
|
|
|
|
2022-09-20 09:47:00 +02:00
|
|
|
PYTHON_COMPAT=( python3_{10..11} )
|
2020-12-08 17:10:46 +01:00
|
|
|
|
|
|
|
inherit distutils-r1
|
|
|
|
|
2022-07-04 23:11:57 +02:00
|
|
|
COMMIT_ID="8737cfb7331069d01b2d44bcccf593fb1227ee2e"
|
2020-12-08 17:10:46 +01:00
|
|
|
|
|
|
|
DESCRIPTION="SoundFile is an audio library based on libsndfile, CFFI, and NumPy"
|
2021-05-15 23:59:59 +02:00
|
|
|
HOMEPAGE="https://github.com/bastibe/python-soundfile"
|
2020-12-08 17:10:46 +01:00
|
|
|
|
|
|
|
if [[ ${PV} == *9999 ]]; then
|
2021-05-15 23:59:59 +02:00
|
|
|
EGIT_REPO_URI="https://github.com/bastibe/python-${PN}"
|
2020-12-08 17:10:46 +01:00
|
|
|
inherit git-r3
|
|
|
|
else
|
2022-02-09 23:02:03 +01:00
|
|
|
if [[ (${PV} == *_p*) || (${PV} == *_beta*) ]]; then
|
2021-05-15 23:59:59 +02:00
|
|
|
SRC_URI="https://github.com/bastibe/python-${PN}/archive/${COMMIT_ID}.tar.gz -> ${P}.tar.gz"
|
|
|
|
S="${WORKDIR}/python-${PN}-${COMMIT_ID}"
|
2020-12-08 17:10:46 +01:00
|
|
|
else
|
2021-05-15 23:59:59 +02:00
|
|
|
SRC_URI="https://github.com/bastibe/python-${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
|
2020-12-08 17:10:46 +01:00
|
|
|
fi
|
|
|
|
fi
|
2021-08-05 14:22:51 +02:00
|
|
|
KEYWORDS="~amd64 ~x86"
|
2020-12-08 17:10:46 +01:00
|
|
|
|
|
|
|
LICENSE="PySoundFile-BSD-3"
|
|
|
|
SLOT="0"
|
|
|
|
IUSE="test"
|
|
|
|
# Some tests result in sandbox violations.
|
|
|
|
RESTRICT="test"
|
|
|
|
|
|
|
|
DEPEND="
|
|
|
|
dev-python/cffi[${PYTHON_USEDEP}]
|
|
|
|
dev-python/numpy[${PYTHON_USEDEP}]
|
|
|
|
media-libs/libsndfile
|
|
|
|
test? ( dev-python/pytest[${PYTHON_USEDEP}] )
|
|
|
|
"
|
|
|
|
|
|
|
|
python_test() {
|
|
|
|
py.test -vv
|
|
|
|
}
|