From: Barnabás Pőcze Date: Tue, 13 Jun 2023 16:12:26 +0000 (+0200) Subject: meson: Override "dbus-1" dependency name X-Git-Tag: dbus-1.15.8~35^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=67036a2fdff86741bb4f22e55c039466be8dfbef;p=thirdparty%2Fdbus.git meson: Override "dbus-1" dependency name Since meson 0.54.0, it is possible to override a dependency name, so do that to make it easy to use dbus as a subproject. After this change, simply dependency('dbus-1') will fall back to the subproject automatically and there is no need for using `fallback` keyword argument. Of course this assumes that the dbus source tree is at subprojects/dbus-1 and not subprojects/dbus but it is easy to achieve that. If the dbus source tree for some reason needs to be at subprojects/dbus, dependency('dbus-1', fallback: 'dbus') may be used, which still has the advantage of not needing to depend on the variable names in the dbus build definitions. --- diff --git a/dbus/meson.build b/dbus/meson.build index 6bdb649ef..70b16f5eb 100644 --- a/dbus/meson.build +++ b/dbus/meson.build @@ -209,6 +209,8 @@ libdbus_dep = declare_dependency( link_with: libdbus, ) +meson.override_dependency('dbus-1', libdbus_dep) + libdbus_internal = static_library('dbus-internal', dbus_util_sources,