@@ -1,22 +1,41 @@
1−{ stdenv, fetchurl, pkgconfig, autoreconfHook
2−, glib, gdk_pixbuf, gobject-introspection }:
1+{ stdenv, fetchurl, meson, ninja, pkgconfig, fetchpatch
2+, glib, gdk_pixbuf, gobject-introspection, gnome3 }:
33
44stdenv.mkDerivation rec {
5− ver_maj = "0.7";
6− ver_min = "7";
7− name = "libnotify-${ver_maj}.${ver_min}";
5+ pname = "libnotify";
6+ version = "0.7.8";
87
98 src = fetchurl {
10− url = "mirror://gnome/sources/libnotify/${ver_maj}/${name}.tar.xz";
11− sha256 = "017wgq9n00hx39n0hm784zn18hl721hbaijda868cm96bcqwxd4w";
9+ url = "mirror://gnome/sources/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
10+ sha256 = "1371csx0n92g60b5dmai4mmzdnx8081mc3kcgc6a0xipcq5rw839";
1211 };
1312
14− # disable tests as we don't need to depend on gtk+(2/3)
15− configureFlags = [ "--disable-tests" ];
13+ patches = [
14+ # Fix darwin build
15+ # https://gitlab.gnome.org/GNOME/libnotify/merge_requests/9
16+ (fetchpatch {
17+ url = "https://gitlab.gnome.org/GNOME/libnotify/commit/55eb69247fe2b479ea43311503042fc03bf4e67d.patch";
18+ sha256 = "1hlb5b7c5axiyir1i5j2pi94bm2gyr1ybkp6yaqy7yk6iiqlvv50";
19+ })
20+ ];
1621
17− nativeBuildInputs = [ pkgconfig autoreconfHook gobject-introspection ];
22+ mesonFlags = [
23+ # disable tests as we don't need to depend on gtk+(2/3)
24+ "-Dtests=false"
25+ "-Ddocbook_docs=disabled"
26+ "-Dgtk_doc=false"
27+ ];
28+
29+ nativeBuildInputs = [ meson ninja pkgconfig gobject-introspection ];
1830 buildInputs = [ glib gdk_pixbuf ];
1931
32+ passthru = {
33+ updateScript = gnome3.updateScript {
34+ packageName = pname;
35+ versionPolicy = "none";
36+ };
37+ };
38+
2039 meta = with stdenv.lib; {
2140 homepage = https://developer.gnome.org/notification-spec/;
2241 description = "A library that sends desktop notifications to a notification daemon";