Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 stdenv, 4 fetchurl, 5 meson, 6 ninja, 7 pkg-config, 8 libxslt, 9 docbook-xsl-ns, 10 glib, 11 gdk-pixbuf, 12 gnome, 13 buildPackages, 14 withIntrospection ? 15 lib.meta.availableOn stdenv.hostPlatform gobject-introspection 16 && stdenv.hostPlatform.emulatorAvailable buildPackages, 17 gobject-introspection, 18}: 19 20stdenv.mkDerivation rec { 21 pname = "libnotify"; 22 version = "0.8.6"; 23 24 outputs = [ 25 "out" 26 "man" 27 "dev" 28 ]; 29 30 src = fetchurl { 31 url = "mirror://gnome/sources/${pname}/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz"; 32 hash = "sha256-xVQKrvtg4dY7HFh8BfIoTr5y7OfQwOXkp3jP1YRLa1g="; 33 }; 34 35 mesonFlags = [ 36 # disable tests as we don't need to depend on GTK (2/3) 37 "-Dtests=false" 38 "-Ddocbook_docs=disabled" 39 "-Dgtk_doc=false" 40 "-Dintrospection=${if withIntrospection then "enabled" else "disabled"}" 41 ]; 42 43 strictDeps = true; 44 45 nativeBuildInputs = [ 46 meson 47 ninja 48 pkg-config 49 libxslt 50 docbook-xsl-ns 51 glib # for glib-mkenums needed during the build 52 ] 53 ++ lib.optionals withIntrospection [ 54 gobject-introspection 55 ]; 56 57 propagatedBuildInputs = [ 58 gdk-pixbuf 59 glib 60 ]; 61 62 passthru = { 63 updateScript = gnome.updateScript { 64 packageName = pname; 65 versionPolicy = "none"; 66 }; 67 }; 68 69 meta = with lib; { 70 description = "Library that sends desktop notifications to a notification daemon"; 71 homepage = "https://gitlab.gnome.org/GNOME/libnotify"; 72 license = licenses.lgpl21; 73 teams = [ teams.gnome ]; 74 mainProgram = "notify-send"; 75 platforms = platforms.unix; 76 }; 77}