depot/third_party/nixpkgs/pkgs/development/python-modules/pykakasi/default.nix
Default email 98eb3e9ef5 Project import generated by Copybara.
GitOrigin-RevId: 00d80d13810dbfea8ab4ed1009b09100cca86ba8
2024-07-01 15:47:52 +00:00

62 lines
1.3 KiB
Nix

{
lib,
buildPythonPackage,
deprecated,
fetchFromGitea,
importlib-resources,
jaconv,
py-cpuinfo,
pytest-benchmark,
pytestCheckHook,
pythonOlder,
setuptools-scm,
}:
buildPythonPackage rec {
pname = "pykakasi";
version = "2.3.0";
pyproject = true;
disabled = pythonOlder "3.8";
src = fetchFromGitea {
domain = "codeberg.org";
owner = "miurahr";
repo = "pykakasi";
rev = "refs/tags/v${version}";
hash = "sha256-b2lYYdg1RW1xRD3hym7o1EnxzN/U5txVTWRifwZn3k0=";
};
build-system = [ setuptools-scm ];
dependencies = [
jaconv
deprecated
] ++ lib.optionals (pythonOlder "3.9") [ importlib-resources ];
nativeCheckInputs = [
py-cpuinfo
pytest-benchmark
pytestCheckHook
];
disabledTests = [
# We don't care about benchmarks
"test_benchmark"
"pytest_benchmark_update_machine_info"
"pytest_benchmark_update_json"
# Assertion error
"test_aozora"
];
pythonImportsCheck = [ "pykakasi" ];
meta = with lib; {
description = "Python converter for Japanese Kana-kanji sentences into Kana-Roman";
homepage = "https://codeberg.org/miurahr/pykakasi";
changelog = "https://codeberg.org/miurahr/pykakasi/src/tag/v${version}/CHANGELOG.rst";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ fab ];
mainProgram = "kakasi";
};
}