From e0aca18f687e9f49223ffb24b9be354bed4b150a Mon Sep 17 00:00:00 2001 From: Willem Jan Palenstijn Date: Wed, 25 Feb 2015 10:49:08 +0100 Subject: Add logging for python module checks --- build/linux/acinclude.m4 | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'build/linux/acinclude.m4') diff --git a/build/linux/acinclude.m4 b/build/linux/acinclude.m4 index 713b5d3..e4b6de7 100644 --- a/build/linux/acinclude.m4 +++ b/build/linux/acinclude.m4 @@ -70,6 +70,18 @@ AC_DEFUN([ASTRA_RUN_LOGOUTPUT],[{ }]) +dnl ASTRA_TRY_PYTHON(code, action-if-ok, action-if-not-ok) +AC_DEFUN([ASTRA_TRY_PYTHON],[ +cat >conftest.py <<_ACEOF +$1 +_ACEOF +ASTRA_RUN_LOGOUTPUT($PYTHON conftest.py) +AS_IF([test $? = 0],[$2],[ + AS_ECHO(["$as_me: failed program was:"]) >&AS_MESSAGE_LOG_FD + sed 's/^/| /' conftest.py >&AS_MESSAGE_LOG_FD + $3]) +]) + dnl ASTRA_CHECK_NVCC(variable-to-set,cppflags-to-set) AC_DEFUN([ASTRA_CHECK_NVCC],[ -- cgit v1.2.3