Files
MINGW-packages/mingw-w64-nodejs/0004-Define-localtime_s-for-MinGW.patch
2024-01-13 14:51:57 +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 152fbbf3..2b7dea59 100644
--- a/deps/v8/src/base/platform/platform-win32.cc
+++ b/deps/v8/src/base/platform/platform-win32.cc
@@ -77,7 +77,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) {
@@ -130,6 +129,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