2019-12-04 13:23:14 -08:00
|
|
|
{ fetchurl
|
|
|
|
, fetchpatch
|
|
|
|
, substituteAll
|
|
|
|
, stdenv
|
|
|
|
, pkgconfig
|
|
|
|
, gnome3
|
|
|
|
, gettext
|
|
|
|
, gobject-introspection
|
|
|
|
, upower
|
|
|
|
, cairo
|
|
|
|
, pango
|
|
|
|
, cogl
|
|
|
|
, json-glib
|
|
|
|
, libstartup_notification
|
|
|
|
, zenity
|
|
|
|
, libcanberra-gtk3
|
|
|
|
, ninja
|
|
|
|
, xkeyboard_config
|
|
|
|
, libxkbfile
|
|
|
|
, libxkbcommon
|
|
|
|
, libXtst
|
|
|
|
, libinput
|
|
|
|
, gsettings-desktop-schemas
|
|
|
|
, glib
|
|
|
|
, gtk3
|
|
|
|
, gnome-desktop
|
|
|
|
, geocode-glib
|
|
|
|
, pipewire
|
|
|
|
, libgudev
|
|
|
|
, libwacom
|
|
|
|
, xwayland
|
|
|
|
, meson
|
2019-03-03 10:30:10 -08:00
|
|
|
, gnome-settings-daemon
|
|
|
|
, xorgserver
|
|
|
|
, python3
|
|
|
|
, wrapGAppsHook
|
2019-09-09 12:47:10 -07:00
|
|
|
, sysprof
|
|
|
|
, desktop-file-utils
|
2019-10-19 06:15:20 -07:00
|
|
|
, libcap_ng
|
2019-09-27 14:31:31 -07:00
|
|
|
, egl-wayland
|
2019-03-03 10:30:10 -08:00
|
|
|
}:
|
2016-09-18 12:35:23 -07:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-04-18 01:29:48 -07:00
|
|
|
pname = "mutter";
|
2020-02-16 23:35:39 -08:00
|
|
|
version = "3.34.4";
|
2018-02-25 12:07:20 -08:00
|
|
|
|
2019-07-04 05:32:34 -07:00
|
|
|
outputs = [ "out" "dev" "man" ];
|
|
|
|
|
2018-02-25 12:07:20 -08:00
|
|
|
src = fetchurl {
|
2019-04-18 01:29:48 -07:00
|
|
|
url = "mirror://gnome/sources/mutter/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
|
2020-02-16 23:35:39 -08:00
|
|
|
sha256 = "18hbw98p4h3d4qz57415smwmfg72s9a0nk8mb04ds1gn2lsm2d01";
|
2018-02-25 12:07:20 -08:00
|
|
|
};
|
|
|
|
|
2019-03-03 10:30:10 -08:00
|
|
|
mesonFlags = [
|
2019-12-04 13:23:14 -08:00
|
|
|
"-Degl_device=true"
|
2019-07-04 05:32:25 -07:00
|
|
|
"-Dinstalled_tests=false" # TODO: enable these
|
2019-09-27 14:31:31 -07:00
|
|
|
"-Dwayland_eglstream=true"
|
2019-12-04 13:23:14 -08:00
|
|
|
"-Dxwayland-path=${xwayland}/bin/Xwayland"
|
2017-11-03 15:30:56 -07:00
|
|
|
];
|
2016-09-18 12:35:23 -07:00
|
|
|
|
2017-06-25 09:59:23 -07:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
# required for pkgconfig to detect mutter-clutter
|
2019-10-19 06:03:17 -07:00
|
|
|
json-glib
|
2019-12-04 13:23:14 -08:00
|
|
|
libXtst
|
2019-10-19 06:15:20 -07:00
|
|
|
libcap_ng
|
2017-06-25 09:59:23 -07:00
|
|
|
];
|
|
|
|
|
2019-03-03 10:30:10 -08:00
|
|
|
nativeBuildInputs = [
|
2019-12-04 13:23:14 -08:00
|
|
|
desktop-file-utils
|
2019-03-03 10:30:10 -08:00
|
|
|
gettext
|
2019-12-04 13:23:14 -08:00
|
|
|
meson
|
2019-03-03 10:30:10 -08:00
|
|
|
ninja
|
2019-12-04 13:23:14 -08:00
|
|
|
pkgconfig
|
2019-03-03 10:30:10 -08:00
|
|
|
python3
|
|
|
|
wrapGAppsHook
|
2019-12-04 13:23:14 -08:00
|
|
|
xorgserver # for cvt command
|
2019-03-03 10:30:10 -08:00
|
|
|
];
|
2017-11-03 14:48:50 -07:00
|
|
|
|
2019-02-13 13:47:50 -08:00
|
|
|
buildInputs = [
|
2019-12-04 13:23:14 -08:00
|
|
|
cairo
|
|
|
|
cogl
|
|
|
|
egl-wayland
|
|
|
|
geocode-glib
|
|
|
|
glib
|
|
|
|
gnome-desktop
|
|
|
|
gnome-settings-daemon
|
|
|
|
gobject-introspection
|
|
|
|
gsettings-desktop-schemas
|
|
|
|
gtk3
|
|
|
|
libcanberra-gtk3
|
|
|
|
libgudev
|
|
|
|
libinput
|
|
|
|
libstartup_notification
|
|
|
|
libwacom
|
|
|
|
libxkbcommon
|
|
|
|
libxkbfile
|
|
|
|
pango
|
|
|
|
pipewire
|
|
|
|
sysprof
|
|
|
|
upower
|
|
|
|
xkeyboard_config
|
|
|
|
xwayland
|
|
|
|
zenity
|
|
|
|
zenity
|
2017-12-16 16:22:42 -08:00
|
|
|
];
|
2016-09-18 12:35:23 -07:00
|
|
|
|
2019-03-31 16:31:17 -07:00
|
|
|
patches = [
|
2019-12-04 13:51:56 -08:00
|
|
|
# Fix build with libglvnd provided headers
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://gitlab.gnome.org/GNOME/mutter/commit/a444a4c5f58ea516ad3cd9d6ddc0056c3ca9bc90.patch";
|
|
|
|
sha256 = "0imy2j8af9477jliwdq4jc40yw1cifsjjf196gnmwxr9rkj0hbrd";
|
|
|
|
})
|
|
|
|
|
2019-10-19 06:15:20 -07:00
|
|
|
# Drop inheritable cap_sys_nice, to prevent the ambient set from leaking
|
|
|
|
# from mutter/gnome-shell, see https://github.com/NixOS/nixpkgs/issues/71381
|
|
|
|
./drop-inheritable.patch
|
2019-12-04 13:51:56 -08:00
|
|
|
|
2019-12-04 13:23:14 -08:00
|
|
|
# TODO: submit upstream
|
|
|
|
./0001-build-use-get_pkgconfig_variable-for-sysprof-dbusdir.patch
|
2019-12-04 13:51:56 -08:00
|
|
|
|
2019-03-31 16:31:17 -07:00
|
|
|
(substituteAll {
|
|
|
|
src = ./fix-paths.patch;
|
|
|
|
inherit zenity;
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2019-03-03 10:30:10 -08:00
|
|
|
postPatch = ''
|
|
|
|
patchShebangs src/backends/native/gen-default-modes.py
|
|
|
|
'';
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
${glib.dev}/bin/glib-compile-schemas "$out/share/glib-2.0/schemas"
|
2016-09-18 12:35:23 -07:00
|
|
|
'';
|
|
|
|
|
2019-02-13 13:47:50 -08:00
|
|
|
passthru = {
|
|
|
|
updateScript = gnome3.updateScript {
|
2019-12-04 13:23:14 -08:00
|
|
|
packageName = pname;
|
|
|
|
attrPath = "gnome3.${pname}";
|
2019-02-13 13:47:50 -08:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2016-09-18 12:35:23 -07:00
|
|
|
meta = with stdenv.lib; {
|
2019-12-04 13:23:14 -08:00
|
|
|
description = "A window manager for GNOME";
|
|
|
|
homepage = "https://gitlab.gnome.org/GNOME/mutter";
|
2017-12-16 16:22:42 -08:00
|
|
|
license = licenses.gpl2;
|
2019-12-04 13:23:14 -08:00
|
|
|
maintainers = gnome3.maintainers;
|
|
|
|
platforms = platforms.linux;
|
2016-09-18 12:35:23 -07:00
|
|
|
};
|
|
|
|
}
|