diff options
author | Brad King <brad.king@kitware.com> | 2014-08-12 14:17:22 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2014-08-12 14:17:22 (GMT) |
commit | 1f8cfc3b5f4bd87216e48c6bf909b59f10b9065e (patch) | |
tree | 83b88bef435f7c15d2d9133da379277680511d38 | |
parent | 7365a9fe929c935a194987d3a4a68aff77129a2b (diff) | |
parent | 2b20110f681d180f12f4c200df1489eeb242d1b2 (diff) | |
download | CMake-1f8cfc3b5f4bd87216e48c6bf909b59f10b9065e.zip CMake-1f8cfc3b5f4bd87216e48c6bf909b59f10b9065e.tar.gz CMake-1f8cfc3b5f4bd87216e48c6bf909b59f10b9065e.tar.bz2 |
Merge topic 'vs-windows-sdk-desktop-arm'
2b20110f MSVC: Select default standard libraries for ARM platform
2dfcf0ed VS: Fix generation of desktop applications for ARM
dbb5a7ee CMakeDetermineCompilerId: Fix detection for VS ARM platform
-rw-r--r-- | Modules/CMakeDetermineCompilerId.cmake | 5 | ||||
-rw-r--r-- | Modules/CompilerId/VS-10.vcxproj.in | 1 | ||||
-rw-r--r-- | Modules/Platform/Windows-MSVC.cmake | 6 | ||||
-rw-r--r-- | Source/cmVisualStudio10TargetGenerator.cxx | 5 |
4 files changed, 16 insertions, 1 deletions
diff --git a/Modules/CMakeDetermineCompilerId.cmake b/Modules/CMakeDetermineCompilerId.cmake index a780fa6..1fca55d 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 bacbca4..a17d03d 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"> diff --git a/Modules/Platform/Windows-MSVC.cmake b/Modules/Platform/Windows-MSVC.cmake index 9d4aca2..0c2e21b 100644 --- a/Modules/Platform/Windows-MSVC.cmake +++ b/Modules/Platform/Windows-MSVC.cmake @@ -167,13 +167,17 @@ elseif(WINDOWS_PHONE OR WINDOWS_STORE) set(_FLAGS_CXX " /DUNICODE /D_UNICODE /GR /EHsc") if(WINDOWS_PHONE) set(CMAKE_C_STANDARD_LIBRARIES_INIT "WindowsPhoneCore.lib RuntimeObject.lib PhoneAppModelHost.lib") + elseif(MSVC_C_ARCHITECTURE_ID STREQUAL ARM OR MSVC_CXX_ARCHITECTURE_ID STREQUAL ARM) + set(CMAKE_C_STANDARD_LIBRARIES_INIT "kernel32.lib user32.lib") else() set(CMAKE_C_STANDARD_LIBRARIES_INIT "kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib") endif() else() set(_PLATFORM_DEFINES "/DWIN32") - if(MSVC_VERSION GREATER 1310) + if(MSVC_C_ARCHITECTURE_ID STREQUAL ARM OR MSVC_CXX_ARCHITECTURE_ID STREQUAL ARM) + set(CMAKE_C_STANDARD_LIBRARIES_INIT "kernel32.lib user32.lib") + elseif(MSVC_VERSION GREATER 1310) set(_RTC1 "/RTC1") set(_FLAGS_CXX " /GR /EHsc") set(CMAKE_C_STANDARD_LIBRARIES_INIT "kernel32.lib user32.lib gdi32.lib winspool.lib shell32.lib ole32.lib oleaut32.lib uuid.lib comdlg32.lib advapi32.lib") diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx index 291827a..1e9e8e8 100644 --- a/Source/cmVisualStudio10TargetGenerator.cxx +++ b/Source/cmVisualStudio10TargetGenerator.cxx @@ -2133,4 +2133,9 @@ void cmVisualStudio10TargetGenerator::WriteApplicationTypeSettings() "</MinimumVisualStudioVersion>\n", 2); } } + if (this->Platform == "ARM") + { + this->WriteString("<WindowsSDKDesktopARMSupport>true" + "</WindowsSDKDesktopARMSupport>", 2); + } } |