summaryrefslogtreecommitdiff
path: root/dev-python
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2025-07-15 05:55:20 +0200
committerMichał Górny <mgorny@gentoo.org>2025-07-15 05:55:20 +0200
commite3e4ca57b8ca9b1759b6bdb47071cdc56b30555b (patch)
tree65806bc52f710b2754e5c15436434e53e69be27d /dev-python
parentba9b007212b39e22083da86190b57f4ca4dfdef5 (diff)
downloadgentoo-e3e4ca57b8ca9b1759b6bdb47071cdc56b30555b.tar.gz
gentoo-e3e4ca57b8ca9b1759b6bdb47071cdc56b30555b.tar.bz2
gentoo-e3e4ca57b8ca9b1759b6bdb47071cdc56b30555b.zip
dev-python/uv-build: Bump to 0.7.21
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'dev-python')
-rw-r--r--dev-python/uv-build/Manifest1
-rw-r--r--dev-python/uv-build/uv-build-0.7.21.ebuild99
2 files changed, 100 insertions, 0 deletions
diff --git a/dev-python/uv-build/Manifest b/dev-python/uv-build/Manifest
index 1097e5ba3010..f29784dab183 100644
--- a/dev-python/uv-build/Manifest
+++ b/dev-python/uv-build/Manifest
@@ -1,3 +1,4 @@
DIST uv_build-0.7.13.tar.gz 310547 BLAKE2B 37a07d3aae9e5c1a1d8c187157473ab4c0bc65779751d2848c2d46228cef9ccb1b7e040f3330f3660b163a5fbf84acbd2433371d7d05014e53716297762bfe24 SHA512 44026e1139c95d082871a93d7d456684b07aa0b8f34609aabf1b7a74a81431a6811973e141cdc98c377b65e06b8ed56c6ca2393688132b6813363a00e622a911
DIST uv_build-0.7.19.tar.gz 311467 BLAKE2B a7e85c3bbaee786ed9729b1331e5506eeb95d4ee875502814555956611449501f6b1c62284945640a2ce95f225a1b1c151b47d17c0d303599fe69bffc4ab8e5c SHA512 c3bc554dd9d86bfdb1e9ebf042d8c00987a790da9d386eb371dcc1bc7cd1c0000ae69a4d1e5f1759ed723d78eed73a461bae26d5047bdb0c0bb75f450fdc009a
DIST uv_build-0.7.20.tar.gz 312893 BLAKE2B 0d675422d95cebebb25241b2d09568d7ca978c7598c5148841abbc228980d0bdd4ef6af977e4258e438474311d3ad13fdecb6c213b21bb4022d4b986ffc69cbd SHA512 bc2ef4f11af2c35e442b8ebc9c0edd0354924007d5d5151a6d3509c827fa3cc0702d372cc2129d4ebe3b98187c151cd30833f15a9cf59955901fcd6209f169b0
+DIST uv_build-0.7.21.tar.gz 314858 BLAKE2B 401135336e5ea8a58263562b398a2f0fd4d1ad8bf81b576d53d7006cc2c19042206fa2557ccf63cef132acd1b76b2ad8c39ebc8b997f35dbc8f8fe316738fca5 SHA512 51a285944e50ce7448e668f7f3c2209a51d9a62841bf8e2f5b0b9eeb355b75ff64e5d61d94c6974369119c0d654600d0f07637b41e35a81bac56d5de5730f6bf
diff --git a/dev-python/uv-build/uv-build-0.7.21.ebuild b/dev-python/uv-build/uv-build-0.7.21.ebuild
new file mode 100644
index 000000000000..7b6a5ee54e1b
--- /dev/null
+++ b/dev-python/uv-build/uv-build-0.7.21.ebuild
@@ -0,0 +1,99 @@
+# Copyright 2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+# Maturin compiles uv-build executable for every impl, we do not want
+# that, so we use another backend. And since we use another backend,
+# why not dogfood it in the first place?
+DISTUTILS_USE_PEP517=standalone
+PYTHON_COMPAT=( pypy3_11 python3_{11..14} )
+
+inherit distutils-r1 pypi
+
+DESCRIPTION="PEP517 uv build backend"
+HOMEPAGE="
+ https://github.com/astral-sh/uv/
+ https://pypi.org/project/uv-build/
+"
+
+LICENSE="|| ( Apache-2.0 MIT )"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ >=dev-python/uv-${PV}
+"
+BDEPEND="
+ test? (
+ app-arch/unzip
+ dev-python/build[${PYTHON_USEDEP}]
+ )
+"
+
+src_prepare() {
+ distutils-r1_src_prepare
+
+ # use the executable from dev-python/uv instead of building
+ # a largely overlapping uv-build executable (at least for now)
+ sed -i -e '/USE_UV_EXECUTABLE/s:False:True:' python/uv_build/__init__.py || die
+
+ # replace the build-system section
+ sed -i -e '/\[build-system\]/,$d' pyproject.toml || die
+ cat >> pyproject.toml <<-EOF || die
+ [build-system]
+ requires = ["uv_build<9999"]
+ build-backend = "uv_build"
+ backend-path = ["src"]
+ EOF
+
+ # rename to make uv-build find it
+ mv python src || die
+}
+
+python_test() {
+ "${EPYTHON}" -m build -n || die "Self-build failed with ${EPYTHON}"
+
+ local zip_result=$(
+ unzip -t "dist/uv_build-${PV}-py3-none-any.whl" || die
+ )
+ local zip_expected="\
+Archive: dist/uv_build-${PV}-py3-none-any.whl
+ testing: uv_build/ OK
+ testing: uv_build/__init__.py OK
+ testing: uv_build/__main__.py OK
+ testing: uv_build/py.typed OK
+ testing: uv_build-${PV}.dist-info/ OK
+ testing: uv_build-${PV}.dist-info/WHEEL OK
+ testing: uv_build-${PV}.dist-info/METADATA OK
+ testing: uv_build-${PV}.dist-info/RECORD OK
+No errors detected in compressed data of dist/uv_build-${PV}-py3-none-any.whl.\
+"
+ if [[ ${zip_result} != ${zip_expected} ]]; then
+ eerror ".zip result:\n${zip_result}"
+ eerror ".zip expected:\n${zip_expected}"
+ die ".whl result mismatch"
+ fi
+
+ local tar_result=$(
+ tar -tf "dist/uv_build-${PV}.tar.gz" || die
+ )
+ local tar_expected="\
+uv_build-${PV}/PKG-INFO
+uv_build-${PV}/
+uv_build-${PV}/README.md
+uv_build-${PV}/pyproject.toml
+uv_build-${PV}/src
+uv_build-${PV}/src/uv_build
+uv_build-${PV}/src/uv_build/__init__.py
+uv_build-${PV}/src/uv_build/__main__.py
+uv_build-${PV}/src/uv_build/py.typed\
+"
+ if [[ ${tar_result} != ${tar_expected} ]]; then
+ eerror ".tar.gz result:\n${tar_result}"
+ eerror ".tar.gz expected:\n${tar_expected}"
+ die ".tar.gz result mismatch"
+ fi
+}