summaryrefslogtreecommitdiff
path: root/nt/inc/ms-w32.h
diff options
context:
space:
mode:
Diffstat (limited to 'nt/inc/ms-w32.h')
-rw-r--r--nt/inc/ms-w32.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/nt/inc/ms-w32.h b/nt/inc/ms-w32.h
index d1534336c4..bb8ae6ad8f 100644
--- a/nt/inc/ms-w32.h
+++ b/nt/inc/ms-w32.h
@@ -185,6 +185,13 @@ extern struct tm * sys_localtime (const time_t *);
supply the 2nd arg correctly, so don't use _setjmp directly in that
case. */
#undef HAVE__SETJMP
+
+/* Unlike MS and mingw.org, MinGW64 doesn't define gai_strerror as an
+ inline function in a system header file, and instead seems to
+ require to link against ws2_32.a. But we don't want to link with
+ -lws2_32, as that would make Emacs dependent on the respective DLL.
+ So MinGW64 is amply punished here by the following: */
+#undef HAVE_GAI_STRERROR
#endif
/* The following is needed for recovery from C stack overflows. */
@@ -284,6 +291,9 @@ extern int sys_umask (int);
/* Map to MSVC names. */
#define execlp _execlp
#define execvp _execvp
+#include <stdint.h> /* for intptr_t */
+extern intptr_t _execvp (const char *, char **);
+extern intptr_t execve (const char *, char * const *, char * const *);
#define fdatasync _commit
#define fdopen _fdopen
#define fsync _commit