build: set have_* dep variables for our features
This allows users to to something like this when wlroots is used as a subproject: wlr_has_xwayland = wlroots.get_variable('have_xwayland') Instead of having to parse conf_data from the subproject object.
This commit is contained in:
parent
6f873078d4
commit
fdd9088e05
|
@ -158,10 +158,16 @@ lib_wlr = library(
|
||||||
link_depends: symbols_file,
|
link_depends: symbols_file,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
wlr_vars = {}
|
||||||
|
foreach name, have : features
|
||||||
|
wlr_vars += { 'have_' + name.underscorify(): have.to_string() }
|
||||||
|
endforeach
|
||||||
|
|
||||||
wlroots = declare_dependency(
|
wlroots = declare_dependency(
|
||||||
link_with: lib_wlr,
|
link_with: lib_wlr,
|
||||||
dependencies: wlr_deps,
|
dependencies: wlr_deps,
|
||||||
include_directories: wlr_inc,
|
include_directories: wlr_inc,
|
||||||
|
variables: wlr_vars,
|
||||||
)
|
)
|
||||||
|
|
||||||
meson.override_dependency('wlroots', wlroots)
|
meson.override_dependency('wlroots', wlroots)
|
||||||
|
|
Loading…
Reference in New Issue