summaryrefslogtreecommitdiff
path: root/src/Make_mvc.mak
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2020-02-12 21:52:32 +0100
committerBram Moolenaar <Bram@vim.org>2020-02-12 21:52:32 +0100
commit3fb377fa78131004138b22a87afe33eeb7649b94 (patch)
tree1ce664cf537cc0db3b176fe575039f6090a6737b /src/Make_mvc.mak
parent2f189750887636fecd440d7ef353d9224e48713f (diff)
downloadvim-git-3fb377fa78131004138b22a87afe33eeb7649b94.tar.gz
patch 8.2.0249: MS-Windows: various warningsv8.2.0249
Problem: MS-Windows: various warnings. Solution: Set the charset to utf-8. Add _WIN32_WINNT and _USING_V110_SDK71_. (Ken Takata, closes #5625)
Diffstat (limited to 'src/Make_mvc.mak')
-rw-r--r--src/Make_mvc.mak9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/Make_mvc.mak b/src/Make_mvc.mak
index b95e936f0..da9a911d0 100644
--- a/src/Make_mvc.mak
+++ b/src/Make_mvc.mak
@@ -626,6 +626,12 @@ NODEFAULTLIB =
NODEFAULTLIB = /nodefaultlib
!endif
+# Specify source code charset to suppress warning C4819 on non-English
+# environment. Only available from MSVC 14.
+!if $(MSVC_MAJOR) >= 14
+CFLAGS = $(CFLAGS) /source-charset:utf-8
+!endif
+
# Use multiprocess build on MSVC 10
!if ("$(USE_MP)" == "yes") && ($(MSVC_MAJOR) >= 10)
CFLAGS = $(CFLAGS) /MP
@@ -669,6 +675,9 @@ CFLAGS = $(CFLAGS) $(WP64CHECK)
CFLAGS = $(CFLAGS) $(OPTFLAG) -DNDEBUG $(CPUARG)
RCFLAGS = $(rcflags) $(rcvars) -DNDEBUG
+! if "$(CL)" == "/D_USING_V110_SDK71_"
+RCFLAGS = $(RCFLAGS) /D_USING_V110_SDK71_
+! endif
! ifdef USE_MSVCRT
CFLAGS = $(CFLAGS) /MD
LIBC = msvcrt.lib