From a5441f137f96bf584f1ea7bcbe21209033024b8e Mon Sep 17 00:00:00 2001 From: Jarkko Sakkinen Date: Thu, 25 Nov 2010 08:45:48 -0800 Subject: [PATCH] Fixed configure.ac so that configure script fails if uthash and/or libattr and their corresponding headers are not detected. Thanks to Ahmed S. Darwish for reporting this issue. --- configure.ac | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 0c143b4..b2fa5ae 100644 --- a/configure.ac +++ b/configure.ac @@ -22,8 +22,17 @@ fi AM_CONDITIONAL([HAVE_DOXYGEN],[test ! -z "$DOXYGEN"]) AC_SUBST([DOXYGEN], [$DOXYGEN]) -AC_CHECK_HEADERS([utarray.h uthash.h utlist.h utstring.h]) +AC_CHECK_HEADER([attr/xattr.h],[ + AC_CHECK_LIB([attr],[setxattr],[],[ + AC_MSG_ERROR([Cannot find setxattr in libattr])]) + AC_CHECK_LIB([attr],[getxattr],[],[ + AC_MSG_ERROR([Cannot find getxattr in libattr])]) +],[ + AC_MSG_ERROR([Cannot find attr/xattr.h]) +]) +AC_CHECK_HEADERS([utarray.h uthash.h utlist.h utstring.h],, + [AC_MSG_ERROR(Cannot find uthash headers)]) PKG_CHECK_MODULES([CHECK], [check >= 0.9.4]) AC_CONFIG_FILES([Makefile src/Makefile tests/Makefile doc/Makefile libsmack.spec]) -- 2.7.4