mesonbuild/meson
在 GitHub 查看Warn when build files use `object.path()` in places where `object` should be used
Open
#2,742 创建于 2017年12月6日
enhancementhelp wantedparser/interpreter
描述
If script.sh exists, has a shebang but is not executable then the following two lines will case an error when trying to invoke the run target.
myscript = find_program('script.sh')
run_target('myscript', command : myscript.path())
I could not track down the exact cause of the problem. When meson searches for the program it will recognize that the file is not executable and look for the shebang. (It might be a good idea to warn about this on *nix platforms.) It then identifies the interpreter and creates an external program with the interpreter and the script file.
When trying to invoke the program in run_script_command the interpreter is lost and we fail to execute the non-executable script.