From 1e197cf74674f2884b05e34b5ce994ba1ca05df1 Mon Sep 17 00:00:00 2001 From: Werneck Date: Wed, 13 Nov 2019 22:24:04 -0200 Subject: [PATCH] Adjustmente for MSVC build. --- .vscode/c_cpp_properties.json | 1 + .vscode/tasks.json | 12 ++++++++---- client/src/include/ipc-client-internals.h | 5 +++++ 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/.vscode/c_cpp_properties.json b/.vscode/c_cpp_properties.json index 06ed698..e309b1d 100644 --- a/.vscode/c_cpp_properties.json +++ b/.vscode/c_cpp_properties.json @@ -9,6 +9,7 @@ ], "defines": [ "_DEBUG", + "DEBUG", "UNICODE", "_UNICODE" ], diff --git a/.vscode/tasks.json b/.vscode/tasks.json index 10bf42f..05967f7 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -11,10 +11,14 @@ "/favor:AMD64", "/c", "/EHsc", - "/I","${workspaceFolder}/client/src/include", - "/I","${workspaceFolder}/common/src/include", - "/I","C:/Program Files/pw3270/sdk/include", - "/I","${env:VCPKG_ROOT}/x64-windows-static/include", + "/I", + "${workspaceFolder}/client/src/include", + "/I", + "${workspaceFolder}/common/src/include", + "/I", + "C:/Program Files/pw3270/sdk/include", + "/I", + "${env:VCPKG_ROOT}/x64-windows-static/include", "${file}" ], "group": { diff --git a/client/src/include/ipc-client-internals.h b/client/src/include/ipc-client-internals.h index da23d00..c89203e 100644 --- a/client/src/include/ipc-client-internals.h +++ b/client/src/include/ipc-client-internals.h @@ -82,6 +82,11 @@ #define GNUC_UNUSED #endif +#if defined(_MSC_VER) + // MSVC doesn't have a strcasecmp() function; instead it has _stricmp. + #define strcasecmp(a,b) _stricmp(a,b) +#endif // _MSC_VER + #ifdef HAVE_ICONV #include #endif // HAVE_ICONV -- libgit2 0.21.2