[epiphany/mcatanzaro/meson-warnings: 1/4] build: check result of run_command()
- From: Michael Catanzaro <mcatanzaro src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany/mcatanzaro/meson-warnings: 1/4] build: check result of run_command()
- Date: Fri, 5 Aug 2022 20:41:05 +0000 (UTC)
commit 73c4fb039ec59ea8a8a14790c23e3dfc326756a1
Author: Michael Catanzaro <mcatanzaro redhat com>
Date: Fri Aug 5 15:33:49 2022 -0500
build: check result of run_command()
This avoids whining from Meson, see:
https://github.com/mesonbuild/meson/issues/9300
and is surely a good idea in general.
meson.build | 2 +-
tests/meson.build | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/meson.build b/meson.build
index 931ab3125..02a515945 100644
--- a/meson.build
+++ b/meson.build
@@ -9,7 +9,7 @@ project('epiphany', 'c',
gnome = import('gnome')
i18n = import('i18n')
-r = run_command('grep', '-Po', '^NAME=\K.*', '/etc/os-release')
+r = run_command('grep', '-Po', '^NAME=\K.*', '/etc/os-release', check: true)
if r.returncode() == 0
distributor_name = r.stdout().strip()
else
diff --git a/tests/meson.build b/tests/meson.build
index d120d1391..7d474497a 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -3,7 +3,7 @@ envs = [
'G_TEST_BUILDDIR=' + meson.current_build_dir(),
'GSETTINGS_SCHEMA_DIR=' + join_paths(meson.build_root(), 'data'),
'GSETTINGS_BACKEND=memory',
- 'PATH=' + join_paths(meson.build_root(), 'src') + ':' + run_command('printenv', 'PATH').stdout(),
+ 'PATH=' + join_paths(meson.build_root(), 'src') + ':' + run_command('printenv', 'PATH', check:
true).stdout(),
]
test_cargs = ['-UG_DISABLE_ASSERT']
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]