1{
2 lib,
3 stdenv,
4 fetchFromGitHub,
5 pkg-config,
6 python3,
7 xmlbird,
8 cairo,
9 gdk-pixbuf,
10 libgee,
11 glib,
12 gtk3,
13 webkitgtk_4_1,
14 libnotify,
15 sqlite,
16 vala,
17 gobject-introspection,
18 gsettings-desktop-schemas,
19 wrapGAppsHook3,
20 autoPatchelfHook,
21 nix-update-script,
22}:
23
24stdenv.mkDerivation (finalAttrs: {
25 pname = "birdfont";
26 version = "2.33.6";
27
28 src = fetchFromGitHub {
29 owner = "johanmattssonm";
30 repo = "birdfont";
31 tag = "v${finalAttrs.version}";
32 sha256 = "sha256-7xVjY/yH7pMlUBpQc5Gb4t4My24Mx5KkARVp2KSr+Iw=";
33 };
34
35 nativeBuildInputs = [
36 python3
37 pkg-config
38 vala
39 gobject-introspection
40 wrapGAppsHook3
41 autoPatchelfHook
42 ];
43 buildInputs = [
44 xmlbird
45 libgee
46 cairo
47 gdk-pixbuf
48 glib
49 gtk3
50 webkitgtk_4_1
51 libnotify
52 sqlite
53 gsettings-desktop-schemas
54 ];
55
56 postPatch = ''
57 substituteInPlace install.py \
58 --replace 'platform.version()' '"Nix"'
59
60 patchShebangs .
61 '';
62
63 buildPhase = "./build.py";
64
65 installPhase = "./install.py";
66
67 passthru.updateScript = nix-update-script { };
68
69 meta = with lib; {
70 description = "Font editor which can generate fonts in TTF, EOT, SVG and BIRDFONT format";
71 homepage = "https://birdfont.org";
72 license = licenses.gpl3;
73 maintainers = with maintainers; [ dtzWill ];
74 };
75})