mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-13 16:34:27 +00:00
6ae50e12ee
Since b2f9cd34e7
("gobject-introspection: use wrapper.nix for the
native package too so we can propagate the dev output"),
gobject-introspection doesn't need to be included in buildInputs when
it's in nativeBuildInputs, as it's propagated from the setup hook.
Removing the build input fixes evaluation in buildPackages when
cross-compiling to platforms that gobject-introspection is unsupported
on, like ghcjs.
Tested building natively on x86_64-linux, in
pkgsCross.aarch64-multiplatform, and in pkgsCross.ghcjs.buildPackages.
68 lines
1.4 KiB
Nix
68 lines
1.4 KiB
Nix
{ lib, stdenv
|
|
, fetchurl
|
|
, meson
|
|
, ninja
|
|
, pkg-config
|
|
, libxslt
|
|
, docbook-xsl-ns
|
|
, glib
|
|
, gdk-pixbuf
|
|
, gnome
|
|
, withIntrospection ? (stdenv.buildPlatform == stdenv.hostPlatform)
|
|
, gobject-introspection
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "libnotify";
|
|
version = "0.8.1";
|
|
|
|
outputs = [ "out" "man" "dev" ];
|
|
|
|
src = fetchurl {
|
|
url = "mirror://gnome/sources/${pname}/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
|
|
sha256 = "0DPm1NbMv0akNsMWKKS2YbNtyh9dQXT+AXPidPTmJVc=";
|
|
};
|
|
|
|
mesonFlags = [
|
|
# disable tests as we don't need to depend on GTK (2/3)
|
|
"-Dtests=false"
|
|
"-Ddocbook_docs=disabled"
|
|
"-Dgtk_doc=false"
|
|
"-Dintrospection=${if withIntrospection then "enabled" else "disabled"}"
|
|
];
|
|
|
|
strictDeps = true;
|
|
|
|
nativeBuildInputs = [
|
|
meson
|
|
ninja
|
|
pkg-config
|
|
libxslt
|
|
docbook-xsl-ns
|
|
glib # for glib-mkenums needed during the build
|
|
] ++ lib.optionals withIntrospection [
|
|
gobject-introspection
|
|
];
|
|
|
|
propagatedBuildInputs = [
|
|
gdk-pixbuf
|
|
glib
|
|
];
|
|
|
|
passthru = {
|
|
updateScript = gnome.updateScript {
|
|
packageName = pname;
|
|
versionPolicy = "none";
|
|
};
|
|
};
|
|
|
|
meta = with lib; {
|
|
description = "A library that sends desktop notifications to a notification daemon";
|
|
homepage = "https://gitlab.gnome.org/GNOME/libnotify";
|
|
license = licenses.lgpl21;
|
|
maintainers = teams.gnome.members;
|
|
mainProgram = "notify-send";
|
|
platforms = platforms.unix;
|
|
};
|
|
}
|