2022-05-23 09:44:39 +02:00
|
|
|
xwayland_feature_names = [
|
|
|
|
'listenfd',
|
|
|
|
'no_touch_pointer_emulation',
|
|
|
|
'force_xrandr_emulation',
|
|
|
|
'terminate_delay',
|
|
|
|
]
|
|
|
|
|
|
|
|
xwayland_features = {}
|
2021-02-04 17:56:28 +01:00
|
|
|
if xwayland.found()
|
2021-09-15 19:01:14 +02:00
|
|
|
xwayland_path = xwayland.get_variable('xwayland')
|
2022-05-23 09:44:39 +02:00
|
|
|
foreach name : xwayland_feature_names
|
|
|
|
have = xwayland.get_variable('have_' + name, default_value: 'false') == 'true'
|
|
|
|
xwayland_features += { name: have }
|
|
|
|
endforeach
|
2021-02-04 17:56:28 +01:00
|
|
|
else
|
|
|
|
xwayland_path = xwayland_prog.full_path()
|
2022-05-23 09:44:39 +02:00
|
|
|
foreach name : xwayland_feature_names
|
|
|
|
xwayland_features += { name: false }
|
|
|
|
endforeach
|
2021-02-04 17:56:28 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
xwayland_config_data = configuration_data()
|
|
|
|
xwayland_config_data.set_quoted('XWAYLAND_PATH', xwayland_path)
|
2022-05-23 09:44:39 +02:00
|
|
|
foreach name, have : xwayland_features
|
|
|
|
xwayland_config_data.set10('HAVE_XWAYLAND_' + name.to_upper(), have)
|
|
|
|
endforeach
|
2021-02-04 17:56:28 +01:00
|
|
|
configure_file(
|
|
|
|
output: 'config.h',
|
|
|
|
configuration: xwayland_config_data,
|
|
|
|
)
|