From e203535ff0895c8a2486a1372d0c913d04f5613b Mon Sep 17 00:00:00 2001 From: Stefan Neis Date: Sat, 5 Apr 2008 21:00:46 +0000 Subject: [PATCH] Tests for declarations of snprintf/vsnprintf/vsscanf should be done in C++. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@53035 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- configure | 12 ++++++++++++ configure.in | 2 ++ 2 files changed, 14 insertions(+) diff --git a/configure b/configure index 1a93290..13a27f2 100755 --- a/configure +++ b/configure @@ -35017,6 +35017,12 @@ fi done + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + if test "$ac_cv_func_vsnprintf" = "yes"; then { echo "$as_me:$LINENO: checking for vsnprintf declaration" >&5 echo $ECHO_N "checking for vsnprintf declaration... $ECHO_C" >&6; } @@ -35401,6 +35407,12 @@ _ACEOF fi fi + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + if test "$wxUSE_UNICODE" = yes; then diff --git a/configure.in b/configure.in index de07fb3..887522e 100644 --- a/configure.in +++ b/configure.in @@ -4029,6 +4029,7 @@ dnl dnl FIXME: replace this mess with WX_CHECK_FUNCS() AC_CHECK_FUNCS(snprintf vsnprintf vsscanf) +AC_LANG_PUSH(C++) if test "$ac_cv_func_vsnprintf" = "yes"; then dnl yes it is -- now check if it is in the headers AC_CACHE_CHECK([for vsnprintf declaration], wx_cv_func_vsnprintf_decl, @@ -4194,6 +4195,7 @@ if test "$ac_cv_func_vsscanf" = "yes"; then AC_DEFINE(HAVE_VSSCANF_DECL) fi fi +AC_LANG_POP() if test "$wxUSE_UNICODE" = yes; then -- 2.7.4