-rw-r--r-- | acinclude.m4 | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/acinclude.m4 b/acinclude.m4 index 80defc7..fbb4cdc 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -142,25 +142,42 @@ AC_DEFUN([AC_WITH_PCREPP],[ if test "${PCREPP_CONFIG}" = "false" ; then ifelse([$2], , :, [$2]) else HAVE_PCREPP="yes" PCREPP_PREFIX="`${PCREPP_CONFIG} --prefix`" PCREPP_EXEC_PREFIX="`${PCREPP_CONFIG} --exec-prefix`" PCREPP_VERSION="`${PCREPP_CONFIG} --version`" PCREPP_CFLAGS="`${PCREPP_CONFIG} --cflags` ${PCRE_CFLAGS}" PCREPP_LIBS="`${PCREPP_CONFIG} --libs` ${PCRE_LIBS}" AC_SUBST([PCREPP_CONFIG]) AC_SUBST([PCREPP_PREFIX]) AC_SUBST([PCREPP_EXEC_PREFIX]) AC_SUBST([PCREPP_VERSION]) AC_SUBST([PCREPP_CFLAGS]) AC_SUBST([PCREPP_LIBS]) AC_DEFINE([HAVE_PCREPP],,[pcre++ support]) AC_DEFINE_UNQUOTED([PCREPP_VERSION],["${PCREPP_VERSION}"],[pcre++ version]) $1 fi fi fi fi ]) +dnl AC_CHECK_SHAREDPTR(NS,HEADER[,ACTION-IF-FOUND[,ACTION-IF-NOT-FOUND]]) +AC_DEFUN([AC_CHECK_SHAREDPTR],[ + AC_LANG_PUSH([C++]) + AC_MSG_CHECKING([for $1::shared_ptr<> in $2]) + AC_COMPILE_IFELSE([ + #include <$2> + int main(int c,char**v) { $1::shared_ptr<int> spi(new int(0)); return *spi; } + ],[ + AC_MSG_RESULT([found]) + $3 + ],[ + AC_MSG_RESULT([not found]) + $4 + ]) + AC_LANG_POP([C++]) +]) + m4_include([acinclude.d/libcurl.m4]) |