[rhythmbox] build: check realpath worked before using the output



commit 44b76e3163c6c527d26b7f597698772955c6e772
Author: Jonathan Matthew <jonathan d14n org>
Date:   Thu Jun 16 22:16:44 2022 +1000

    build: check realpath worked before using the output

 shell/meson.build | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/shell/meson.build b/shell/meson.build
index 5b57d93ba..1393c51a7 100644
--- a/shell/meson.build
+++ b/shell/meson.build
@@ -142,7 +142,9 @@ real_prefix = get_option('prefix')
 realpath = find_program('realpath', required: false)
 if realpath.found()
   realpath_result = run_command([realpath, real_prefix], check: false)
-  real_prefix = realpath_result.stdout().strip()
+  if realpath_result.returncode() == 0
+    real_prefix = realpath_result.stdout().strip()
+  endif
 endif
 
 if real_prefix.startswith(meson.project_source_root())


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]