OSDN Git Service

check that intel-gen4asm tool is actually present
authorDaniel Charles <daniel.charles@intel.com>
Thu, 3 Jul 2014 21:28:50 +0000 (14:28 -0700)
committerXiang, Haihao <haihao.xiang@intel.com>
Thu, 26 Mar 2015 00:38:59 +0000 (08:38 +0800)
intel-gen4asm tool has to be present on the host tools so that
it can actually be used. Cross compiling shows problems when the
gpu-tools version is met but the tool is not available on the PATH

So, first check that the tool is available and later check for version
before defining HAVE_GEN4ASM.

Signed-off-by: Daniel Charles <daniel.charles@intel.com>
(cherry picked from commit 038097c00ad7b4f2e0fd572ee20f255dd378b5cb)

Conflicts:

configure.ac

configure.ac

index bbff1f7..d71a3cc 100644 (file)
@@ -78,8 +78,9 @@ AC_SUBST(LIBDRM_VERSION)
 
 dnl Check for gen4asm
 PKG_CHECK_MODULES(GEN4ASM, [intel-gen4asm >= 1.9], [gen4asm=yes], [gen4asm=no])
-AM_CONDITIONAL(HAVE_GEN4ASM, test x$gen4asm = xyes)
 AC_PATH_PROG([GEN4ASM], [intel-gen4asm])
+AS_IF([test "x$GEN4ASM" = "x" ], [AM_CONDITIONAL(HAVE_GEN4ASM, false)],
+    [AM_CONDITIONAL(HAVE_GEN4ASM, [test x$gen4asm = xyes])])
 
 dnl Check for git
 AC_ARG_VAR([GIT], [Path to git program, if any])