Skip to content

Commit

Permalink
Merge pull request #305943 from fabaff/levenshtein-bump
Browse files Browse the repository at this point in the history
python312Packages.levenshtein: 0.25.0 -> 0.25.1
  • Loading branch information
fabaff authored Apr 27, 2024
2 parents fce4c5c + 576b9e6 commit 4d205c7
Showing 1 changed file with 24 additions and 29 deletions.
53 changes: 24 additions & 29 deletions pkgs/development/python-modules/levenshtein/default.nix
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
{ lib
, stdenv
, buildPythonPackage
, cmake
, cython
, fetchFromGitHub
, pytestCheckHook
, pythonOlder
, rapidfuzz
, rapidfuzz-cpp
, scikit-build
{
lib,
stdenv,
buildPythonPackage,
cmake,
cython,
fetchFromGitHub,
pytestCheckHook,
pythonOlder,
rapidfuzz,
rapidfuzz-cpp,
scikit-build,
}:

buildPythonPackage rec {
pname = "levenshtein";
version = "0.25.0";
version = "0.25.1";
pyproject = true;

disabled = pythonOlder "3.8";
Expand All @@ -22,8 +23,8 @@ buildPythonPackage rec {
owner = "maxbachmann";
repo = "Levenshtein";
rev = "refs/tags/v${version}";
hash = "sha256-MkzIwTZU8hqPDOlfN4qADCKjGJIQrNhhOmVRAnAfNK0=";
fetchSubmodules = true; ## for vendored `rapidfuzz-cpp`
hash = "sha256-ye2XQL/ZQPlA4dy3tlr03WyGhfl7SaOXMt10cWHnW5o=";
fetchSubmodules = true; # # for vendored `rapidfuzz-cpp`
};

nativeBuildInputs = [
Expand All @@ -34,25 +35,19 @@ buildPythonPackage rec {

dontUseCmakeConfigure = true;

buildInputs = [
rapidfuzz-cpp
];
buildInputs = [ rapidfuzz-cpp ];

env.NIX_CFLAGS_COMPILE = toString (lib.optionals (stdenv.cc.isClang && stdenv.isDarwin) [
"-fno-lto" # work around https://github.com/NixOS/nixpkgs/issues/19098
]);
env.NIX_CFLAGS_COMPILE = toString (
lib.optionals (stdenv.cc.isClang && stdenv.isDarwin) [
"-fno-lto" # work around https://github.com/NixOS/nixpkgs/issues/19098
]
);

propagatedBuildInputs = [
rapidfuzz
];
dependencies = [ rapidfuzz ];

nativeCheckInputs = [
pytestCheckHook
];
nativeCheckInputs = [ pytestCheckHook ];

pythonImportsCheck = [
"Levenshtein"
];
pythonImportsCheck = [ "Levenshtein" ];

meta = with lib; {
description = "Functions for fast computation of Levenshtein distance and string similarity";
Expand Down

0 comments on commit 4d205c7

Please sign in to comment.