summaryrefslogtreecommitdiffstats
path: root/win/configure.in
diff options
context:
space:
mode:
Diffstat (limited to 'win/configure.in')
-rw-r--r--win/configure.in22
1 files changed, 21 insertions, 1 deletions
diff --git a/win/configure.in b/win/configure.in
index 16591e6..b195e2b 100644
--- a/win/configure.in
+++ b/win/configure.in
@@ -3,7 +3,7 @@
# generate the file "configure", which is run during Tcl installation
# to configure the system for the local environment.
#
-# RCS: @(#) $Id: configure.in,v 1.64 2003/01/25 12:48:12 mdejong Exp $
+# RCS: @(#) $Id: configure.in,v 1.65 2003/01/27 02:19:57 mdejong Exp $
AC_INIT(../generic/tcl.h)
AC_PREREQ(2.13)
@@ -224,6 +224,26 @@ if test "$tcl_cv_malloc_decl_alloca" = "no" &&
[Defined when gcc should use inline ASM to call alloca.])
fi
+# See if the compiler supports casting to a union type.
+# This is used to stop gcc from printing a compiler
+# warning when initializing a union member.
+
+AC_CACHE_CHECK(for cast to union support,
+ tcl_cv_cast_to_union,
+AC_TRY_COMPILE([],
+[
+ 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)
+)
+if test "$tcl_cv_cast_to_union" = "yes"; then
+ AC_DEFINE(HAVE_CAST_TO_UNION, 1,
+ [Defined when compiler supports casting to union type.])
+fi
+
+
#--------------------------------------------------------------------
# Determines the correct binary file extension (.o, .obj, .exe etc.)
#--------------------------------------------------------------------