changeset 36723:1f9bbd1d6b8a

xdiff: fix builds on Windows This works on my ancient Fedora system too, without warnings. There are, however, warnings about various 64 to 32 bit conversions on Windows that need to be examined.
author Matt Harbison <matt_harbison@yahoo.com>
date Sun, 04 Mar 2018 15:16:42 -0500
parents 6bacb2f663cb
children ca201470abb4
files mercurial/thirdparty/xdiff/xdiffi.c mercurial/thirdparty/xdiff/xinclude.h
diffstat 2 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/thirdparty/xdiff/xdiffi.c	Mon Mar 05 01:08:40 2018 +0530
+++ b/mercurial/thirdparty/xdiff/xdiffi.c	Sun Mar 04 15:16:42 2018 -0500
@@ -30,6 +30,10 @@
 #define XDL_SNAKE_CNT 20
 #define XDL_K_HEUR 4
 
+/* VC 2008 doesn't know about the inline keyword. */
+#if defined(_MSC_VER)
+#define inline __forceinline
+#endif
 
 
 typedef struct s_xdpsplit {
--- a/mercurial/thirdparty/xdiff/xinclude.h	Mon Mar 05 01:08:40 2018 +0530
+++ b/mercurial/thirdparty/xdiff/xinclude.h	Sun Mar 04 15:16:42 2018 -0500
@@ -26,7 +26,6 @@
 #include <ctype.h>
 #include <stdio.h>
 #include <stdlib.h>
-#include <unistd.h>
 #include <string.h>
 #include <limits.h>