1{
2 lib,
3 appstream,
4 blueprint-compiler,
5 desktop-file-utils,
6 fetchFromGitLab,
7 glib,
8 gobject-introspection,
9 gtk4,
10 libadwaita,
11 meson,
12 ninja,
13 nix-update-script,
14 pandoc,
15 pkg-config,
16 python3Packages,
17 webkitgtk_6_0,
18 wrapGAppsHook4,
19}:
20
21python3Packages.buildPythonApplication rec {
22 pname = "morphosis";
23 version = "48.2";
24 pyproject = false;
25
26 src = fetchFromGitLab {
27 domain = "gitlab.gnome.org";
28 owner = "World";
29 repo = "morphosis";
30 tag = version;
31 hash = "sha256-wDEhXIt1iup7QxKsmWUjQZGTEZhOuNjpLqzpqs+TPHo=";
32 };
33
34 strictDeps = true;
35
36 nativeBuildInputs = [
37 appstream
38 blueprint-compiler
39 desktop-file-utils
40 glib # For `glib-compile-schemas`
41 gobject-introspection
42 gtk4 # For `gtk-update-icon-cache`
43 meson
44 ninja
45 pkg-config
46 wrapGAppsHook4
47 ];
48
49 buildInputs = [
50 libadwaita
51 webkitgtk_6_0
52 ];
53
54 dependencies = with python3Packages; [ pygobject3 ];
55
56 dontWrapGApps = true;
57 makeWrapperArgs = [
58 "\${gappsWrapperArgs[@]}"
59 "--prefix PATH : ${lib.makeBinPath [ pandoc ]}"
60 ];
61
62 passthru = {
63 updateScript = nix-update-script { };
64 };
65
66 meta = {
67 description = "Convert your documents";
68 homepage = "https://gitlab.gnome.org/World/morphosis";
69 license = lib.licenses.gpl3Only;
70 maintainers = with lib.maintainers; [ getchoo ];
71 mainProgram = "morphosis";
72 platforms = lib.platforms.linux;
73 };
74}