meson: make use of override_dependency() if possible
This allows simplifying the subproject override to simply ```meson dependency('libpkgconf') ```pull/237/head
parent
b5cfc75b58
commit
f6b28e85d6
|
@ -78,6 +78,12 @@ dep_libpkgconf = declare_dependency(
|
|||
include_directories : include_directories('.'),
|
||||
)
|
||||
|
||||
# If we have a new enough meson override the dependency so that only
|
||||
# `dependency('libpkgconf')` is required from the consumer
|
||||
if meson.version().version_compare('>= 0.54.0')
|
||||
meson.override_dependency('libpkgconf', dep_libpkgconf)
|
||||
endif
|
||||
|
||||
pkg = import('pkgconfig')
|
||||
pkg.generate(libpkgconf,
|
||||
name : 'libpkgconf',
|
||||
|
|
Loading…
Reference in New Issue