1{
2 lib,
3 stdenv,
4 buildPythonPackage,
5 fetchFromGitHub,
6 pythonOlder,
7 cython,
8 setuptools,
9 setuptools-scm,
10 pytestCheckHook,
11 ApplicationServices,
12}:
13
14buildPythonPackage rec {
15 pname = "uharfbuzz";
16 version = "0.39.0";
17 pyproject = true;
18
19 disabled = pythonOlder "3.5";
20
21 src = fetchFromGitHub {
22 owner = "harfbuzz";
23 repo = "uharfbuzz";
24 rev = "refs/tags/v${version}";
25 fetchSubmodules = true;
26 hash = "sha256-I4fCaomq26FdkpiJdj+zyrbdqdynnD2hIutYTuTFvQs=";
27 };
28
29 nativeBuildInputs = [
30 cython
31 setuptools
32 setuptools-scm
33 ];
34
35 buildInputs = lib.optionals stdenv.isDarwin [ ApplicationServices ];
36
37 nativeCheckInputs = [ pytestCheckHook ];
38
39 pythonImportsCheck = [ "uharfbuzz" ];
40
41 meta = with lib; {
42 description = "Streamlined Cython bindings for the harfbuzz shaping engine";
43 homepage = "https://github.com/harfbuzz/uharfbuzz";
44 license = licenses.asl20;
45 maintainers = with maintainers; [ ];
46 };
47}