From: Anthony Fok <foka@debian.org>
Subject: [PATCH] include: Suppress "use msvcrt" error in tchar.h when -mno-cygwin is used
Message-Id: <1452016223-3469-1-git-send-email-foka@debian.org>
Date: Tue,  5 Jan 2016 10:50:23 -0700

Fixes https://bugs.winehq.org/show_bug.cgi?id=39904

Tested on Debian GNU/Linux (sid, amd64).

Signed-off-by: Anthony Fok <foka@debian.org>
---
 include/tchar.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/include/tchar.h b/include/tchar.h
index 38885d4..13c8ee6 100644
--- a/include/tchar.h
+++ b/include/tchar.h
@@ -23,8 +23,8 @@
 #error Wine should not include tchar.h internally
 #endif
 
-#if defined(_UNICODE) || defined(_MBCS)
-#error You must use msvcrt when building in Unicode/MBCS mode
+#if !defined(__MSVCRT__) && (defined(_UNICODE) || defined(_MBCS))
+#error You must use msvcrt when building in Unicode/MBCS mode [-mno-cygwin]
 #endif
 
 #ifdef __cplusplus

-- 
2.6.4