summaryrefslogtreecommitdiff
path: root/Modules
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2014-08-05 14:44:12 -0400
committerBrad King <brad.king@kitware.com>2014-08-12 10:08:37 -0400
commitdbb5a7ee315948b4f16e5c6a549db090e266e51d (patch)
treed983c8dc7b31876eda7196dbd75f4bb422fcd388 /Modules
parent5d3d9a22b28e99894dab2fe4fac0279fb422ace4 (diff)
downloadcmake-dbb5a7ee315948b4f16e5c6a549db090e266e51d.tar.gz
CMakeDetermineCompilerId: Fix detection for VS ARM platform
Add WindowsSDKDesktopARMSupport to the compiler id .vcxproj to avoid 'error MSB8022: Compiling Desktop applications for the ARM platform is not supported.' from VS. Inspired-by: Minmin Gong <minmin.gong@gmail.com> Inspired-by: Gilles Khouzam <gillesk@microsoft.com>
Diffstat (limited to 'Modules')
-rw-r--r--Modules/CMakeDetermineCompilerId.cmake5
-rw-r--r--Modules/CompilerId/VS-10.vcxproj.in1
2 files changed, 6 insertions, 0 deletions
diff --git a/Modules/CMakeDetermineCompilerId.cmake b/Modules/CMakeDetermineCompilerId.cmake
index a780fa6dab..1fca55d045 100644
--- a/Modules/CMakeDetermineCompilerId.cmake
+++ b/Modules/CMakeDetermineCompilerId.cmake
@@ -180,6 +180,11 @@ Id flags: ${testflags}
else()
set(id_system_version "")
endif()
+ if(id_platform STREQUAL ARM)
+ set(id_WindowsSDKDesktopARMSupport "<WindowsSDKDesktopARMSupport>true</WindowsSDKDesktopARMSupport>")
+ else()
+ set(id_WindowsSDKDesktopARMSupport "")
+ endif()
if(CMAKE_VS_WINCE_VERSION)
set(id_entrypoint "mainACRTStartup")
if("${vs_version}" VERSION_LESS 9)
diff --git a/Modules/CompilerId/VS-10.vcxproj.in b/Modules/CompilerId/VS-10.vcxproj.in
index bacbca4ea1..a17d03d0d2 100644
--- a/Modules/CompilerId/VS-10.vcxproj.in
+++ b/Modules/CompilerId/VS-10.vcxproj.in
@@ -12,6 +12,7 @@
<Keyword>Win32Proj</Keyword>
@id_system@
@id_system_version@
+ @id_WindowsSDKDesktopARMSupport@
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|@id_platform@'" Label="Configuration">