diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2012-04-06 22:04:03 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2012-04-06 22:04:03 (GMT) |
commit | edf582e29363915f6b8ea7954176768d8545934f (patch) | |
tree | 845dc4e8e220a3589692bbc862c9d74649410158 /win/tcl.m4 | |
parent | ca830add40b2f1d21998d01aa0a67b9d0d4dd275 (diff) | |
download | tk-edf582e29363915f6b8ea7954176768d8545934f.zip tk-edf582e29363915f6b8ea7954176768d8545934f.tar.gz tk-edf582e29363915f6b8ea7954176768d8545934f.tar.bz2 |
some more cygwin compatibility improvements
Diffstat (limited to 'win/tcl.m4')
-rwxr-xr-x[-rw-r--r--] | win/tcl.m4 | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/win/tcl.m4 b/win/tcl.m4 index 752f022..ab47afc 100644..100755 --- 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) ]) @@ -413,12 +417,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 @@ -589,12 +593,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 |