Windows XP x64 does not provide 32-bit time functions. Those are provided
on X64 systems since Windows Vista x64.

Main function symbols (those without suffixes) are 64-bit on all Windows
x64 systems.

So remove aliasing of X64 "time" symbol to "_time64" symbol as it is not
needed.

Symbol "_difftime64" was added in Windows Vista. So for compatibility with
Windows XP x64, define "_difftime64" symbol as alias to "difftime". Both
symbols have same functionality.

And export _ctime32, _mktime32, _time32 and _wctime32 symbols also on X64
version of msvcrt.dll as they are available since Windows Vista for both
I386 and X64. Note that they are not available on Windows XP x64, but there
is no reason to not export them (because mingw-w64 crt does not provide any
fallback replacement implementation).
---
 mingw-w64-crt/lib-common/msvcrt.def.in | 22 +++++++---------------
 1 file changed, 7 insertions(+), 15 deletions(-)

diff --git a/mingw-w64-crt/lib-common/msvcrt.def.in 
b/mingw-w64-crt/lib-common/msvcrt.def.in
index ffc2812b92ac..c3dc34745aef 100644
--- a/mingw-w64-crt/lib-common/msvcrt.def.in
+++ b/mingw-w64-crt/lib-common/msvcrt.def.in
@@ -952,7 +952,7 @@ swscanf
 system
 tan
 tanh ; if we implement tanh, we can set it to DATA only.
-time F_NON_I386(== _time64)
+time
 tmpfile
 tmpnam
 tolower
@@ -1250,9 +1250,7 @@ _crtDbgFlag
 _cscanf_l
 _cscanf_s
 _cscanf_s_l
-; _ctime32 replaced by below aliases
-F_ARM_ANY(_ctime32)
-F_I386(_ctime32 == ctime)
+_ctime32 F_I386(== ctime) ; i386 _ctime32 replaced by alias
 ; _ctime32_s replaced by emu
 ; _ctime64_s replaced by emu
 _cwprintf_l
@@ -1264,7 +1262,7 @@ _cwscanf_l
 _cwscanf_s
 _cwscanf_s_l
 _difftime32 F_I386(== difftime) ; i386 _difftime32 replaced by alias
-_difftime64
+_difftime64 F_X64(== difftime) ; x64 _difftime64 replaced by alias
 _ecvt_s
 F_I386(_except_handler4_common)
 _expand_dbg
@@ -1464,11 +1462,9 @@ _mbtowc_l
 _mbsnlen
 _mbstrnlen
 _memicmp_l
-_mkgmtime32
+_mkgmtime32 F_I386(== _mkgmtime) ; i386 _mkgmtime32 replaced by alias
 ; _mktemp_s replaced by emu
-; _mktime32 replaced by below aliases
-F_I386(_mktime32 == mktime)
-F_ARM_ANY(_mktime32)
+_mktime32 F_I386(== mktime) ; i386 _mktime32 replaced by alias
 F_NON_I386(_msize_dbg)
 F_I386(_msize_debug)
 _printf_l
@@ -1544,9 +1540,7 @@ _swprintf_s_l
 _swscanf_l
 _swscanf_s_l
 _tempnam_dbg
-; _time32 replaced by below aliases
-F_I386(_time32 == time)
-F_ARM_ANY(_time32)
+_time32 F_I386(== time) ; i386 _time32 replaced by alias
 _tolower_l
 _toupper_l
 _towlower_l
@@ -1634,9 +1628,7 @@ _wcsupr_l
 _wcsupr_s
 _wcsupr_s_l
 _wcsxfrm_l
-; _wctime32 replaced by below aliases
-F_I386(_wctime32 == _wctime)
-F_ARM_ANY(_wctime32)
+_wctime32 F_I386(== _wctime) ; i386 _wctime32 replaced by alias
 ; _wctime32_s replaced by emu
 ; _wctime64_s replaced by emu
 _wctomb_l
-- 
2.20.1



_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to