2018-04-03 13:17:50 +01:00
|
|
|
{ stdenv, fetchurl, meson, ninja, gettext, pkgconfig, spidermonkey_52, glib
|
2018-12-25 23:29:06 +00:00
|
|
|
, gnome3, gnome-menus, substituteAll }:
|
2016-09-18 20:35:23 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "gnome-shell-extensions";
|
2019-04-18 12:40:10 +01:00
|
|
|
version = "3.32.1";
|
2018-02-25 20:07:20 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2019-08-15 13:41:18 +01:00
|
|
|
url = "mirror://gnome/sources/gnome-shell-extensions/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
|
2019-04-18 12:40:10 +01:00
|
|
|
sha256 = "07libf6z24n42hpdsq163w0j8xyrav0lxqrwxrvq5kbz8zxv5ch2";
|
2018-02-25 20:07:20 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
passthru = {
|
2018-03-13 22:46:11 +00:00
|
|
|
updateScript = gnome3.updateScript {
|
|
|
|
packageName = "gnome-shell-extensions";
|
|
|
|
attrPath = "gnome3.gnome-shell-extensions";
|
|
|
|
};
|
2018-02-25 20:07:20 +00:00
|
|
|
};
|
2016-09-18 20:35:23 +01:00
|
|
|
|
2018-04-03 13:17:50 +01:00
|
|
|
patches = [
|
|
|
|
(substituteAll {
|
|
|
|
src = ./fix_gmenu.patch;
|
2018-12-25 23:29:06 +00:00
|
|
|
gmenu_path = "${gnome-menus}/lib/girepository-1.0";
|
2018-04-03 13:17:50 +01:00
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2016-09-18 20:35:23 +01:00
|
|
|
doCheck = true;
|
2018-12-13 11:48:08 +00:00
|
|
|
# 52 is required for tests
|
|
|
|
# https://gitlab.gnome.org/GNOME/gnome-shell-extensions/blob/3.30.1/meson.build#L25
|
|
|
|
checkInputs = [ spidermonkey_52 ];
|
2016-09-18 20:35:23 +01:00
|
|
|
|
2018-03-13 22:46:11 +00:00
|
|
|
nativeBuildInputs = [ meson ninja pkgconfig gettext glib ];
|
2016-09-18 20:35:23 +01:00
|
|
|
|
2018-03-13 22:46:11 +00:00
|
|
|
mesonFlags = [ "-Dextension_set=all" ];
|
2017-09-13 22:41:02 +01:00
|
|
|
|
2018-04-02 11:31:04 +01:00
|
|
|
preFixup = ''
|
|
|
|
# The meson build doesn't compile the schemas.
|
|
|
|
# Fixup adapted from export-zips.sh in the source.
|
|
|
|
|
|
|
|
extensiondir=$out/share/gnome-shell/extensions
|
2019-08-26 08:44:25 +01:00
|
|
|
schemadir=${glib.makeSchemaPath "$out" "${pname}-${version}"}
|
2018-04-02 11:31:04 +01:00
|
|
|
|
|
|
|
glib-compile-schemas $schemadir
|
|
|
|
|
|
|
|
for f in $extensiondir/*; do
|
|
|
|
name=`basename ''${f%%@*}`
|
|
|
|
uuid=$name@gnome-shell-extensions.gcampax.github.com
|
|
|
|
schema=$schemadir/org.gnome.shell.extensions.$name.gschema.xml
|
|
|
|
|
|
|
|
if [ -f $schema ]; then
|
|
|
|
mkdir $f/schemas
|
|
|
|
ln -s $schema $f/schemas;
|
|
|
|
glib-compile-schemas $f/schemas
|
|
|
|
fi
|
|
|
|
done
|
|
|
|
'';
|
|
|
|
|
2016-09-18 20:35:23 +01:00
|
|
|
meta = with stdenv.lib; {
|
|
|
|
homepage = https://wiki.gnome.org/Projects/GnomeShell/Extensions;
|
|
|
|
description = "Modify and extend GNOME Shell functionality and behavior";
|
|
|
|
maintainers = gnome3.maintainers;
|
|
|
|
license = licenses.gpl2;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|