meson: fix various meson build warnings and formatting
- Make run_command() calls check for failures to fix warnings about
ignoring errors, see https://github.com/mesonbuild/meson/issues/9300.
- Remove `include_directories('../subprojects')` from tests/meson.build.
It isn't necessary and caused build warnings due to referencing files
outside the tests/ directory.
- Fix indent level and formatting in a few places.
Tested: meson; ninja; ninja test
Change-Id: I17ae0c51d68ed004772a237641f08345f4893200
Signed-off-by: Nikolai Artemiev <nartemiev@google.com>
Original-Reviewed-on: https://review.coreboot.org/c/flashrom/+/66060
Original-Reviewed-by: Thomas Heijligen <src@posteo.de>
Original-Reviewed-by: Anastasia Klimchuk <aklm@chromium.org>
Reviewed-on: https://review.coreboot.org/c/flashrom-stable/+/72341
Reviewed-by: Nico Huber <nico.h@gmx.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
diff --git a/meson.build b/meson.build
index c111c0e..03ffbc9 100644
--- a/meson.build
+++ b/meson.build
@@ -1,5 +1,5 @@
project('flashromutils', 'c',
- version : run_command('util/getversion.sh', '--version').stdout().strip(),
+ version : run_command('util/getversion.sh', '--version', check : true).stdout().strip(),
license : 'GPL-2.0',
meson_version : '>=0.50.0',
default_options : [
@@ -7,7 +7,8 @@
'c_std=c99',
'werror=true',
'optimization=s',
- 'debug=false'],
+ 'debug=false',
+ ],
)
# libtool versioning
@@ -445,7 +446,7 @@
)
conf.set('VERSION', version)
-conf.set('MAN_DATE', run_command('util/getversion.sh', '--man-date').stdout().strip())
+conf.set('MAN_DATE', run_command('util/getversion.sh', '--man-date', check : true).stdout().strip())
configure_file(
input : 'flashrom.8.tmpl',
output : 'flashrom.8',