From: "Michał Górny" <mgorny@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/crc32c/
Date: Wed, 28 Feb 2024 16:48:52 +0000 (UTC) [thread overview]
Message-ID: <1709138925.80fb851506b51dfc626394910599e083714bf9c3.mgorny@gentoo> (raw)
commit: 80fb851506b51dfc626394910599e083714bf9c3
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Wed Feb 28 14:59:43 2024 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Wed Feb 28 16:48:45 2024 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=80fb8515
dev-python/crc32c: New package, v2.4
New package, needed by dev-python/kafka-python[test]
and dev-python/python-snappy.
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
dev-python/crc32c/Manifest | 1 +
dev-python/crc32c/crc32c-2.4.ebuild | 46 +++++++++++++++++++++++++++++++++++++
dev-python/crc32c/metadata.xml | 11 +++++++++
3 files changed, 58 insertions(+)
diff --git a/dev-python/crc32c/Manifest b/dev-python/crc32c/Manifest
new file mode 100644
index 000000000000..1bbb68b67268
--- /dev/null
+++ b/dev-python/crc32c/Manifest
@@ -0,0 +1 @@
+DIST crc32c-2.4.tar.gz 38272 BLAKE2B 1273f62794bd646e983737d922c4e1320a4519856b1cedf2d1d1f9b1e47fc767e248b6e00ada48e8f245e47fc18619327e9a8cfa5d88a0569c467ca6147a1974 SHA512 d747dee42184ff025dd6fd7334b65e5caba4066a055943a783b951d09e09339694072ea552aa95579f03a85a7bdb2eb4a8d12dc9a17f0f83d84c0fde534b36cb
diff --git a/dev-python/crc32c/crc32c-2.4.ebuild b/dev-python/crc32c/crc32c-2.4.ebuild
new file mode 100644
index 000000000000..ff64329bc4ad
--- /dev/null
+++ b/dev-python/crc32c/crc32c-2.4.ebuild
@@ -0,0 +1,46 @@
+# Copyright 2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_EXT=1
+DISTUTILS_USE_PEP517=setuptools
+PYTHON_COMPAT=( pypy3 python3_{10..12} )
+
+inherit distutils-r1 pypi
+
+DESCRIPTION="CRC32c algorithm in hardware and software"
+HOMEPAGE="
+ https://github.com/ICRAR/crc32c/
+ https://pypi.org/project/crc32c/
+"
+
+LICENSE="LGPL-2.1+"
+SLOT="0"
+KEYWORDS="~amd64"
+# NB: these don't affect the build, they are only used for tests
+IUSE="cpu_flags_arm_crc32 cpu_flags_x86_sse4_2"
+
+distutils_enable_tests pytest
+
+python_test() {
+ local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1
+ local -x CRC32C_SW_MODE
+
+ # force = run "software" code (i.e. unoptimized)
+ # none = run "hardware" code (i.e. SSE4.2 / ARMv8 CRC32)
+ for CRC32C_SW_MODE in none force; do
+ if [[ ${CRC32C_SW_MODE} == none ]]; then
+ if ! use cpu_flags_arm_crc32 && ! use cpu_flags_x86_sse4_2; then
+ continue
+ fi
+
+ # the test suite just skips all tests, so double-check
+ "${EPYTHON}" -c "import crc32c" ||
+ die "Importing crc32c failed (accelerated code path broken?)"
+ fi
+
+ einfo "Testing with CRC32C_SW_MODE=${CRC32C_SW_MODE}"
+ epytest
+ done
+}
diff --git a/dev-python/crc32c/metadata.xml b/dev-python/crc32c/metadata.xml
new file mode 100644
index 000000000000..a5c4dec1ece1
--- /dev/null
+++ b/dev-python/crc32c/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>python@gentoo.org</email>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">ICRAR/crc32c</remote-id>
+ <remote-id type="pypi">crc32c</remote-id>
+ </upstream>
+</pkgmetadata>
next reply other threads:[~2024-02-28 16:48 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-28 16:48 Michał Górny [this message]
-- strict thread matches above, loose matches on Subject: below --
2024-02-28 20:50 [gentoo-commits] repo/gentoo:master commit in: dev-python/crc32c/ Jakov Smolić
2024-02-28 20:56 Sam James
2024-02-28 21:39 Jakov Smolić
2024-02-28 23:16 Sam James
2024-05-17 17:18 Michał Górny
2024-06-30 18:26 Michał Górny
2024-07-01 2:57 Michał Górny
2024-08-08 3:08 Michał Górny
2024-08-10 5:26 Michał Górny
2024-08-24 19:32 Michał Górny
2024-08-26 14:56 Michał Górny
2024-09-25 4:39 Michał Górny
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1709138925.80fb851506b51dfc626394910599e083714bf9c3.mgorny@gentoo \
--to=mgorny@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox