public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH i-g-t 1/2] meson: don't assume xmlrpc-c-config is there
@ 2017-10-24  8:14 Jani Nikula
  2017-10-24  8:14 ` [PATCH i-g-t 2/2] meson: intel_dp_compliance depends on libudev Jani Nikula
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: Jani Nikula @ 2017-10-24  8:14 UTC (permalink / raw)
  To: intel-gfx; +Cc: jani.nikula

xmlrpc is an optional dependency. If pkg-config can't find it, don't
assume xmlrpc-c-config will be there either. Make xmlrpc-c-config
optional too.

Fixes error:

Meson encountered an error in file meson.build, line 73, column 1:
Program or command 'xmlrpc-c-config' not foundor not executable

Fixes: 892abc602a8a ("meson: Add fallback for xmlrpc discovery")
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>

---

Note: Untested in the scenario described in 892abc602a8a ("meson: Add
fallback for xmlrpc discovery")
---
 meson.build | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/meson.build b/meson.build
index ac991c2f9bf2..fb81c4dbbd55 100644
--- a/meson.build
+++ b/meson.build
@@ -69,9 +69,10 @@ xmlrpc = dependency('xmlrpc', required : false)
 xmlrpc_util = dependency('xmlrpc_util', required : false)
 xmlrpc_client = dependency('xmlrpc_client', required : false)
 
-if not xmlrpc.found()
-	libs_cmd = run_command('xmlrpc-c-config', 'client', '--libs')
-	cflags_cmd = run_command('xmlrpc-c-config', 'client', '--cflags')
+xmlrpc_cmd = find_program('xmlrpc-c-config', required : false)
+if not xmlrpc.found() and xmlrpc_cmd.found()
+	libs_cmd = run_command(xmlrpc_cmd, 'client', '--libs')
+	cflags_cmd = run_command(xmlrpc_cmd, 'client', '--cflags')
 
 	if libs_cmd.returncode() == 0 and cflags_cmd.returncode() == 0
 		xmlrpc = declare_dependency(compile_args: cflags_cmd.stdout().strip().split(),
-- 
2.11.0

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2017-10-24 15:00 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-24  8:14 [PATCH i-g-t 1/2] meson: don't assume xmlrpc-c-config is there Jani Nikula
2017-10-24  8:14 ` [PATCH i-g-t 2/2] meson: intel_dp_compliance depends on libudev Jani Nikula
2017-10-24  8:32 ` ✓ Fi.CI.BAT: success for series starting with [1/2] meson: don't assume xmlrpc-c-config is there Patchwork
2017-10-24  9:13 ` ✓ Fi.CI.IGT: " Patchwork
2017-10-24 12:29 ` [PATCH i-g-t 1/2] " Arkadiusz Hiler
2017-10-24 14:54 ` ✗ Fi.CI.BAT: failure for series starting with [1/2] " Patchwork
2017-10-24 15:00 ` Patchwork

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox