about summary refs log tree commit diff
path: root/nixpkgs/pkgs/desktops/deepin/deepin-mutter/default.nix
blob: 83afe1ee24f729b9cd1356dddea7f572029c3ffb (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
{ stdenv, fetchFromGitHub, pkgconfig, intltool, libtool, gnome3, gtk3,
  xorg, libcanberra-gtk3, upower, xkeyboard_config, libxkbcommon,
  libstartup_notification, libinput, libgudev, cogl, clutter, systemd,
  gsettings-desktop-schemas, deepin-desktop-schemas, wrapGAppsHook,
  deepin }:

stdenv.mkDerivation rec {
  name = "${pname}-${version}";
  pname = "deepin-mutter";
  version = "3.20.38";

  src = fetchFromGitHub {
    owner = "linuxdeepin";
    repo = pname;
    rev = version;
    sha256 = "1aq7606sgn2c6n8wfgxdryw3lprc4va0zjc0r65798w5656fdi31";
  };

  nativeBuildInputs = [
    pkgconfig
    intltool
    libtool
    gnome3.gnome-common
    wrapGAppsHook
    deepin.setupHook
  ];

  buildInputs = [
    clutter
    cogl
    deepin-desktop-schemas
    gnome3.gnome-desktop
    gnome3.zenity
    gsettings-desktop-schemas
    gtk3
    libcanberra-gtk3
    libgudev
    libinput
    libstartup_notification
    libxkbcommon
    systemd
    upower
    xkeyboard_config
    xorg.libxkbfile
  ];

  patches = [
    ./deepin-mutter.plugins-dir.patch
  ];

  postPatch = ''
    searchHardCodedPaths  # debugging
    sed -i -e "s,Exec=deepin-mutter,Exec=$out/bin/deepin-mutter," data/mutter.desktop.in
  '';

  configureFlags = [
    "--enable-native-backend"
    "--enable-compile-warnings=minimum"
  ];

  preConfigure = ''
    NOCONFIGURE=1 ./autogen.sh
  '';

  postFixup = ''
    searchHardCodedPaths $out  # debugging
  '';

  enableParallelBuilding = true;

  passthru.updateScript = deepin.updateScript { inherit name; };

  meta = with stdenv.lib; {
    description = "Base window manager for deepin, fork of gnome mutter";
    homepage = https://github.com/linuxdeepin/deepin-mutter;
    license = licenses.gpl3;
    platforms = platforms.linux;
    maintainers = with maintainers; [ romildo ];
  };
}