diff options
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index cce0ad0..f61a73a 100644 --- a/configure.ac +++ b/configure.ac @@ -63,6 +63,7 @@ AC_SUBST(LT_AGE) AC_PROG_CC AM_PROG_CC_C_O +AC_PROG_CXX AC_PROG_INSTALL LT_INIT AC_PROG_MKDIR_P @@ -72,6 +73,15 @@ AC_CHECK_PROGS(YACC, 'bison -y') AC_C_CONST AC_C_INLINE +AC_LANG_PUSH([C++]) +AC_COMPILE_IFELSE([AC_LANG_PROGRAM( + [[#ifndef __cplusplus + #error "broken C++" + #endif]])],, + [CXX=;]) +AC_LANG_POP([C++]) +AM_CONDITIONAL([HAS_CXX], [test "x$CXX" != x]) + PKG_CHECK_MODULES([CHECK], [check >= 0.9.0], [has_check="yes"], [AC_MSG_WARN([*** Disabling building of unit tests]) @@ -155,6 +165,11 @@ fi AC_OUTPUT +CXX_MSG="none" +if test "x$CXX" != x ; then + CXX_MSG="[$CXX]" +fi + echo echo "libnl $LIBNL_VERSION configuration${LIBNL_GIT_SHA:+ (git:$LIBNL_GIT_SHA)}:" echo " --enable-pthreads=$enable_pthreads" @@ -164,4 +179,5 @@ echo " --enable-debug=$enable_debug" echo " --enable-cli=$enable_cli" echo echo " check: $has_check" +echo " CXX: $CXX_MSG (only used for tests)" echo |