20 buildPythonPackage rec {
25 disabled = pythonOlder "3.9";
27 src = fetchFromGitHub {
28 owner = "maxbachmann";
30 rev = "refs/tags/v${version}";
31 hash = "sha256-0L8nkjgWdP/w//M69ZRxYk9If3CIEcnAl9mkJKJ4o1g=";
35 substituteInPlace pyproject.toml \
36 --replace-fail "Cython >=3.0.11, <3.1.0" "Cython"
46 dontUseCmakeConfigure = true;
55 export RAPIDFUZZ_BUILD_EXTENSION=1
57 + lib.optionalString (stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isx86_64) ''
58 export CMAKE_ARGS="-DCMAKE_CXX_COMPILER_AR=$AR -DCMAKE_CXX_COMPILER_RANLIB=$RANLIB"
61 optional-dependencies = {
66 export RAPIDFUZZ_IMPLEMENTATION=cpp
75 disabledTests = lib.optionals (stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isx86_64) [
80 pythonImportsCheck = [
88 description = "Rapid fuzzy string matching";
89 homepage = "https://github.com/maxbachmann/RapidFuzz";
90 changelog = "https://github.com/maxbachmann/RapidFuzz/blob/${src.rev}/CHANGELOG.rst";
91 license = licenses.mit;
92 maintainers = with maintainers; [ dotlambda ];