mirror of https://github.com/microsoft/vcpkg.git
24 lines
466 B
Diff
24 lines
466 B
Diff
diff --git a/src/Assert.cpp b/src/Assert.cpp
|
|
index b0ac35c53c..d212320065 100644
|
|
--- a/src/Assert.cpp
|
|
+++ b/src/Assert.cpp
|
|
@@ -6,7 +6,17 @@
|
|
#include <csignal>
|
|
#include <cstdio>
|
|
#include <cstdlib>
|
|
-#include <unistd.h>
|
|
+#if defined(_WIN32)
|
|
+#include <io.h>
|
|
+#include <process.h>
|
|
+#ifndef STDERR_FILENO
|
|
+#define STDERR_FILENO 2
|
|
+#endif
|
|
+#define getpid _getpid
|
|
+#define write _write
|
|
+#else
|
|
+#include <unistd.h>
|
|
+#endif
|
|
#include <array>
|
|
|
|
namespace Bungee::Assert {
|