bottom: add gpu recognition, new apple sdk, refactor (#360568)
[NixPkgs.git] / pkgs / by-name / em / emblem / package.nix
blob5cf592125649bc85ebb7efe5284ba8f294559125
2   lib,
3   stdenv,
4   fetchFromGitLab,
5   rustPlatform,
6   cargo,
7   desktop-file-utils,
8   glib,
9   meson,
10   ninja,
11   pkg-config,
12   rustc,
13   wrapGAppsHook4,
14   libadwaita,
15   libxml2,
16   darwin,
19 stdenv.mkDerivation rec {
20   pname = "emblem";
21   version = "1.4.0";
23   src = fetchFromGitLab {
24     domain = "gitlab.gnome.org";
25     group = "World";
26     owner = "design";
27     repo = "emblem";
28     rev = version;
29     sha256 = "sha256-pW+2kQANZ9M1f0jMoBqCxMjLCu0xAnuEE2EdzDq4ZCE=";
30   };
32   cargoDeps = rustPlatform.fetchCargoTarball {
33     inherit src;
34     name = "${pname}-${version}";
35     hash = "sha256-2mxDXDGQA2YB+gnGwy6VSZP/RRBKg0RiR1GlXIkio9E=";
36   };
38   nativeBuildInputs = [
39     desktop-file-utils
40     glib
41     meson
42     ninja
43     pkg-config
44     wrapGAppsHook4
45     rustPlatform.cargoSetupHook
46     cargo
47     rustc
48   ];
50   buildInputs =
51     [
52       libadwaita
53       libxml2
54     ]
55     ++ lib.optionals stdenv.hostPlatform.isDarwin [
56       darwin.apple_sdk.frameworks.Foundation
57     ];
59   env.NIX_CFLAGS_COMPILE = toString (
60     lib.optionals stdenv.hostPlatform.isDarwin [
61       "-Wno-error=incompatible-function-pointer-types"
62     ]
63   );
65   meta = {
66     description = "Generate project icons and avatars from a symbolic icon";
67     mainProgram = "emblem";
68     homepage = "https://gitlab.gnome.org/World/design/emblem";
69     license = lib.licenses.gpl3Plus;
70     platforms = lib.platforms.unix;
71     maintainers =
72       with lib.maintainers;
73       [
74         figsoda
75         foo-dogsquared
76       ]
77       ++ lib.teams.gnome-circle.members;
78   };