Merge pull request #175998 from Mindavi/feedbackd/cross

feedbackd: support cross-compilation
This commit is contained in:
Rick van Schijndel 2022-06-08 21:02:46 +02:00 committed by GitHub
commit dd16129445
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -32,7 +32,9 @@ stdenv.mkDerivation rec {
# only a Debian package release that is tagged in the upstream repo
version = "0.0.0+git20220520";
outputs = [ "out" "dev" "devdoc" ];
outputs = [ "out" "dev" ]
# remove if cross-compiling gobject-introspection works
++ lib.optionals (stdenv.buildPlatform == stdenv.hostPlatform) [ "devdoc" ];
src = fetchFromGitLab {
domain = "source.puri.sm";
@ -61,7 +63,13 @@ stdenv.mkDerivation rec {
libgudev
];
mesonFlags = [ "-Dgtk_doc=true" "-Dman=true" ];
mesonFlags = [
"-Dgtk_doc=${lib.boolToString (stdenv.buildPlatform == stdenv.hostPlatform)}"
"-Dman=true"
# TODO(mindavi): introspection broken due to https://github.com/NixOS/nixpkgs/issues/72868
# can be removed if cross-compiling gobject-introspection works.
"-Dintrospection=${if (stdenv.buildPlatform == stdenv.hostPlatform) then "enabled" else "disabled"}"
];
checkInputs = [
dbus