Git fork
at reftables-rust 28 lines 1.1 kB view raw
1bin_wrappers_config = configuration_data() 2foreach key, value : { 3 'BUILD_DIR': meson.project_build_root(), 4 'MERGE_TOOLS_DIR': meson.project_source_root() / 'mergetools', 5 'TEMPLATE_DIR': meson.project_build_root() / 'templates', 6 'GIT_TEXTDOMAINDIR': meson.project_build_root() / 'po', 7 'GITPERLLIB': meson.project_build_root() / 'perl/lib', 8} 9 # Paths need to be Unix-style without drive prefixes as they get added to the 10 # PATH variable. And given that drive prefixes contain a colon we'd otherwise 11 # end up with a broken PATH if we didn't convert them. 12 if cygpath.found() 13 value = run_command(cygpath, value, check: true).stdout().strip() 14 endif 15 bin_wrappers_config.set(key, value) 16endforeach 17 18foreach executable : bin_wrappers 19 executable_config = configuration_data() 20 executable_config.merge_from(bin_wrappers_config) 21 executable_config.set('PROG', executable.full_path()) 22 23 configure_file( 24 input: 'wrap-for-bin.sh', 25 output: fs.stem(executable.full_path()), 26 configuration: executable_config, 27 ) 28endforeach