summaryrefslogtreecommitdiffstats
path: root/win
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2020-10-30 15:38:47 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2020-10-30 15:38:47 (GMT)
commit38ba30a89bc4868dd7ab031e4267b2adc76c40ce (patch)
tree8c6865989f9df04fcfb86da7aaf0d8be4c9b4e8d /win
parent22c4ca00cfe9df9d0567532367b491e83fb386a2 (diff)
parentf163c24b4c9dd8b0e7c72274f1c008384ea8f514 (diff)
downloadtcl-38ba30a89bc4868dd7ab031e4267b2adc76c40ce.zip
tcl-38ba30a89bc4868dd7ab031e4267b2adc76c40ce.tar.gz
tcl-38ba30a89bc4868dd7ab031e4267b2adc76c40ce.tar.bz2
Merge 8.6
Diffstat (limited to 'win')
-rw-r--r--win/Makefile.in8
-rwxr-xr-xwin/configure8
-rw-r--r--win/configure.in6
-rw-r--r--win/tcl.m42
-rw-r--r--win/tclWinChan.c2
-rw-r--r--win/tclWinConsole.c2
-rw-r--r--win/tclWinInt.h15
-rw-r--r--win/tclWinPipe.c2
-rw-r--r--win/tclWinSerial.c2
9 files changed, 31 insertions, 16 deletions
diff --git a/win/Makefile.in b/win/Makefile.in
index d839345..08b04bc 100644
--- a/win/Makefile.in
+++ b/win/Makefile.in
@@ -85,7 +85,7 @@ CFLAGS_OPTIMIZE = @CFLAGS_OPTIMIZE@
#CFLAGS = $(CFLAGS_DEBUG)
#CFLAGS = $(CFLAGS_OPTIMIZE)
#CFLAGS = $(CFLAGS_DEBUG) $(CFLAGS_OPTIMIZE)
-CFLAGS = @CFLAGS@ @CFLAGS_DEFAULT@ -D_ATL_XP_TARGETING -DMP_FIXED_CUTOFFS -DMP_NO_STDINT
+CFLAGS = @CFLAGS@ @CFLAGS_DEFAULT@ -D_ATL_XP_TARGETING=1 -D__USE_MINGW_ANSI_STDIO=0 -DMP_FIXED_CUTOFFS -DMP_NO_STDINT
# To compile without backward compatibility and deprecated code uncomment the
# following
@@ -149,12 +149,12 @@ TCL_STUB_LIB_FILE = @TCL_STUB_LIB_FILE@
TCL_DLL_FILE = @TCL_DLL_FILE@
TCL_LIB_FILE = @TCL_LIB_FILE@
DDE_DLL_FILE = tcldde$(DDEVER)${DLLSUFFIX}
-DDE_LIB_FILE = @LIBPREFIX@tcldde$(DDEVER)${LIBSUFFIX}
+DDE_LIB_FILE = @LIBPREFIX@tcldde$(DDEVER)${DLLSUFFIX}${LIBSUFFIX}
REG_DLL_FILE = tclreg$(REGVER)${DLLSUFFIX}
-REG_LIB_FILE = @LIBPREFIX@tclreg$(REGVER)${LIBSUFFIX}
+REG_LIB_FILE = @LIBPREFIX@tclreg$(REGVER)${DLLSUFFIX}${LIBSUFFIX}
TEST_DLL_FILE = tcltest$(VER)${DLLSUFFIX}
TEST_EXE_FILE = tcltest${EXESUFFIX}
-TEST_LIB_FILE = @LIBPREFIX@tcltest$(VER)${LIBSUFFIX}
+TEST_LIB_FILE = @LIBPREFIX@tcltest$(VER)${DLLSUFFIX}${LIBSUFFIX}
TEST_LOAD_PRMS = package ifneeded dde 1.4.3 [list load [file normalize ${DDE_DLL_FILE}] dde];\
package ifneeded registry 1.3.5 [list load [file normalize ${REG_DLL_FILE}] registry]
TEST_LOAD_FACILITIES = package ifneeded Tcltest ${VERSION}@TCL_PATCH_LEVEL@ [list load [file normalize ${TEST_DLL_FILE}] Tcltest];\
diff --git a/win/configure b/win/configure
index 2cfd3a9..dae49d6 100755
--- a/win/configure
+++ b/win/configure
@@ -3584,7 +3584,7 @@ echo "$as_me: error: ${CC} does not support the -shared option.
SHLIB_LD='${CC} -shared'
SHLIB_LD_LIBS='${LIBS}'
MAKE_DLL="\${SHLIB_LD} \$(LDFLAGS) -o \$@ ${extra_ldflags} \
- -Wl,--out-implib,\$(patsubst %.dll,lib%.a,\$@)"
+ -Wl,--out-implib,\$(patsubst %.dll,lib%.dll.a,\$@)"
# DLLSUFFIX is separate because it is the building block for
# users of tclConfig.sh that may build shared or static.
DLLSUFFIX="\${DBGX}.dll"
@@ -5075,7 +5075,11 @@ eval "TCL_STUB_LIB_SPEC=\"-L${libdir} ${TCL_STUB_LIB_FLAG}\""
eval "TCL_BUILD_STUB_LIB_PATH=\"`$CYGPATH $(pwd)`/${TCL_STUB_LIB_FILE}\""
eval "TCL_STUB_LIB_PATH=\"${libdir}/${TCL_STUB_LIB_FILE}\""
-eval "TCL_LIB_FILE=\"${LIBPREFIX}tcl${VER}${LIBSUFFIX}\""
+if test ${SHARED_BUILD} = 0 ; then
+ eval "TCL_LIB_FILE=\"${LIBPREFIX}tcl${VER}${LIBSUFFIX}\""
+else
+ eval "TCL_LIB_FILE=\"${LIBPREFIX}tcl${VER}${DLLSUFFIX}.a\""
+fi
eval "TCL_BUILD_LIB_SPEC=\"-L`$CYGPATH $(pwd)` -ltcl${VER}${FLAGSUFFIX}\""
eval "TCL_LIB_SPEC=\"-L${libdir} -ltcl${VER}${FLAGSUFFIX}\""
diff --git a/win/configure.in b/win/configure.in
index 70553b8..9e0dd19 100644
--- a/win/configure.in
+++ b/win/configure.in
@@ -311,7 +311,11 @@ eval "TCL_STUB_LIB_SPEC=\"-L${libdir} ${TCL_STUB_LIB_FLAG}\""
eval "TCL_BUILD_STUB_LIB_PATH=\"`$CYGPATH $(pwd)`/${TCL_STUB_LIB_FILE}\""
eval "TCL_STUB_LIB_PATH=\"${libdir}/${TCL_STUB_LIB_FILE}\""
-eval "TCL_LIB_FILE=\"${LIBPREFIX}tcl${VER}${LIBSUFFIX}\""
+if test ${SHARED_BUILD} = 0 ; then
+ eval "TCL_LIB_FILE=\"${LIBPREFIX}tcl${VER}${LIBSUFFIX}\""
+else
+ eval "TCL_LIB_FILE=\"${LIBPREFIX}tcl${VER}${DLLSUFFIX}.a\""
+fi
eval "TCL_BUILD_LIB_SPEC=\"-L`$CYGPATH $(pwd)` -ltcl${VER}${FLAGSUFFIX}\""
eval "TCL_LIB_SPEC=\"-L${libdir} -ltcl${VER}${FLAGSUFFIX}\""
diff --git a/win/tcl.m4 b/win/tcl.m4
index c62af68..44bb380 100644
--- a/win/tcl.m4
+++ b/win/tcl.m4
@@ -715,7 +715,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
SHLIB_LD='${CC} -shared'
SHLIB_LD_LIBS='${LIBS}'
MAKE_DLL="\${SHLIB_LD} \$(LDFLAGS) -o \[$]@ ${extra_ldflags} \
- -Wl,--out-implib,\$(patsubst %.dll,lib%.a,\[$]@)"
+ -Wl,--out-implib,\$(patsubst %.dll,lib%.dll.a,\[$]@)"
# DLLSUFFIX is separate because it is the building block for
# users of tclConfig.sh that may build shared or static.
DLLSUFFIX="\${DBGX}.dll"
diff --git a/win/tclWinChan.c b/win/tclWinChan.c
index 4f210cb..573ac7d 100644
--- a/win/tclWinChan.c
+++ b/win/tclWinChan.c
@@ -1377,7 +1377,7 @@ TclWinOpenFileChannel(
infoPtr->flags = appendMode;
infoPtr->handle = handle;
infoPtr->dirty = 0;
- sprintf(channelName, "file%" TCL_I_MODIFIER "x", (size_t) infoPtr);
+ sprintf(channelName, "file%" TCL_Z_MODIFIER "x", (size_t) infoPtr);
infoPtr->channel = Tcl_CreateChannel(&fileChannelType, channelName,
infoPtr, permissions);
diff --git a/win/tclWinConsole.c b/win/tclWinConsole.c
index a223a1f..bb5166b 100644
--- a/win/tclWinConsole.c
+++ b/win/tclWinConsole.c
@@ -1332,7 +1332,7 @@ TclWinOpenConsoleChannel(
* for instance).
*/
- sprintf(channelName, "file%" TCL_I_MODIFIER "x", (size_t) infoPtr);
+ sprintf(channelName, "file%" TCL_Z_MODIFIER "x", (size_t) infoPtr);
infoPtr->channel = Tcl_CreateChannel(&consoleChannelType, channelName,
infoPtr, permissions);
diff --git a/win/tclWinInt.h b/win/tclWinInt.h
index 5f532bc..ac95da5 100644
--- a/win/tclWinInt.h
+++ b/win/tclWinInt.h
@@ -53,11 +53,18 @@ MODULE_SCOPE TclWinProcs tclWinProcs;
#define VER_PLATFORM_WIN32_CE 3
#endif
-#ifdef _WIN64
-# define TCL_I_MODIFIER "I"
-#else
-# define TCL_I_MODIFIER ""
+#ifndef TCL_Z_MODIFIER
+# ifdef _WIN64
+# if defined(__USE_MINGW_ANSI_STDIO) && __USE_MINGW_ANSI_STDIO
+# define TCL_Z_MODIFIER "ll"
+# else
+# define TCL_Z_MODIFIER "I"
+# endif
+# else
+# define TCL_Z_MODIFIER ""
+# endif
#endif
+#define TCL_I_MODIFIER TCL_Z_MODIFIER
/*
* Declarations of functions that are not accessible by way of the
diff --git a/win/tclWinPipe.c b/win/tclWinPipe.c
index 14ca9e3..00bc9fe 100644
--- a/win/tclWinPipe.c
+++ b/win/tclWinPipe.c
@@ -1834,7 +1834,7 @@ TclpCreateCommandChannel(
* unique, in case channels share handles (stdin/stdout).
*/
- sprintf(channelName, "file%" TCL_I_MODIFIER "x", (size_t) infoPtr);
+ sprintf(channelName, "file%" TCL_Z_MODIFIER "x", (size_t) infoPtr);
infoPtr->channel = Tcl_CreateChannel(&pipeChannelType, channelName,
infoPtr, infoPtr->validMask);
diff --git a/win/tclWinSerial.c b/win/tclWinSerial.c
index 6946907..d7fa9f5 100644
--- a/win/tclWinSerial.c
+++ b/win/tclWinSerial.c
@@ -1456,7 +1456,7 @@ TclWinOpenSerialChannel(
* are shared between multiple channels (stdin/stdout).
*/
- sprintf(channelName, "file%" TCL_I_MODIFIER "x", (size_t) infoPtr);
+ sprintf(channelName, "file%" TCL_Z_MODIFIER "x", (size_t) infoPtr);
infoPtr->channel = Tcl_CreateChannel(&serialChannelType, channelName,
infoPtr, permissions);