diff --git a/dev-python/simsimd/Manifest b/dev-python/simsimd/Manifest index e2e30cdf5ba83..4c2072e6760ad 100644 --- a/dev-python/simsimd/Manifest +++ b/dev-python/simsimd/Manifest @@ -1 +1,2 @@ DIST SimSIMD-6.4.7.gh.tar.gz 221008 BLAKE2B 074c6d466a3b091fdba61d5896dc88adda516e90218940106a139249c70a27f51538a44fafe68159aba81e0c2b4662741d596e3258ad6a0147b69eef4e160b90 SHA512 73caaf4aa4b9de338d3f7205c60c6c2476ebf692d58ba9ae29797ab70c556fbf4e2acc111e5c48abc948addec3911e526bc77fe89a0624f7c02487d61da20f6b +DIST SimSIMD-6.4.9.gh.tar.gz 221231 BLAKE2B 088ed41affc07c51818999688fe12c37f97de5bfe2401b25fe92f76c013fd88e1648d9a4e04db6c1e05a79cd21ea0b2d3ac36ac1626f1bd9236cb997448bbd4f SHA512 c08656215c4c909de2446f94e42ddb3b1d965656f58c6f4c17245c12d1b7134ab0d61318918c61ed9c3270d8108004ae0ac0502e3da6f6ba66ed0ab37aeaaa8a diff --git a/dev-python/simsimd/simsimd-6.4.9.ebuild b/dev-python/simsimd/simsimd-6.4.9.ebuild new file mode 100644 index 0000000000000..2855eb30f7fbf --- /dev/null +++ b/dev-python/simsimd/simsimd-6.4.9.ebuild @@ -0,0 +1,64 @@ +# Copyright 2024-2025 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_11 python3_{11..14} ) + +inherit distutils-r1 toolchain-funcs + +MY_P=SimSIMD-${PV} +DESCRIPTION="Fastest SIMD-Accelerated Vector Similarity Functions for x86 and Arm" +HOMEPAGE=" + https://github.com/ashvardanian/SimSIMD/ + https://pypi.org/project/simsimd/ +" +# no sdist, as of 4.3.1 +# https://github.com/ashvardanian/SimSIMD/issues/113 +SRC_URI=" + https://github.com/ashvardanian/SimSIMD/archive/v${PV}.tar.gz + -> ${MY_P}.gh.tar.gz +" +S=${WORKDIR}/${MY_P} + +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="~amd64" +IUSE="openmp" + +BDEPEND=" + test? ( + dev-python/pytest-repeat[${PYTHON_USEDEP}] + dev-python/tabulate[${PYTHON_USEDEP}] + ) +" + +distutils_enable_tests pytest + +pkg_pretend() { + if [[ ${MERGE_TYPE} != binary ]] && use openmp; then + tc-check-openmp + fi +} + +pkg_setup() { + if [[ ${MERGE_TYPE} != binary ]] && use openmp; then + tc-check-openmp + fi +} + +src_prepare() { + sed -i -e '/-O3/d' setup.py || die + if ! use openmp; then + sed -i -e '/-fopenmp/d' setup.py || die + fi + + distutils-r1_src_prepare +} + +python_test() { + local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 + epytest -p repeat scripts/test.py +}