summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/piper-phonemize/default.nix
blob: 159e39bb38f67b926a20a811b5264fa21fd79351 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
{
  lib,
  stdenv,
  buildPythonPackage,
  onnxruntime-native,
  piper-phonemize-native,
  pybind11,
  setuptools,
}:

buildPythonPackage {
  inherit (piper-phonemize-native) pname version src;
  pyproject = true;

  nativeBuildInputs = [
    pybind11
    setuptools
  ];

  buildInputs = [
    onnxruntime-native
    piper-phonemize-native
    piper-phonemize-native.espeak-ng
  ];

  # coredump in onnxruntime::logging::Logger& onnxruntime::logging::LoggingManager::DefaultLogger()
  pythonImportsCheck = lib.optionals stdenv.hostPlatform.isx86 [ "piper_phonemize" ];

  # no tests
  doCheck = false;

  meta = {
    description = "Phonemization libary used by Piper text to speech system";
    inherit (piper-phonemize-native.meta) homepage license maintainers;
  };
}