gupnp: fix cross-compilation

This commit is contained in:
Rick van Schijndel 2021-08-23 21:17:51 +02:00
parent b827b46c8d
commit 856ca0f52f

View File

@ -22,7 +22,8 @@ stdenv.mkDerivation rec {
pname = "gupnp";
version = "1.4.0";
outputs = [ "out" "dev" "devdoc" ];
outputs = [ "out" "dev" ]
++ lib.optionals (stdenv.buildPlatform == stdenv.hostPlatform) [ "devdoc" ];
src = fetchurl {
url = "mirror://gnome/sources/gupnp/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
@ -34,6 +35,10 @@ stdenv.mkDerivation rec {
./0001-pkg-config-Declare-header-dependencies-as-public.patch
];
depsBuildBuild = [
pkg-config
];
nativeBuildInputs = [
meson
ninja
@ -58,7 +63,8 @@ stdenv.mkDerivation rec {
];
mesonFlags = [
"-Dgtk_doc=true"
"-Dgtk_doc=${lib.boolToString (stdenv.buildPlatform == stdenv.hostPlatform)}"
"-Dintrospection=${lib.boolToString (stdenv.buildPlatform == stdenv.hostPlatform)}"
];
doCheck = true;