OPTION(ENABLE_TEST "Enable unit and regression tests" ON)
SET(POSIX_REGEX_LIB "AUTO" CACHE STRING "Choose what library should provide POSIX regular expression support")
SET(ENABLE_SAFESEH "AUTO" CACHE STRING "Enable use of /SAFESEH linker flag (MSVC only)")
-SET(WINDOWS_VERSION "WINXP" CACHE STRING "Set Windows version to use (Windows only)")
+SET(WINDOWS_VERSION "" CACHE STRING "Set Windows version to use (Windows only)")
IF(ENABLE_TEST)
ENABLE_TESTING()
SET(WINVER 0x0600)
ELSEIF(WINDOWS_VERSION STREQUAL "WS03")
SET(WINVER 0x0502)
- ELSE(WINDOWS_VERSION STREQUAL "WIN8")
+ ELSEIF(WINDOWS_VERSION STREQUAL "WINXP")
SET(WINVER 0x0501)
+ ELSE(WINDOWS_VERSION STREQUAL "WIN8")
+ # The default is to use Windows 2000 API.
+ SET(WINVER 0x0500)
ENDIF(WINDOWS_VERSION STREQUAL "WIN8")
SET(_WIN32_WINNT ${WINVER})
ENDIF(WIN32)