Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 stdenv, 4 buildPythonPackage, 5 fetchPypi, 6 isPy3k, 7 pytest, 8 unicodecsv, 9 rustPlatform, 10 libiconv, 11}: 12 13buildPythonPackage rec { 14 pname = "jellyfish"; 15 version = "1.0.4"; 16 17 disabled = !isPy3k; 18 19 format = "pyproject"; 20 21 src = fetchPypi { 22 inherit pname version; 23 hash = "sha256-cqq7O+3VE83SBxIkL9URc7WZcsCxRregucbzLxZWKT8="; 24 }; 25 26 nativeBuildInputs = with rustPlatform; [ 27 maturinBuildHook 28 cargoSetupHook 29 ]; 30 31 buildInputs = lib.optionals stdenv.isDarwin [ libiconv ]; 32 33 cargoDeps = rustPlatform.fetchCargoTarball { 34 inherit src; 35 name = "${pname}-${version}-rust-dependencies"; 36 hash = "sha256-HtzgxTO6tbN/tohaiTm9B9jrFYGTt1Szo9qRzpcy8BA="; 37 }; 38 39 nativeCheckInputs = [ 40 pytest 41 unicodecsv 42 ]; 43 44 meta = { 45 homepage = "https://github.com/sunlightlabs/jellyfish"; 46 description = "Approximate and phonetic matching of strings"; 47 maintainers = with lib.maintainers; [ koral ]; 48 }; 49}