blob: f18bc365fc4a362b50f9f84a8918dd97022a57d6 (
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-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_{13..14} )
inherit distutils-r1
DESCRIPTION="Python bindings generator for C/C++ libraries"
HOMEPAGE="https://github.com/Python-SIP/sip/"
SRC_URI="
https://github.com/Python-SIP/sip/archive/refs/tags/${PV}.tar.gz
-> ${P}.gh.tar.gz
"
LICENSE="BSD-2 BSD"
SLOT="5"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86"
RDEPEND="
dev-python/packaging[${PYTHON_USEDEP}]
dev-python/setuptools[${PYTHON_USEDEP}]
"
BDEPEND="
>=dev-python/setuptools-scm-8[${PYTHON_USEDEP}]
"
PATCHES=(
# https://github.com/Python-SIP/sip/issues/114
"${FILESDIR}/${P}-legacy-abi-without-minimum.patch"
)
distutils_enable_sphinx docs \
dev-python/myst-parser \
dev-python/sphinx-rtd-theme
EPYTEST_PLUGINS=()
distutils_enable_tests pytest
python_test() {
# the latest ABI version gets tested by default, but ABI 14
# requires python3.15 or higher
local epytestargs=()
[[ ${EPYTHON} =~ python3.1[2-4]t? ]] &&
epytestargs=( --sip-abi-version=13 )
epytest "${epytestargs[@]}"
}
|