mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-17 14:49:30 -07:00
dev-python/sip: backport %MinimumABIVersion patch
Bug: https://bugs.gentoo.org/981016 Signed-off-by: David Seifert <soap@gentoo.org>
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
From 09598895c607f3e41f0249ade217ace0a4da6437 Mon Sep 17 00:00:00 2001
|
||||
From: Phil Thompson <phil@riverbankcomputing.com>
|
||||
Date: Sun, 23 Aug 2026 12:18:00 +0100
|
||||
Subject: [PATCH] Bug fixes
|
||||
|
||||
- Fixed a regression in SIP v6.16.1 that meant that bindings using legacy
|
||||
ABIs would not build if they didn't specify `%MinimumABIVersion`.
|
||||
Resolves #114
|
||||
---
|
||||
sipbuild/generator/parser/parser_manager.py | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/sipbuild/generator/parser/parser_manager.py b/sipbuild/generator/parser/parser_manager.py
|
||||
index 8f2501ff..83c63310 100644
|
||||
--- a/sipbuild/generator/parser/parser_manager.py
|
||||
+++ b/sipbuild/generator/parser/parser_manager.py
|
||||
@@ -1938,6 +1938,10 @@ def _finalise_abi_version(self):
|
||||
# We have no minimum version information from which to derive a
|
||||
# major version so use the default.
|
||||
major = DEFAULT_ABI_MAJOR
|
||||
+ elif major <= 13 and not minimums:
|
||||
+ # Allow older ABIs that don't specify %MinimumABIVersion. This
|
||||
+ # case can be removed in SIP v7.
|
||||
+ pass
|
||||
else:
|
||||
# Check that this major version is supported and that any minor
|
||||
# version meets the minimum requirements.
|
||||
49
dev-python/sip/sip-6.16.1-r1.ebuild
Normal file
49
dev-python/sip/sip-6.16.1-r1.ebuild
Normal file
@@ -0,0 +1,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_{12..15} )
|
||||
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[@]}"
|
||||
}
|
||||
Reference in New Issue
Block a user