dev-python/pure-protobuf: new package, add 3.1.5

Signed-off-by: Locez <locez@locez.com>
This commit is contained in:
Locez committed 2026-07-05 22:26:17 +08:00
1 parent 71d9a1e708
commit d920e7dbac
3 files changed
+49

No files matched your search

+1
View File
@@ -0,0 +1 @@
DIST pure_protobuf-3.1.5.tar.gz 17351 BLAKE2B 0082ec8d56b4aca2e533e021a62aa9572d4fa1ca3175c476e6e9200478bf1ea07e30cfeeee954ca48663b1bcd938de336a5fa1fea39e00c16883be682d633b55 SHA512 ba47ccd60ce2762b93e17e472949d385fde757e93945e7330248c74b3f1ec67eec158f8d4d6b45f547f4bced30afbfce97cb36c511f9306fe3455382423ef1bf
+12
View File
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>locez@locez.com</email>
<name>Locez</name>
</maintainer>
<upstream>
<remote-id type="pypi">pure-protobuf</remote-id>
<remote-id type="github">eigenein/protobuf</remote-id>
</upstream>
</pkgmetadata>
@@ -0,0 +1,36 @@
# Copyright 2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DISTUTILS_USE_PEP517=poetry-core
PYTHON_COMPAT=( python3_{13..14} )
inherit distutils-r1 pypi
DESCRIPTION="A pure python implementation of google protobuf"
HOMEPAGE="https://github.com/eigenein/protobuf"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"
RDEPEND="
>=dev-python/typing-extensions-4.4.0[${PYTHON_USEDEP}]
<dev-python/typing-extensions-5[${PYTHON_USEDEP}]
"
src_prepare() {
# Patch backend to use poetry-core directly, avoiding poetry-dynamic-versioning dependency.
sed -i \
-e 's:poetry_dynamic_versioning.backend:poetry.core.masonry.api:' \
-e '/"poetry-dynamic-versioning"/d' \
pyproject.toml || die
distutils-r1_src_prepare
}
python_test() {
local -x PYTHONPATH="${BUILD_DIR}/install$(python_get_sitedir)"
"${EPYTHON}" -c "from pure_protobuf.annotations import Field; from pure_protobuf.message import BaseMessage" \
|| die "Import check failed with ${EPYTHON}"
}