1{ lib
2, clangStdenv
3, fetchFromGitLab
4, rustPlatform
5, cargo
6, meson
7, ninja
8, pkg-config
9, rustc
10, glib
11, gtk4
12, libadwaita
13, zbar
14, sqlite
15, openssl
16, pipewire
17, gstreamer
18, gst-plugins-base
19, gst-plugins-bad
20, wrapGAppsHook4
21, appstream-glib
22, desktop-file-utils
23}:
24
25clangStdenv.mkDerivation rec {
26 pname = "gnome-decoder";
27 version = "0.3.3";
28
29 src = fetchFromGitLab {
30 domain = "gitlab.gnome.org";
31 owner = "World";
32 repo = "decoder";
33 rev = version;
34 hash = "sha256-eMyPN3UxptqavY9tEATW2AP+kpoWaLwUKCwhNQrarVc=";
35 };
36
37 cargoDeps = rustPlatform.fetchCargoTarball {
38 inherit src;
39 name = "${pname}-${version}";
40 hash = "sha256-3j1hoFffQzWBy4IKtmoMkLBJmNbntpyn0sjv1K0MmDo=";
41 };
42
43 nativeBuildInputs = [
44 meson
45 ninja
46 pkg-config
47 wrapGAppsHook4
48 appstream-glib
49 desktop-file-utils
50 cargo
51 rustc
52 rustPlatform.bindgenHook
53 rustPlatform.cargoSetupHook
54 ];
55
56 buildInputs = [
57 glib
58 gtk4
59 libadwaita
60 zbar
61 sqlite
62 openssl
63 pipewire
64 gstreamer
65 gst-plugins-base
66 gst-plugins-bad
67 ];
68
69 meta = with lib; {
70 description = "Scan and Generate QR Codes";
71 homepage = "https://gitlab.gnome.org/World/decoder";
72 license = licenses.gpl3Plus;
73 platforms = platforms.linux;
74 mainProgram = "decoder";
75 maintainers = with maintainers; [ zendo ];
76 };
77}