Skip to content
This repository was archived by the owner on Aug 31, 2021. It is now read-only.

Commit 34c88cb

Browse files
committed
[[ VS2015 ]] Tweak libpq so it builds under VS2015
This patch ensures that libpq builds under VS2015. It tweaks a win32 compatibility routine definition based on VS version and ensure win32error.c is included in the build which provides the _dosmaperr function which is no longer present in the VS CRT.
1 parent 8652b4e commit 34c88cb

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

libpq/libpq.gyp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@
111111
'src/system.c',
112112
'src/win32.c',
113113
'src/win32setlocale.c',
114+
'src/win32error.c',
114115
],
115116

116117
'link_settings':

libpq/src/chklocale.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ win32_langinfo(const char *ctype)
203203
{
204204
char *r = NULL;
205205

206-
#if (_MSC_VER >= 1700)
206+
#if (_MSC_VER == 1700)
207207
_locale_t loct = NULL;
208208

209209
loct = _create_locale(LC_CTYPE, ctype);

0 commit comments

Comments
 (0)