summaryrefslogtreecommitdiffstats
path: root/win/tcl.m4
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2021-01-05 15:26:16 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2021-01-05 15:26:16 (GMT)
commitda4ed550358ff33023ebe52eb325ba906ffebed6 (patch)
treee2ba3e433a9b0b4129e61fb0c08ceb0d70bc319a /win/tcl.m4
parentd4d7af1554e5b2c8fddd2de7077202ffd5e83f03 (diff)
downloadtk-da4ed550358ff33023ebe52eb325ba906ffebed6.zip
tk-da4ed550358ff33023ebe52eb325ba906ffebed6.tar.gz
tk-da4ed550358ff33023ebe52eb325ba906ffebed6.tar.bz2
Sync */tcl.m4 with Tcl
Diffstat (limited to 'win/tcl.m4')
-rw-r--r--win/tcl.m469
1 files changed, 34 insertions, 35 deletions
diff --git a/win/tcl.m4 b/win/tcl.m4
index 4ef907e..6a974c0 100644
--- a/win/tcl.m4
+++ b/win/tcl.m4
@@ -563,13 +563,13 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
AC_CACHE_CHECK(for cross-compile version of gcc,
ac_cv_cross,
- AC_TRY_COMPILE([
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
#ifndef _WIN32
#error cross-compiler
#endif
- ], [],
- ac_cv_cross=no,
- ac_cv_cross=yes)
+ ]], [[]])],
+ [ac_cv_cross=no],
+ [ac_cv_cross=yes])
)
if test "$ac_cv_cross" = "yes"; then
@@ -630,13 +630,13 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
extra_ldflags="-pipe -static-libgcc"
AC_CACHE_CHECK(for mingw32 version of gcc,
ac_cv_win32,
- AC_TRY_COMPILE([
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
#ifdef _WIN32
#error win32
#endif
- ], [],
- ac_cv_win32=no,
- ac_cv_win32=yes)
+ ]], [[]])],
+ [ac_cv_win32=no],
+ [ac_cv_win32=yes])
)
if test "$ac_cv_win32" != "yes"; then
AC_MSG_ERROR([${CC} cannot produce win32 executables.])
@@ -736,18 +736,18 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
AC_MSG_RESULT([ Using 64-bit $MACHINE mode])
;;
*)
- AC_TRY_COMPILE([
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
#ifndef _WIN64
#error 32-bit
#endif
- ], [],
- tcl_win_64bit=yes,
- tcl_win_64bit=no
+ ]], [[]])],
+ [tcl_win_64bit=yes],
+ [tcl_win_64bit=no]
)
if test "$tcl_win_64bit" = "yes" ; then
- do64bit=amd64
- MACHINE="AMD64"
- AC_MSG_RESULT([ Using 64-bit $MACHINE mode])
+ do64bit=amd64
+ MACHINE="AMD64"
+ AC_MSG_RESULT([ Using 64-bit $MACHINE mode])
fi
;;
esac
@@ -961,7 +961,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
if test "${GCC}" = "yes" ; then
AC_CACHE_CHECK(for SEH support in compiler,
tcl_cv_seh,
- AC_TRY_RUN([
+ AC_RUN_IFELSE([AC_LANG_SOURCE([[
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#undef WIN32_LEAN_AND_MEAN
@@ -976,10 +976,10 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
}
return 1;
}
- ],
- tcl_cv_seh=yes,
- tcl_cv_seh=no,
- tcl_cv_seh=no)
+ ]])],
+ [tcl_cv_seh=yes],
+ [tcl_cv_seh=no],
+ [tcl_cv_seh=no])
)
if test "$tcl_cv_seh" = "no" ; then
AC_DEFINE(HAVE_NO_SEH, 1,
@@ -994,15 +994,15 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
#
AC_CACHE_CHECK(for EXCEPTION_DISPOSITION support in include files,
tcl_cv_eh_disposition,
- AC_TRY_COMPILE([
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
# define WIN32_LEAN_AND_MEAN
# include <windows.h>
# undef WIN32_LEAN_AND_MEAN
- ],[
+ ]], [[
EXCEPTION_DISPOSITION x;
- ],
- tcl_cv_eh_disposition=yes,
- tcl_cv_eh_disposition=no)
+ ]])],
+ [tcl_cv_eh_disposition=yes],
+ [tcl_cv_eh_disposition=no])
)
if test "$tcl_cv_eh_disposition" = "no" ; then
AC_DEFINE(EXCEPTION_DISPOSITION, int,
@@ -1015,18 +1015,18 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
AC_CACHE_CHECK(for winnt.h that ignores VOID define,
tcl_cv_winnt_ignore_void,
- AC_TRY_COMPILE([
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
#define VOID void
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#undef WIN32_LEAN_AND_MEAN
- ], [
+ ]], [[
CHAR c;
SHORT s;
LONG l;
- ],
- tcl_cv_winnt_ignore_void=yes,
- tcl_cv_winnt_ignore_void=no)
+ ]])],
+ [tcl_cv_winnt_ignore_void=yes],
+ [tcl_cv_winnt_ignore_void=no])
)
if test "$tcl_cv_winnt_ignore_void" = "yes" ; then
AC_DEFINE(HAVE_WINNT_IGNORE_VOID, 1,
@@ -1039,13 +1039,12 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
AC_CACHE_CHECK(for cast to union support,
tcl_cv_cast_to_union,
- AC_TRY_COMPILE([],
- [
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[
union foo { int i; double d; };
union foo f = (union foo) (int) 0;
- ],
- tcl_cv_cast_to_union=yes,
- tcl_cv_cast_to_union=no)
+ ]])],
+ [tcl_cv_cast_to_union=yes],
+ [tcl_cv_cast_to_union=no])
)
if test "$tcl_cv_cast_to_union" = "yes"; then
AC_DEFINE(HAVE_CAST_TO_UNION, 1,