diff options
author | Rechi <Rechi@users.noreply.github.com> | 2020-09-25 04:01:17 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2020-09-25 17:11:14 (GMT) |
commit | 561d4b4a47281e715b2868811093e15fd560d307 (patch) | |
tree | 65c14faced7c2f9e517add802ae5e927ba290a2d /Modules/CMakeGenericSystem.cmake | |
parent | 0cd1ef0932dfb4c0c2c7d0eaa5d91a8593b3a3d7 (diff) | |
download | CMake-561d4b4a47281e715b2868811093e15fd560d307.zip CMake-561d4b4a47281e715b2868811093e15fd560d307.tar.gz CMake-561d4b4a47281e715b2868811093e15fd560d307.tar.bz2 |
VS: Fix CMAKE_INSTALL_PREFIX with GENERATOR_PLATFORM for x64 and ARM
Generate the same default `CMAKE_INSTALL_PREFIX` if a project is
configured with CMAKE_GENERATOR_PLATFORM (`cmake -G "Visual Studio
[...]" -A x64` and `cmake -G "Visual Studio [...]" -A ARM`) instead of
the prior CMake 3.1 way (`cmake -G "Visual Studio [...] Win64"` and
`cmake -G "Visual Studio [...] ARM"`).
Diffstat (limited to 'Modules/CMakeGenericSystem.cmake')
-rw-r--r-- | Modules/CMakeGenericSystem.cmake | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Modules/CMakeGenericSystem.cmake b/Modules/CMakeGenericSystem.cmake index 6f665a6..649b6f7 100644 --- a/Modules/CMakeGenericSystem.cmake +++ b/Modules/CMakeGenericSystem.cmake @@ -77,10 +77,14 @@ function(GetDefaultWindowsPrefixBase var) # if("${CMAKE_GENERATOR}" MATCHES "(Win64|IA64)") set(arch_hint "x64") + elseif("${CMAKE_GENERATOR_PLATFORM}" MATCHES "x64") + set(arch_hint "x64") elseif("${CMAKE_GENERATOR_PLATFORM}" MATCHES "ARM64") set(arch_hint "ARM64") elseif("${CMAKE_GENERATOR}" MATCHES "ARM") set(arch_hint "ARM") + elseif("${CMAKE_GENERATOR_PLATFORM}" MATCHES "ARM") + set(arch_hint "ARM") elseif("${CMAKE_SIZEOF_VOID_P}" STREQUAL "8") set(arch_hint "x64") elseif("$ENV{LIB}" MATCHES "(amd64|ia64)") |