Mesa (main): meson: Check that bin/meson_get_version.py ran without an error

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue Aug 17 22:47:33 UTC 2021


Module: Mesa
Branch: main
Commit: cf23fbb040f15e0b035e8d5ba90761a7d5418e68
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=cf23fbb040f15e0b035e8d5ba90761a7d5418e68

Author: Jordan Justen <jordan.l.justen at intel.com>
Date:   Tue Aug 17 02:11:10 2021 -0700

meson: Check that bin/meson_get_version.py ran without an error

According to https://mesonbuild.com/Reference-manual.html, the check
parameter is supported since meson 0.47.0.

This could have helped to catch the issue fixed by:

221871fb6da ("meson: Search for python3 before python for bin/meson_get_version.py")

as it would have caused the build to fail immediately.

It's still a good idea to check the result even though that issue is
now fixed.

Signed-off-by: Jordan Justen <jordan.l.justen at intel.com>
Reviewed-by: Eric Engestrom <eric at engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12404>

---

 meson.build | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/meson.build b/meson.build
index 08667a82acf..2106094cb4b 100644
--- a/meson.build
+++ b/meson.build
@@ -22,7 +22,8 @@ project(
   'mesa',
   ['c', 'cpp'],
   version : run_command(
-    [find_program('python3', 'python'), 'bin/meson_get_version.py']
+    [find_program('python3', 'python'), 'bin/meson_get_version.py'],
+    check : true
   ).stdout(),
   license : 'MIT',
   meson_version : '>= 0.52',



More information about the mesa-commit mailing list