summarylogtreecommitdiffstats
path: root/0042-Fix-build-for-Mingw-w64.patch
blob: 043f0f7592502085bc8568f6b5a6d13170b0196d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
From 9b99858bba9441e5d6048006c2e092b0f64bb03e Mon Sep 17 00:00:00 2001
From: Sergei Litvin <litvindev@gmail.com>
Date: Tue, 17 Jun 2025 12:43:40 +0200
Subject: [PATCH] Fix build for Mingw-w64

---
 env/emacs/xrefactory.el | 3 ++-
 src/stdinc.h            | 3 +--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/env/emacs/xrefactory.el b/env/emacs/xrefactory.el
index 39a6db7..79e854e 100644
--- a/env/emacs/xrefactory.el
+++ b/env/emacs/xrefactory.el
@@ -93,7 +93,8 @@
 ;; current platform identification (will be used in default settings)
 
 (if (or (string-match "-nt" system-configuration) 
-		(string-match "-win" system-configuration))
+		(string-match "-win" system-configuration)
+		(string-match "-mingw32" system-configuration))
 	(defvar xref-platform 'windows)
   (defvar xref-platform 'unix)
 )
diff --git a/src/stdinc.h b/src/stdinc.h
index e35b69e..0009d56 100644
--- a/src/stdinc.h
+++ b/src/stdinc.h
@@ -12,12 +12,11 @@
 #ifdef __OS2__			/*SBD*/
 #include <os2.h>		/*SBD*/
 #else					/*SBD*/
-#include <unistd.h>		/*SBD*/
 #include <dirent.h>		/*SBD*/
 #endif					/*SBD*/
 #endif					/*SBD*/
 
-
+#include <unistd.h>		/*SBD*/
 #include <stdio.h>		/*SBD*/
 #include <stdlib.h>		/*SBD*/
 #include <ctype.h>		/*SBD*/
-- 
2.50.0.windows.1