nixpkgs/pkgs/development/libraries/gupnp/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

103 lines
2.2 KiB
Nix
Raw Normal View History

2021-10-20 15:59:12 +00:00
{ stdenv
, lib
, fetchurl
2023-07-10 23:20:54 +00:00
, fetchpatch2
, meson
, ninja
, pkg-config
, gobject-introspection
, vala
, gtk-doc
, docbook_xsl
, docbook_xml_dtd_412
, docbook_xml_dtd_45
, glib
, gssdp
, libsoup
, libxml2
, libuuid
, gnome
}:
stdenv.mkDerivation rec {
pname = "gupnp";
version = "1.4.4";
2021-08-23 19:17:51 +00:00
outputs = [ "out" "dev" ]
++ lib.optionals (stdenv.buildPlatform == stdenv.hostPlatform) [ "devdoc" ];
2015-08-03 20:49:39 +00:00
src = fetchurl {
url = "mirror://gnome/sources/gupnp/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
sha256 = "sha256-N2GxXLBjYh+Efz7/t9djfwMXUA/Ka9oeGQT3OSF1Ch8=";
};
2021-06-28 21:13:42 +00:00
patches = [
2021-10-20 15:59:12 +00:00
# Bring .pc file in line with our patched pkg-config.
./0001-pkg-config-Declare-header-dependencies-as-public.patch
2023-07-10 23:20:54 +00:00
# Unbreak build with Meson 1.2.0
# https://gitlab.gnome.org/GNOME/gupnp/-/merge_requests/33
(fetchpatch2 {
name = "meson-1.2-fix.patch";
url = "https://gitlab.gnome.org/GNOME/gupnp/-/commit/85c0244cfbf933d3e90d50ab68394c68d86f9ed5.patch";
hash = "sha256-poDhkEgDTpgGnTbbZLPwx8Alf0h81vmzJyx3izWmDGw=";
})
2023-07-10 23:20:54 +00:00
# Fix build against libxml2 2.11
# https://gitlab.gnome.org/GNOME/gupnp/-/merge_requests/34
(fetchpatch2 {
name = "libxml2-2.11-fix.patch";
2023-07-10 23:20:54 +00:00
url = "https://gitlab.gnome.org/GNOME/gupnp/-/commit/bc56f02b0f89e96f2bd74af811903d9931965f58.patch";
hash = "sha256-KCHlq7Es+WLIWKgIgGVTaHarVQIiZPEi5r6nMAhXTgY=";
})
2021-06-28 21:13:42 +00:00
];
2021-08-23 19:17:51 +00:00
depsBuildBuild = [
pkg-config
];
nativeBuildInputs = [
meson
ninja
pkg-config
gobject-introspection
vala
gtk-doc
docbook_xsl
docbook_xml_dtd_412
docbook_xml_dtd_45
];
buildInputs = [
libuuid
];
propagatedBuildInputs = [
glib
gssdp
libsoup
libxml2
];
mesonFlags = [
2021-08-23 19:17:51 +00:00
"-Dgtk_doc=${lib.boolToString (stdenv.buildPlatform == stdenv.hostPlatform)}"
];
2022-10-20 01:04:08 +00:00
# Bail out! ERROR:../tests/test-bugs.c:168:test_on_timeout: code should not be reached
doCheck = !stdenv.isDarwin;
passthru = {
updateScript = gnome.updateScript {
packageName = pname;
freeze = true;
};
};
meta = with lib; {
homepage = "http://www.gupnp.org/";
description = "An implementation of the UPnP specification";
license = licenses.lgpl2Plus;
2022-10-20 01:04:08 +00:00
platforms = platforms.unix;
};
}