cannot break compilation of gsocket.cpp.
Replaced AC_LANG_SAVE/RESTORE by AC_LANG_PUSH/POP for consistency.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37196
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
dnl adds -traditional for gcc if needed
AC_PROG_GCC_TRADITIONAL
dnl adds -traditional for gcc if needed
AC_PROG_GCC_TRADITIONAL
-AC_LANG_SAVE
-AC_LANG_CPLUSPLUS
dnl C++-compiler checks
dnl defines CXX with the compiler to use
dnl C++-compiler checks
dnl defines CXX with the compiler to use
CXXFLAGS=${CXXFLAGS:=}
AC_BAKEFILE_PROG_CXX
CXXFLAGS=${CXXFLAGS:=}
AC_BAKEFILE_PROG_CXX
dnl ranlib command
dnl defines RANLIB with the appropriate command
dnl ranlib command
dnl defines RANLIB with the appropriate command
dnl ---------------------------------------------------------------------
dnl (non-OS/2-only piece)
dnl ---------------------------------------------------------------------
dnl (non-OS/2-only piece)
- AC_LANG_SAVE
- AC_LANG_CPLUSPLUS
AC_CACHE_CHECK([for strcasecmp() in string.h], ac_cv_string_strcasecmp, [
AC_TRY_LINK([
AC_CACHE_CHECK([for strcasecmp() in string.h], ac_cv_string_strcasecmp, [
AC_TRY_LINK([
dnl (end of non-OS/2-only piece)
;;
esac
dnl (end of non-OS/2-only piece)
;;
esac
[if -D__STDC_EXT__ is required],
wx_cv_STDC_EXT_required,
[
[if -D__STDC_EXT__ is required],
wx_cv_STDC_EXT_required,
[
- AC_LANG_SAVE
- AC_LANG_CPLUSPLUS
wx_cv_STDC_EXT_required=no,
wx_cv_STDC_EXT_required=yes
)
wx_cv_STDC_EXT_required=no,
wx_cv_STDC_EXT_required=yes
)
]
)
if test "x$wx_cv_STDC_EXT_required" = "xyes"; then
]
)
if test "x$wx_cv_STDC_EXT_required" = "xyes"; then
AC_CACHE_CHECK([if expat.h is valid C++ header],
wx_cv_expat_is_not_broken,
[
AC_CACHE_CHECK([if expat.h is valid C++ header],
wx_cv_expat_is_not_broken,
[
- AC_LANG_SAVE
- AC_LANG_CPLUSPLUS
AC_TRY_COMPILE([#include <expat.h>],[],
wx_cv_expat_is_not_broken=yes,
wx_cv_expat_is_not_broken=no
)
AC_TRY_COMPILE([#include <expat.h>],[],
wx_cv_expat_is_not_broken=yes,
wx_cv_expat_is_not_broken=no
)
]
)
if test "$wx_cv_expat_is_not_broken" = "yes" ; then
]
)
if test "$wx_cv_expat_is_not_broken" = "yes" ; then
dnl check what exactly size_t is on this machine - this is necessary to avoid
dnl ambiguous overloads in several places, notably wx/string.h and wx/array.h
dnl check what exactly size_t is on this machine - this is necessary to avoid
dnl ambiguous overloads in several places, notably wx/string.h and wx/array.h
-AC_LANG_SAVE
-AC_LANG_CPLUSPLUS
AC_CACHE_CHECK([if size_t is unsigned int],
wx_cv_size_t_is_uint,
[
AC_CACHE_CHECK([if size_t is unsigned int],
wx_cv_size_t_is_uint,
[
dnl ---------------------------------------------------------------------------
dnl Checks for structures
dnl ---------------------------------------------------------------------------
dnl Checks for structures
dnl *printf() functions sometimes are available in the library but not
dnl prototyped -- if this is the case, we can't use them from C++ code, but to
dnl detect this we have to use C++ compiler for testing
dnl *printf() functions sometimes are available in the library but not
dnl prototyped -- if this is the case, we can't use them from C++ code, but to
dnl detect this we have to use C++ compiler for testing
-AC_LANG_SAVE
-AC_LANG_CPLUSPLUS
dnl check for vsnprintf() -- a safe version of vsprintf())
dnl
dnl check for vsnprintf() -- a safe version of vsprintf())
dnl
[AC_MSG_RESULT([no])]);
fi
[AC_MSG_RESULT([no])]);
fi
if test "x$ac_cv_header_fnmatch_h" = "xyes"; then
AC_CHECK_FUNCS(fnmatch)
if test "x$ac_cv_header_fnmatch_h" = "xyes"; then
AC_CHECK_FUNCS(fnmatch)
dnl check for available version of iconv()
dnl check for available version of iconv()
-AC_LANG_SAVE
-AC_LANG_CPLUSPLUS
AM_ICONV
LIBS="$LIBICONV $LIBS"
AM_ICONV
LIBS="$LIBICONV $LIBS"
dnl check for POSIX signals if we need them
if test "$wxUSE_ON_FATAL_EXCEPTION" = "yes" -a "$wxUSE_UNIX" = "yes"; then
dnl check for POSIX signals if we need them
if test "$wxUSE_ON_FATAL_EXCEPTION" = "yes" -a "$wxUSE_UNIX" = "yes"; then
fi
if test "$wxUSE_ON_FATAL_EXCEPTION" = "yes"; then
fi
if test "$wxUSE_ON_FATAL_EXCEPTION" = "yes"; then
- AC_LANG_SAVE
- AC_LANG_CPLUSPLUS
AC_CACHE_CHECK([for sa_handler type], wx_cv_type_sa_handler,
[
AC_CACHE_CHECK([for sa_handler type], wx_cv_type_sa_handler,
[
AC_DEFINE_UNQUOTED(wxTYPE_SA_HANDLER, $wx_cv_type_sa_handler)
fi
AC_DEFINE_UNQUOTED(wxTYPE_SA_HANDLER, $wx_cv_type_sa_handler)
fi
dnl backtrace() and backtrace_symbols() for wxStackWalker
if test "$wxUSE_STACKWALKER" = "yes" -a "$wxUSE_UNIX" = "yes"; then
dnl backtrace() and backtrace_symbols() for wxStackWalker
if test "$wxUSE_STACKWALKER" = "yes" -a "$wxUSE_UNIX" = "yes"; then
- AC_LANG_SAVE
- AC_LANG_CPLUSPLUS
AC_CACHE_CHECK([for backtrace() in <execinfo.h>], wx_cv_func_backtrace,
[
AC_CACHE_CHECK([for backtrace() in <execinfo.h>], wx_cv_func_backtrace,
[
fi
if test "$wxUSE_STACKWALKER" = "yes" -a "$USE_WIN32" != "1" -a "$USE_UNIX" != "1"; then
fi
if test "$wxUSE_STACKWALKER" = "yes" -a "$USE_WIN32" != "1" -a "$USE_UNIX" != "1"; then
if test "$wx_cv_func_statfs" = "yes"; then
dnl check whether we have its dcelaration too: some systems (AIX 4) lack it
if test "$wx_cv_func_statfs" = "yes"; then
dnl check whether we have its dcelaration too: some systems (AIX 4) lack it
- AC_LANG_SAVE
- AC_LANG_CPLUSPLUS
AC_CACHE_CHECK(for statfs declaration, wx_cv_func_statfs_decl,
AC_TRY_COMPILE(
[
AC_CACHE_CHECK(for statfs declaration, wx_cv_func_statfs_decl,
AC_TRY_COMPILE(
[
wx_cv_func_statfs_decl=no
)
)
wx_cv_func_statfs_decl=no
)
)
if test "$wx_cv_func_statfs_decl" = "yes"; then
AC_DEFINE(HAVE_STATFS_DECL)
if test "$wx_cv_func_statfs_decl" = "yes"; then
AC_DEFINE(HAVE_STATFS_DECL)
dnl
dnl for this check C++ compiler has to be used as passing incompatible
dnl pointers is just a warning and not an error in C
dnl
dnl for this check C++ compiler has to be used as passing incompatible
dnl pointers is just a warning and not an error in C
- AC_LANG_SAVE
- AC_LANG_CPLUSPLUS
AC_CACHE_CHECK(for statvfs argument type, wx_cv_type_statvfs_t,
AC_TRY_COMPILE(
AC_CACHE_CHECK(for statvfs argument type, wx_cv_type_statvfs_t,
AC_TRY_COMPILE(
if test "$wx_cv_type_statvfs_t" != "unknown"; then
AC_DEFINE(HAVE_STATVFS)
if test "$wx_cv_type_statvfs_t" != "unknown"; then
AC_DEFINE(HAVE_STATVFS)
dnl check for MT-safe version of strtok (on DEC Alpha, it's ok for C compiler
dnl but not for C++ one - hence change language)
dnl check for MT-safe version of strtok (on DEC Alpha, it's ok for C compiler
dnl but not for C++ one - hence change language)
-AC_LANG_SAVE
-AC_LANG_CPLUSPLUS
dnl check for inet_addr and inet_aton (these may live either in libc, or in
dnl libnsl or libresolv or libsocket)
dnl check for inet_addr and inet_aton (these may live either in libc, or in
dnl libnsl or libresolv or libsocket)
dnl for it, so testing for it is temporarily disabled and we are restricted
dnl to gethostbyname_r/gethostbyaddr_r and getservbyname_r
dnl for it, so testing for it is temporarily disabled and we are restricted
dnl to gethostbyname_r/gethostbyaddr_r and getservbyname_r
dnl AC_CHECK_FUNC(getaddrinfo, AC_DEFINE(HAVE_GETADDRINFO), [
dnl no getaddrinfo, so check for gethostbyname_r and
dnl related functions (taken from python's configure.in)
dnl AC_CHECK_FUNC(getaddrinfo, AC_DEFINE(HAVE_GETADDRINFO), [
dnl no getaddrinfo, so check for gethostbyname_r and
dnl related functions (taken from python's configure.in)
dnl check to fit this case, if it's really needed. - SN )
dnl ]
dnl )
dnl check to fit this case, if it's really needed. - SN )
dnl ]
dnl )
if test "$wxUSE_THREADS" = "yes"; then
AC_DEFINE(wxUSE_THREADS)
if test "$wxUSE_THREADS" = "yes"; then
AC_DEFINE(wxUSE_THREADS)
if test "$ac_cv_func_strptime" = "yes"; then
AC_CACHE_CHECK([for strptime declaration], wx_cv_func_strptime_decl,
[
if test "$ac_cv_func_strptime" = "yes"; then
AC_CACHE_CHECK([for strptime declaration], wx_cv_func_strptime_decl,
[
- AC_LANG_SAVE
- AC_LANG_CPLUSPLUS
AC_TRY_COMPILE(
[
#include <time.h>
AC_TRY_COMPILE(
[
#include <time.h>
wx_cv_func_strptime_decl=yes,
wx_cv_func_strptime_decl=no
)
wx_cv_func_strptime_decl=yes,
wx_cv_func_strptime_decl=no
)
wx_cv_func_gettimeofday_has_2_args,
[
dnl on some _really_ old systems it takes only 1 argument
wx_cv_func_gettimeofday_has_2_args,
[
dnl on some _really_ old systems it takes only 1 argument
- AC_LANG_SAVE
- AC_LANG_CPLUSPLUS
])
if test "$wx_cv_func_gettimeofday_has_2_args" != "yes"; then
])
if test "$wx_cv_func_gettimeofday_has_2_args" != "yes"; then
if test "$ac_cv_header_ole2_h" = "yes" ; then
if test "$GCC" = yes ; then
if test "$ac_cv_header_ole2_h" = "yes" ; then
if test "$GCC" = yes ; then
- AC_LANG_SAVE
- AC_LANG_CPLUSPLUS
AC_MSG_CHECKING([if g++ requires -fvtable-thunks])
AC_TRY_COMPILE([#include <windows.h>
AC_MSG_CHECKING([if g++ requires -fvtable-thunks])
AC_TRY_COMPILE([#include <windows.h>
[AC_MSG_RESULT(no)],
[AC_MSG_RESULT(yes)
WXCONFIG_CXXFLAGS="$WXCONFIG_CXXFLAGS -fvtable-thunks"])
[AC_MSG_RESULT(no)],
[AC_MSG_RESULT(yes)
WXCONFIG_CXXFLAGS="$WXCONFIG_CXXFLAGS -fvtable-thunks"])
LIBS=" -lrpcrt4 -loleaut32 -lole32 -luuid$LIBS"
if test "$wxUSE_OLE" = "yes" ; then
AC_DEFINE(wxUSE_OLE)
LIBS=" -lrpcrt4 -loleaut32 -lole32 -luuid$LIBS"
if test "$wxUSE_OLE" = "yes" ; then
AC_DEFINE(wxUSE_OLE)