summaryrefslogtreecommitdiff
path: root/dev-python/sip
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-01-26 19:56:43 +0000
committerV3n3RiX <venerix@koprulu.sector>2023-01-26 19:56:43 +0000
commit236302aac694377916670b7769f941e3f1dd0bbc (patch)
tree0a81f35a6120e176fc267d7ad981d4734d85c8ba /dev-python/sip
parent7267fb40fb51ddbc9cc5c1c82b0a12807ef7b281 (diff)
gentoo auto-resync : 26:01:2023 - 19:56:42
Diffstat (limited to 'dev-python/sip')
-rw-r--r--dev-python/sip/Manifest3
-rw-r--r--dev-python/sip/files/sip-6.7.5-tomli.patch93
-rw-r--r--dev-python/sip/sip-6.7.5-r1.ebuild (renamed from dev-python/sip/sip-6.7.5.ebuild)14
3 files changed, 107 insertions, 3 deletions
diff --git a/dev-python/sip/Manifest b/dev-python/sip/Manifest
index a32d2c74a562..31ea5d29ab35 100644
--- a/dev-python/sip/Manifest
+++ b/dev-python/sip/Manifest
@@ -1,6 +1,7 @@
AUX sip-4.18-darwin.patch 1187 BLAKE2B a3cd0418de90e7377bc2ae1206f4620c6be379a3bd38f22c19256b06f5ba0c90ff07f34dcc8d2f44a25244e11544176a5e1b91049d220bd56cc7b3876a26ba76 SHA512 1afe049fd21f0e8e5118dec4d4b74851cd5e2c75a66a93e1a79a42267954b1edfcff9644696c7d98342499fb27fde727a554b5739cbd791d17a0e319c1dddb7e
+AUX sip-6.7.5-tomli.patch 2828 BLAKE2B fae02d3702df75164028298d342b81a5416381d53f33ab9f21604abe55fdbf30b717629b0e9794a7063abb4f74892d7367065b661b5a84def0a387655eebc5cb SHA512 578c980d924f3082b5fe865f4acb044fdea5c5d0d2e7b644446b52370a447500732727b33d2b239b8faaa271f3da554060e74e68263e4c11b15860e56e132139
DIST sip-4.19.25.tar.gz 1056384 BLAKE2B f92e105e6b30e871aea2883dc9cd459e4032fb139a9eaff153a3412a66b39df4d7ac985711a2693aee83195ff3850ae648bee4102f7fc3cc30d09885799f2b98 SHA512 60fb4133c68869bf0993144978b4847d94a0f9c7b477f64a346ea133cfe35bc11820204ab327dcf9a929b6f65a26d16cc7efbce65e49967c3347b39376e57001
DIST sip-6.7.5.tar.gz 1160691 BLAKE2B 64572687e026854c3e8ba7de637925f13a880e51e574993e37190b9b1fafa1850da686600a652bab9d399f58516e2c4e4d8a93f5fb13d53a12ecc5ec3885a98c SHA512 2dc38a6c0489e374a016b7db1f9443bb5d2fb29dc1fa7647ed2dd5bb4aa8758586e2b85569f9fb3b992e15eded0f7a783ec1a53b3d18bee3f8be53d43b79b7b9
EBUILD sip-4.19.25-r1.ebuild 2275 BLAKE2B 3b74d08ad36c71fff2d6982548870f14a1425903d94fcd86a21788bae8f9f0c30485846fe49f0aba13843d0764f421be133ec1a14d5e38f65b61a0a889155b25 SHA512 fa4b11a80372b8c9abf0a5c6b4ceb5b41f998342cd997a856b38f52e07e3c89524bdcfa6539dccd207bb03cfac231a7231304162c2984795d962ad10c88cfda1
-EBUILD sip-6.7.5.ebuild 981 BLAKE2B e3660796fb4b64be72a793dbafce88bc0c6ef9973f61cc82a0733a46f3d04f447b5eb8a758c0449dcdca0acf797caed644f96fa52bf75a9c5ba653b60f0e15a3 SHA512 ba2bbb6fb7a4cb32e57b1cdf4212f254bb88c2ccfaba796ecdb1fc12d773d3b1837ad22f4c0072f47564053a52354d0fb746786a9c57b9265ca922450f7ac57b
+EBUILD sip-6.7.5-r1.ebuild 1072 BLAKE2B 47a191feced8dfc25164c5ae4bf00e10b8eff6d871bb76808e888906e733a4c8826b1ad085f876251a8ac9098c035ba555c37d37ed4b575aa1529d14fd03f374 SHA512 753cc54678dc5b9fde5b4edd24f52b222bd3f3f390ddb0eeb35ee38d2975e23118721b28785fc5a0d878141df1cab3e5a224dfa592749338295d2173adf4b269
MISC metadata.xml 639 BLAKE2B deb4a3e534eaa966db932dc17bf7df6a04ed41ce707dc7f1befb272c362be06f222f976c4b0d526a6190d4954f1fa0e2c94ccc2e6cfceff6e8db5959e653fed1 SHA512 8c8e45d32587e346d4df067950aacbc767618418d42f4a5bf48a62706c9612007915ec643dc9fe7b7d083696b26795abb76d9cc475481c26782874f5116863a1
diff --git a/dev-python/sip/files/sip-6.7.5-tomli.patch b/dev-python/sip/files/sip-6.7.5-tomli.patch
new file mode 100644
index 000000000000..c785e41f265a
--- /dev/null
+++ b/dev-python/sip/files/sip-6.7.5-tomli.patch
@@ -0,0 +1,93 @@
+diff --git a/setup.py b/setup.py
+index 586606d..312a431 100644
+--- a/setup.py
++++ b/setup.py
+@@ -51,7 +51,7 @@ setup(
+ version=version,
+ license='SIP',
+ python_requires='>=3.7',
+- install_requires=['packaging', 'ply', 'setuptools', 'toml'],
++ install_requires=['packaging', 'ply', 'setuptools', 'tomli; python_version<"3.11"'],
+ packages=find_packages(),
+ package_data={
+ 'sipbuild.module': ['source/*/*'],
+diff --git a/sip.egg-info/requires.txt b/sip.egg-info/requires.txt
+index b465c08..8547535 100644
+--- a/sip.egg-info/requires.txt
++++ b/sip.egg-info/requires.txt
+@@ -1,4 +1,4 @@
+ packaging
+ ply
+ setuptools
+-toml
++tomli; python_version<"3.11"
+diff --git a/sipbuild/bindings_configuration.py b/sipbuild/bindings_configuration.py
+index 8197e27..a942f3f 100644
+--- a/sipbuild/bindings_configuration.py
++++ b/sipbuild/bindings_configuration.py
+@@ -22,11 +22,16 @@
+
+
+ import os
+-import toml
++import sys
+
+ from .exceptions import UserFileException, UserParseException
+ from .module import resolve_abi_version
+
++if sys.version_info >= (3, 11):
++ import tomllib
++else:
++ import tomli as tomllib
++
+
+ def get_bindings_configuration(abi_major, sip_file, sip_include_dirs):
+ """ Get the configuration of a set of bindings. """
+@@ -47,7 +52,8 @@ def get_bindings_configuration(abi_major, sip_file, sip_include_dirs):
+
+ # Read the configuration.
+ try:
+- cfg = toml.load(toml_file)
++ with open(toml_file, "rb") as f:
++ cfg = tomllib.load(f)
+ except Exception as e:
+ raise UserParseException(toml_file, detail=str(e))
+
+diff --git a/sipbuild/pyproject.py b/sipbuild/pyproject.py
+index 1ba2223..6e4a7c6 100644
+--- a/sipbuild/pyproject.py
++++ b/sipbuild/pyproject.py
+@@ -22,11 +22,16 @@
+
+
+ from collections import OrderedDict
+-import toml
++import sys
+
+ from .exceptions import UserFileException
+ from .py_versions import OLDEST_SUPPORTED_MINOR
+
++if sys.version_info >= (3, 11):
++ import tomllib
++else:
++ import tomli as tomllib
++
+
+ class PyProjectException(UserFileException):
+ """ An exception related to a pyproject.toml file. """
+@@ -69,7 +74,8 @@ class PyProject:
+ self.toml_error = None
+
+ try:
+- self._pyproject = toml.load('pyproject.toml', _dict=OrderedDict)
++ with open('pyproject.toml', 'rb') as f:
++ self._pyproject = tomllib.load(f)
+ except FileNotFoundError:
+ self.toml_error = "there is no such file in the current directory"
+ except Exception as e:
+@@ -174,4 +180,4 @@ class PyProject:
+ def _is_section(value):
+ """ Returns True if a section value is itself a section. """
+
+- return isinstance(value, (OrderedDict, list))
++ return isinstance(value, (OrderedDict, dict, list))
diff --git a/dev-python/sip/sip-6.7.5.ebuild b/dev-python/sip/sip-6.7.5-r1.ebuild
index 139b26e4f7c4..a839024c9fa8 100644
--- a/dev-python/sip/sip-6.7.5.ebuild
+++ b/dev-python/sip/sip-6.7.5-r1.ebuild
@@ -5,10 +5,14 @@ EAPI=8
PYTHON_COMPAT=( python3_{9..11} )
DISTUTILS_USE_PEP517=setuptools
+
inherit distutils-r1
DESCRIPTION="Python bindings generator for C/C++ libraries"
-HOMEPAGE="https://www.riverbankcomputing.com/software/sip/ https://pypi.org/project/sip/"
+HOMEPAGE="
+ https://www.riverbankcomputing.com/software/sip/
+ https://pypi.org/project/sip/
+"
MY_P=${PN}-${PV/_pre/.dev}
if [[ ${PV} == *_pre* ]]; then
@@ -28,7 +32,13 @@ RDEPEND="
dev-python/packaging[${PYTHON_USEDEP}]
dev-python/ply[${PYTHON_USEDEP}]
dev-python/setuptools[${PYTHON_USEDEP}]
- dev-python/toml[${PYTHON_USEDEP}]
+ $(python_gen_cond_dep '
+ dev-python/tomli[${PYTHON_USEDEP}]
+ ' 3.{8..10})
"
distutils_enable_sphinx doc --no-autodoc
+
+PATCHES=(
+ "${FILESDIR}"/${P}-tomli.patch
+)