Files
MINGW-packages/mingw-w64-nodejs/0004-Define-localtime_s-for-MinGW.patch
2023-07-30 22:07:59 +08:00

33 lines
965 B
Diff

From fa7be56b0c792732aaa07b1f778987c51f38b810 Mon Sep 17 00:00:00 2001
From: Alethea Rose <alethea@alethearose.com>
Date: Tue, 14 Feb 2017 23:07:39 -0500
Subject: [PATCH 04/23] Define localtime_s for MinGW
---
deps/v8/src/base/platform/platform-win32.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/deps/v8/src/base/platform/platform-win32.cc b/deps/v8/src/base/platform/platform-win32.cc
index d495a302..c1a11524 100644
--- a/deps/v8/src/base/platform/platform-win32.cc
+++ b/deps/v8/src/base/platform/platform-win32.cc
@@ -75,7 +75,6 @@ inline void MemoryFence() {
__asm__ __volatile__("xchgl %%eax,%0 ":"=r" (barrier));
}
-#endif // __MINGW64_VERSION_MAJOR
int localtime_s(tm* out_tm, const time_t* time) {
@@ -128,6 +127,7 @@ int strncpy_s(char* dest, size_t dest_size, const char* source, size_t count) {
return 0;
}
+#endif // __MINGW64_VERSION_MAJOR
#endif // __MINGW32__
namespace v8 {
--
2.17.0.windows.1