Skip to content

yara-python: add build-yara-python.yml for riscv64 wheels - #1643

Merged
luhenry merged 1 commit into
mainfrom
yara-python
Sep 9, 2026
Merged

yara-python: add build-yara-python.yml for riscv64 wheels#1643
luhenry merged 1 commit into
mainfrom
yara-python

Conversation

@luhenry

@luhenry luhenry commented Sep 8, 2026

Copy link
Copy Markdown
Member

Python bindings for VirusTotal's YARA malware-pattern-matching engine, compiling the vendored yara/ submodule's C sources straight into the extension and linking OpenSSL for the hash module. Upstream publishes no riscv64 wheel.

Mirrors upstream's publish-to-pypi.yml.

Differs from upstream

  • Installs openssl-devel/openssl-dev via dnf/apk instead of building OpenSSL 1.1.1w from source - Rocky 10 and Alpine both already carry a current one.

Testing

  • same as upstream: tests.py, upstream's own self-contained suite

License: Ships yara/COPYING (BSD-3-Clause, compiled in) and OpenSSL's own LICENSE.txt (Apache-2.0, auditwheel-vendored) alongside yara-python's own Apache-2.0 LICENSE, none of which the unpatched wheel carries.

Patches

  • 0001-Package-the-licence-of-the-statically-compiled-yara-and-openssl-licenses.patch - To upstream [needs a PR against VirusTotal/yara-python]. Without it the wheel ships only yara-python's own LICENSE despite vendoring BSD-3-Clause and Apache-2.0 code; reproduces on any arch.

Built on cp312-manylinux_riscv64 and cp312-musllinux_riscv64; all 47 upstream tests passed, 0 skipped.

Builds the cp312/cp313/cp314/cp314t manylinux and musllinux riscv64 wheels for
yara-python 4.5.4, VirusTotal's C-extension Python bindings for the YARA
malware-pattern-matching engine. The build checks out the upstream repo with
its yara/ submodule (the vendored YARA C library) and drives cibuildwheel
directly against the checkout, compiling the submodule's C sources straight
into the extension with --enable-openssl so the hash module links libcrypto
(Rocky 10/Alpine ship a current openssl-dev(el), so upstream's from-source
OpenSSL 1.1.1w build is unneeded here). A patch declares the vendored yara
library's BSD-3-Clause COPYING and OpenSSL's own Apache-2.0 LICENSE.txt via
setuptools' license_files so both auditwheel-vendored/compiled-in components
ship their licence text alongside yara-python's own Apache-2.0 LICENSE.
luhenry added a commit that referenced this pull request Sep 8, 2026
@luhenry
luhenry merged commit 2a7f35f into main Sep 9, 2026
20 of 23 checks passed
@luhenry
luhenry deleted the yara-python branch September 9, 2026 08:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant