gst_all_1.gstreamer: disable introspection if unavailable

This commit is contained in:
Alyssa Ross 2024-08-15 10:12:42 +02:00
parent af10a338fe
commit b5c88efba7
No known key found for this signature in database
GPG Key ID: F9DBED4859B271C0

View File

@ -15,9 +15,11 @@
, lib
, Cocoa
, CoreServices
, gobject-introspection
, rustc
, testers
, gobject-introspection
, buildPackages
, withIntrospection ? lib.meta.availableOn stdenv.hostPlatform gobject-introspection && stdenv.hostPlatform.emulatorAvailable buildPackages
, libunwind
# darwin.libunwind doesn't have pkg-config definitions so meson doesn't detect it.
, withLibunwind ? !stdenv.isDarwin && lib.meta.availableOn stdenv.hostPlatform libunwind
@ -60,10 +62,11 @@ stdenv.mkDerivation (finalAttrs: {
makeWrapper
glib
bash-completion
gobject-introspection
rustc
] ++ lib.optionals stdenv.isLinux [
libcap # for setcap binary
] ++ lib.optionals withIntrospection [
gobject-introspection
] ++ lib.optionals enableDocumentation [
hotdoc
];
@ -88,6 +91,7 @@ stdenv.mkDerivation (finalAttrs: {
mesonFlags = [
"-Ddbghelp=disabled" # not needed as we already provide libunwind and libdw, and dbghelp is a fallback to those
"-Dexamples=disabled" # requires many dependencies and probably not useful for our users
(lib.mesonEnable "introspection" withIntrospection)
(lib.mesonEnable "doc" enableDocumentation)
(lib.mesonEnable "libunwind" withLibunwind)
(lib.mesonEnable "libdw" withLibunwind)