1dbus_service_files = [ 2 'org.freedesktop.portal.Documents.service', 3 'org.gtk.GDBus.FakeService.service' 4] 5 6srcdir_cdata = configuration_data() 7srcdir_cdata.set('installed_tests_dir', meson.current_build_dir() / '..') 8 9installed_cdata = configuration_data() 10installed_cdata.set('installed_tests_dir', installed_tests_execdir) 11 12foreach service_file : dbus_service_files 13 configure_file( 14 input: service_file + '.in', 15 output: service_file, 16 configuration: srcdir_cdata, 17 ) 18 if installed_tests_enabled 19 # Build a second copy of the service file for the installed 20 # version of the tests. 21 configure_file( 22 input: service_file + '.in', 23 output: service_file + '.to-install', 24 configuration: installed_cdata, 25 ) 26 install_data(meson.current_build_dir() / service_file + '.to-install', 27 install_dir: installed_tests_execdir / 'services', 28 rename: [service_file], 29 ) 30 endif 31endforeach 32