summaryrefslogtreecommitdiffstats
path: root/win/tcl.m4
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2012-04-06 22:59:06 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2012-04-06 22:59:06 (GMT)
commite3509ec1d375b75b6bb1243beffffd788cf432e0 (patch)
tree8730df670d63d4b7741fa084f66c521c8fe59ada /win/tcl.m4
parent54cdd49ec52c0add51c03a85bdab6bdcef7f6b9f (diff)
parent1efb8907c729e92807cbcad5989bb74d3022d4ec (diff)
downloadtk-e3509ec1d375b75b6bb1243beffffd788cf432e0.zip
tk-e3509ec1d375b75b6bb1243beffffd788cf432e0.tar.gz
tk-e3509ec1d375b75b6bb1243beffffd788cf432e0.tar.bz2
some more cygwin compatibility improvements
format tk.decls
Diffstat (limited to 'win/tcl.m4')
-rw-r--r--win/tcl.m420
1 files changed, 12 insertions, 8 deletions
diff --git a/win/tcl.m4 b/win/tcl.m4
index 9036dc6..13e162d 100644
--- a/win/tcl.m4
+++ b/win/tcl.m4
@@ -34,7 +34,11 @@ AC_DEFUN([SC_PATH_TCLCONFIG], [
AC_MSG_ERROR(Tcl directory $TCL_BIN_DIR does not exist)
fi
if test ! -f $TCL_BIN_DIR/tclConfig.sh; then
- AC_MSG_ERROR(There is no tclConfig.sh in $TCL_BIN_DIR: perhaps you did not specify the Tcl *build* directory (not the toplevel Tcl directory) or you forgot to configure Tcl?)
+ if test ! -f $TCL_BIN_DIR/../unix/tclConfig.sh; then
+ AC_MSG_ERROR(There is no tclConfig.sh in $TCL_BIN_DIR: perhaps you did not specify the Tcl *build* directory (not the toplevel Tcl directory) or you forgot to configure Tcl?)
+ fi
+ TCL_BIN_DIR=`cd ${TCL_BIN_DIR}/../unix; pwd`
+ CFLAGS="$CFLAGS -mwin32"
fi
AC_MSG_RESULT($TCL_BIN_DIR/tclConfig.sh)
])
@@ -417,12 +421,12 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
AC_CACHE_CHECK(for cross-compile version of gcc,
ac_cv_cross,
AC_TRY_COMPILE([
- #ifdef __WIN32__
+ #ifndef __WIN32__
#error cross-compiler
#endif
], [],
- ac_cv_cross=yes,
- ac_cv_cross=no)
+ ac_cv_cross=no,
+ ac_cv_cross=yes)
)
if test "$ac_cv_cross" = "yes"; then
@@ -609,12 +613,12 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
;;
*)
AC_TRY_COMPILE([
- #ifdef _WIN64
- #error 64-bit
+ #ifndef _WIN64
+ #error 32-bit
#endif
], [],
- tcl_win_64bit=no,
- tcl_win_64bit=yes
+ tcl_win_64bit=yes,
+ tcl_win_64bit=no
)
if test "$tcl_win_64bit" = "yes" ; then
do64bit=amd64