mirror of
https://github.com/ZoiteChat/zoitechat.git
synced 2026-10-28 14:15:38 +00:00
meson: explicitly mark run_command as fallible when returncode is checked
Meson emits a warning stating that the default will change from false to true, in some future version, and that one should always pass `check: BOOL` explicitly. Normally this is because commands that unexpectedly fail would result in wrong behavior if the build treats it as though it succeeded. In this case, we were specifically relying on it being `check: false`, as the returncode is immediately checked in order to provide a better error message. Make this explicit in the meson.build file. Signed-off-by: Eli Schwartz <[email protected]>
This commit is contained in:
1 file changed
+2
-2
@@ -28,7 +28,7 @@ endif
|
||||
|
||||
perl = find_program(get_option('with-perl'))
|
||||
|
||||
ret = run_command([perl, '-MExtUtils::Embed', '-e', 'ccopts'])
|
||||
ret = run_command([perl, '-MExtUtils::Embed', '-e', 'ccopts'], check: false)
|
||||
if ret.returncode() != 0
|
||||
error('perl: Failed to get cflags')
|
||||
endif
|
||||
@@ -38,7 +38,7 @@ foreach flag : ret.stdout().strip().split(' ')
|
||||
endif
|
||||
endforeach
|
||||
|
||||
ret = run_command([perl, '-MExtUtils::Embed', '-e', 'ldopts'])
|
||||
ret = run_command([perl, '-MExtUtils::Embed', '-e', 'ldopts'], check: false)
|
||||
if ret.returncode() != 0
|
||||
error('perl: Failed to get ldflags')
|
||||
endif
|
||||
|
||||
Reference in new issue
Block a user