diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-10-21 07:48:31 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-10-21 07:48:31 (GMT) |
commit | fd9662ee1c86d86ba0a92a616b5821fd389551e1 (patch) | |
tree | fb7fc2ea8e88ce24750500bb4710fd7998e0e12a | |
parent | 7f986a59bf53e05fac834aed3b3fb663669adadc (diff) | |
download | tcl-fd9662ee1c86d86ba0a92a616b5821fd389551e1.zip tcl-fd9662ee1c86d86ba0a92a616b5821fd389551e1.tar.gz tcl-fd9662ee1c86d86ba0a92a616b5821fd389551e1.tar.bz2 |
Fix [c975939973]: Usage of gnu_printf in latest mingw-w64
-rw-r--r-- | generic/tcl.h | 2 | ||||
-rw-r--r-- | win/tclWinInt.h | 4 | ||||
-rw-r--r-- | win/tclWinPort.h | 4 |
3 files changed, 9 insertions, 1 deletions
diff --git a/generic/tcl.h b/generic/tcl.h index 914f62b..a756a33 100644 --- a/generic/tcl.h +++ b/generic/tcl.h @@ -384,7 +384,7 @@ typedef long LONG; */ #if !defined(TCL_WIDE_INT_TYPE)&&!defined(TCL_WIDE_INT_IS_LONG) -# if defined(_WIN32) +# if defined(_WIN32) && (!defined(__USE_MINGW_ANSI_STDIO) || !__USE_MINGW_ANSI_STDIO) # define TCL_WIDE_INT_TYPE __int64 # ifdef __BORLANDC__ # define TCL_LL_MODIFIER "L" diff --git a/win/tclWinInt.h b/win/tclWinInt.h index 5f532bc..a44abd9 100644 --- a/win/tclWinInt.h +++ b/win/tclWinInt.h @@ -54,7 +54,11 @@ MODULE_SCOPE TclWinProcs tclWinProcs; #endif #ifdef _WIN64 +#if defined(__USE_MINGW_ANSI_STDIO) && __USE_MINGW_ANSI_STDIO +# define TCL_I_MODIFIER "ll" +#else # define TCL_I_MODIFIER "I" +#endif #else # define TCL_I_MODIFIER "" #endif diff --git a/win/tclWinPort.h b/win/tclWinPort.h index 8641e5e..6bfbf0c 100644 --- a/win/tclWinPort.h +++ b/win/tclWinPort.h @@ -18,6 +18,10 @@ /* See [Bug 3354324]: file mtime sets wrong time */ # define __MINGW_USE_VC2005_COMPAT #endif +#if !defined(__USE_MINGW_ANSI_STDIO) +/* See [Bug c975939973]: Usage of gnu_printf in latest mingw-w64 */ +# define __USE_MINGW_ANSI_STDIO 0 +#endif /* * We must specify the lower version we intend to support. |