In June, we announced enhanced targeting for Windows XP using the Visual Studio 2012 C++ compiler and libraries. This feature has been included in Visual Studio 2012 Update 1. You can download it from here. The purpose of this article is to provide an overview of the Windows XP targeting experience, the level of C++ runtime support, and noteworthy differences from the default experience shipped in Visual Studio 2012 at RTM.
In order to target Windows XP, switch from the default v110 toolset to the newly introduced v110_xp toolset inside your project’s property pages. This new platform toolset points to a repackaged version of the Windows 7 SDK shipped in Visual Studio 2010 instead of the Windows 8 SDK, but uses the same Visual Studio 2012 compiler. The v110_xp toolset also sets useful defaults such as a compatible linker subsystem version for downlevel targeting. Only executables built with this platform toolset are supported to run on Windows XP, but those same executables will also run on Vista, Windows 7 and Windows 8.
The static and dynamic link libraries for the CRT, ConCRT/PPL, STL, and MFC have been updated in-place to add runtime support for Windows XP and Windows Server 2003. Applications written in C++/CLI which target the .NET Framework 4.0 will also run on Windows XP and Windows Server 2003. For these operating systems, the supported versions are Windows XP SP3 for x86, Windows XP SP2 for x64, and Windows Server 2003 SP2 for both x86 and x64.
v110 (Store Apps)
Visual Studio 2012 solutions and projects which have been switched to the v110_xp toolset can be built from the command line using MSBuild or DEVENV without additional steps.
However, if you wish to use CL and Link directly, additional steps are needed. Note that the steps below may be automated by creating a batch script.
As always, we'd love to hear your feedback. Please submit bugs to Visual Studio Connect, and suggestions to Visual Studio UserVoice.
Why are you giving C++ 11 XP compatibility, but ignoring the cries of thousands of developers for .NET 4.5 to work on XP? (Really, most of us would be happy with .NET 4.5 not seriously messing up XP development.)
@Stephen, different team. That would require involvement of CLR team. See blogs.msdn.com/.../dotnet
I clicked on the download "here" link. Which file should I be downloading for the Update 1 CTP 3 so I can target xp?
I'm very eager and excited to take advantage of the improved C++ support this will make available to those of us that can't drop XP. Are there any limitations on use of C++11 features when targeting XP?
I would be thrilled if we could have an update on how things are progressing towards the release (not CTP) version of Update 1, since I assume it would be unwise to actually ship a release build on the CTP. Within whatever limits company policy imposes, please keep us up-to-date, so we can refine our plans.
The Remote Tools for Visual Studio 2012 do not support remote debugging on an XP client. When debugging on Windows XP is required, it is recommended to use the debuggers of an older version of Visual Studio, such as Visual Studio 2010, for local or remote debugging. This is in line with the Windows Vista experience for Visual Studio 2012 RTM, which is a runtime target but not a remote debugging target.”
Use Visual Studio 2010 to debug programs built by Visual Studio 2012 ?
Why not make the Remote Tools for Visual Studio 2012 run on XP ?
@Todd: There are no limitations to C++11 support when targeting Windows XP. I cannot comment on the release date, but a final CTP was released on 10/29 which fixes the known issues above. It is available through the same download link.
@David: The remote debugger for VS2012 is designed to take advantage of new operating system features in Windows 7 and above, which prevents it from running on Windows Vista or Windows XP. If debugging with the VS2012 debugger is important for your scenarios, please post it as a suggestion on UserVoice for visibility.
CTP4: Many warnings:
d:\qpsoft\mydev\include\sal_supp.h(57) : warning C4005: '__useHeader' : macro redefinition (html\parser\HTMLSourceTracker.cpp)
D:\qpSOFT\MyDEV\include\sal.h(2872) : see previous definition of '__useHeader'
d:\qpsoft\mydev\include\specstrings_supp.h(77) : warning C4005: '__on_failure' : macro redefinition (html\parser\HTMLSourceTracker.cpp)
D:\qpSOFT\MyDEV\include\sal.h(2882) : see previous definition of '__on_failure'
d:\qpsoft\mydev\include\sal_supp.h(57) : warning C4005: '__useHeader' : macro redefinition (html\parser\HTMLTokenizer.cpp)
d:\qpsoft\mydev\include\specstrings_supp.h(77) : warning C4005: '__on_failure' : macro redefinition (html\parser\HTMLTokenizer.cpp)
d:\qpsoft\mydev\include\sal_supp.h(57) : warning C4005: '__useHeader' : macro redefinition (html\parser\HTMLTreeBuilder.cpp)
d:\qpsoft\mydev\include\specstrings_supp.h(77) : warning C4005: '__on_failure' : macro redefinition (html\parser\HTMLTreeBuilder.cpp)
We modified the sal.h file in VC\include to fix this issue. It seems that your project has its own copy of sal.h (D:\qpSOFT\MyDEV\include\sal.h). If you update this file with the new version in VC\include, this should resolve the issue.
It's not the sal.h copy, just itself.
See: sal_supp.h that from Windows SDK 7.1A.
LN26: #define __useHeader __declspec("SAL_useHeader()")
and sal.h from VC/include
#ifdef _USING_V110_SDK71_ // [
#ifndef _PREFAST_ // [
#else // ][
#error Code analysis is not supported when using Visual C++ 11.0 with the Windows 7.1 SDK.
#endif // ]
#define __useHeader _Use_decl_anno_impl_
In here should changed to:
And same changes should go.
#define __on_failure(annotes) _On_failure_impl_(annotes _SAL_nop_impl_)
When's the real (final) coming out?
Final already have now. Thanx. Is download w/o web? Hash available?
@Arlo: To download an offline version you may follow the steps here: