1
0
mirror of https://github.com/moparisthebest/curl synced 2024-11-14 21:45:13 -05:00

config-win32: Introduce build targets for VS2012+

Visual Studio 2012 introduced support for Windows Store apps as well as
supporting Windows Phone 8. Introduced build targets that allow more
modern APIs to be used as certain legacy ones are not available on these
new platforms.
This commit is contained in:
Steve Holme 2014-11-16 17:18:19 +00:00
parent 800094802e
commit 23e70e1cc6

View File

@ -502,26 +502,30 @@
# endif # endif
#endif #endif
/* Officially, Microsoft's Windows SDK versions 6.X do not support Windows /* Define some minimum and default build targets for Visual Studio */
2000 as a supported build target. VS2008 default installations provide #if defined(_MSC_VER)
an embedded Windows SDK v6.0A along with the claim that Windows 2000 is /* Officially, Microsoft's Windows SDK versions 6.X does not support Windows
a valid build target for VS2008. Popular belief is that binaries built 2000 as a supported build target. VS2008 default installations provides
with VS2008 using Windows SDK versions 6.X and Windows 2000 as a build an embedded Windows SDK v6.0A along with the claim that Windows 2000 is a
target are functional. */ valid build target for VS2008. Popular belief is that binaries built with
#if defined(_MSC_VER) && (_MSC_VER >= 1500) VS2008 using Windows SDK versions v6.X and Windows 2000 as a build target
are functional. */
# define VS2008_MIN_TARGET 0x0500 # define VS2008_MIN_TARGET 0x0500
#endif
/* When no build target is specified VS2008 default build target is Windows /* The minimum build target for VS2012 is Vista unless Update 1 is installed
Vista, which leaves out even Winsows XP. If no build target has been given and the v110_xp toolset is choosen. */
for VS2008 we will target the minimum Officially supported build target, # define VS2012_MIN_TARGET 0x0600
which happens to be Windows XP. */
#if defined(_MSC_VER) && (_MSC_VER >= 1500) /* VS2008 default build target is Windows Vista. We override default target
to be Windows XP. */
# define VS2008_DEF_TARGET 0x0501 # define VS2008_DEF_TARGET 0x0501
/* VS2012 default build target is Windows Vista. */
# define VS2012_DEF_TARGET 0x0600
#endif #endif
/* VS2008 default target settings and minimum build target check. */ /* VS2008 default target settings and minimum build target check. */
#if defined(_MSC_VER) && (_MSC_VER >= 1500) #if defined(_MSC_VER) && (_MSC_VER >= 1500) && (_MSC_VER <= 1600)
# ifndef _WIN32_WINNT # ifndef _WIN32_WINNT
# define _WIN32_WINNT VS2008_DEF_TARGET # define _WIN32_WINNT VS2008_DEF_TARGET
# endif # endif
@ -533,6 +537,19 @@
# endif # endif
#endif #endif
/* VS2012 default target settings and minimum build target check. */
#if defined(_MSC_VER) && (_MSC_VER >= 1700)
# ifndef _WIN32_WINNT
# define _WIN32_WINNT VS2012_DEF_TARGET
# endif
# ifndef WINVER
# define WINVER VS2012_DEF_TARGET
# endif
# if (_WIN32_WINNT < VS2012_MIN_TARGET) || (WINVER < VS2012_MIN_TARGET)
# error VS2012 does not support Windows build targets prior to Windows Vista
# endif
#endif
/* When no build target is specified Pelles C 5.00 and later default build /* When no build target is specified Pelles C 5.00 and later default build
target is Windows Vista. We override default target to be Windows 2000. */ target is Windows Vista. We override default target to be Windows 2000. */
#if defined(__POCC__) && (__POCC__ >= 500) #if defined(__POCC__) && (__POCC__ >= 500)