mirror of
https://github.com/neovim/neovim.git
synced 2025-09-16 08:18:17 +00:00
build/msvc: Add missing WIN32 macro
MSVC predefines `_WIN32`, but not `WIN32`. Also, some unnecessary includes have been removed.
This commit is contained in:
@@ -204,6 +204,7 @@ int main(void)
|
|||||||
if(MSVC)
|
if(MSVC)
|
||||||
# XXX: /W4 gives too many warnings. #3241
|
# XXX: /W4 gives too many warnings. #3241
|
||||||
add_definitions(/W3 -D_CRT_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_DEPRECATE)
|
add_definitions(/W3 -D_CRT_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_DEPRECATE)
|
||||||
|
add_definitions(-DWIN32)
|
||||||
else()
|
else()
|
||||||
add_definitions(-Wall -Wextra -pedantic -Wno-unused-parameter
|
add_definitions(-Wall -Wextra -pedantic -Wno-unused-parameter
|
||||||
-Wstrict-prototypes -std=gnu99)
|
-Wstrict-prototypes -std=gnu99)
|
||||||
@@ -223,6 +224,9 @@ endif()
|
|||||||
if(MINGW)
|
if(MINGW)
|
||||||
# Use POSIX compatible stdio in Mingw
|
# Use POSIX compatible stdio in Mingw
|
||||||
add_definitions(-D__USE_MINGW_ANSI_STDIO)
|
add_definitions(-D__USE_MINGW_ANSI_STDIO)
|
||||||
|
endif()
|
||||||
|
if(WIN32)
|
||||||
|
# Windows Vista is the minimum supported version
|
||||||
add_definitions(-D_WIN32_WINNT=0x0600)
|
add_definitions(-D_WIN32_WINNT=0x0600)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
@@ -7,11 +7,6 @@
|
|||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stdbool.h>
|
#include <stdbool.h>
|
||||||
|
|
||||||
#ifdef WIN32
|
|
||||||
# include <wchar.h>
|
|
||||||
# include <winnls.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <msgpack.h>
|
#include <msgpack.h>
|
||||||
|
|
||||||
#include "nvim/ascii.h"
|
#include "nvim/ascii.h"
|
||||||
|
Reference in New Issue
Block a user