Merge pull request #217701 from Mindavi/libmbim/cross

This commit is contained in:
Artturi 2023-03-26 21:52:59 +03:00 committed by GitHub
commit 1841f6d1b8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -9,8 +9,10 @@
, help2man
, systemd
, bash-completion
, bash
, buildPackages
, withIntrospection ? stdenv.hostPlatform.emulatorAvailable buildPackages
, withDocs ? stdenv.hostPlatform == stdenv.buildPlatform
, gobject-introspection
}:
@ -18,7 +20,8 @@ stdenv.mkDerivation rec {
pname = "libmbim";
version = "1.28.4";
outputs = [ "out" "dev" "man" ];
outputs = [ "out" "dev" ]
++ lib.optionals withDocs [ "man" ];
src = fetchFromGitLab {
domain = "gitlab.freedesktop.org";
@ -31,14 +34,19 @@ stdenv.mkDerivation rec {
mesonFlags = [
"-Dudevdir=${placeholder "out"}/lib/udev"
(lib.mesonBool "introspection" withIntrospection)
(lib.mesonBool "man" withDocs)
];
strictDeps = true;
nativeBuildInputs = [
meson
ninja
pkg-config
python3
] ++ lib.optionals withDocs [
help2man
] ++ lib.optionals withIntrospection [
gobject-introspection
];
@ -46,6 +54,7 @@ stdenv.mkDerivation rec {
glib
systemd
bash-completion
bash
];
doCheck = true;