1{
2 lib,
3 fetchFromGitHub,
4 buildPythonPackage,
5 python,
6 pygobject3,
7 xvfb-run,
8 gobject-introspection,
9 gtk3,
10 pythonOlder,
11}:
12
13buildPythonPackage rec {
14 version = "3.2.0";
15 format = "setuptools";
16 pname = "liblarch";
17 disabled = pythonOlder "3.5.0";
18
19 src = fetchFromGitHub {
20 owner = "getting-things-gnome";
21 repo = "liblarch";
22 rev = "v${version}";
23 hash = "sha256-A2qChe2z6rAhjRVX5VoHQitebf/nMATdVZQgtlquuYg=";
24 };
25
26 nativeCheckInputs = [
27 gobject-introspection # for setup hook
28 gtk3
29 ];
30
31 buildInputs = [ gtk3 ];
32
33 propagatedBuildInputs = [ pygobject3 ];
34
35 checkPhase = ''
36 runHook preCheck
37 ${xvfb-run}/bin/xvfb-run -s '-screen 0 800x600x24' \
38 ${python.interpreter} nix_run_setup test
39 runHook postCheck
40 '';
41
42 meta = with lib; {
43 description = "A python library built to easily handle data structure such are lists, trees and acyclic graphs";
44 homepage = "https://github.com/getting-things-gnome/liblarch";
45 downloadPage = "https://github.com/getting-things-gnome/liblarch/releases";
46 license = licenses.lgpl3Plus;
47 maintainers = with maintainers; [ oyren ];
48 platforms = platforms.linux;
49 };
50}