1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-08 14:02:16 +03:00

Do not rely on the _WIN32_WINNT macro as vs2005 does not define it by default.

Instead, always assume winNT unless the makefile explicitly sets
SQLITE_OS_WINNT=0.

FossilOrigin-Name: 1ce4d21d521c383f2607222006023b6812f147bc
This commit is contained in:
drh
2012-01-30 16:02:43 +00:00
parent b21a8e4834
commit d794e8b026
3 changed files with 22 additions and 10 deletions

View File

@@ -91,11 +91,23 @@
/*
** Determine if we are dealing with Windows NT.
**
** We ought to be able to determine if we are compiling for win98 or winNT
** using the _WIN32_WINNT macro as follows:
**
** #if defined(_WIN32_WINNT)
** # define SQLITE_OS_WINNT 1
** #else
** # define SQLITE_OS_WINNT 0
** #endif
**
** However, vs2005 does not set _WIN32_WINNT by default, as it ought to,
** so the above test does not work. We'll just assume that everything is
** winNT unless the programmer explicitly says otherwise by setting
** SQLITE_OS_WINNT to 0.
*/
#if defined(_WIN32_WINNT)
#if SQLITE_OS_WIN && !defined(SQLITE_OS_WINNT)
# define SQLITE_OS_WINNT 1
#else
# define SQLITE_OS_WINNT 0
#endif
/*