summaryrefslogtreecommitdiff
path: root/Modules/CheckIPOSupported.cmake
diff options
context:
space:
mode:
authorNiels Dekker <N.Dekker@lumc.nl>2018-09-09 23:04:59 +0200
committerBrad King <brad.king@kitware.com>2018-09-17 10:53:10 -0400
commit567fabe88e97c3e39503fd353b484648bcf1cbb2 (patch)
tree7fb0dd095df92c5425896f900a78e46c6ed75633 /Modules/CheckIPOSupported.cmake
parentccb6dab9f19bd19968dc2b94806dfc4cf22cdd79 (diff)
downloadcmake-567fabe88e97c3e39503fd353b484648bcf1cbb2.tar.gz
IPO: INTERPROCEDURAL_OPTIMIZATION (LTCG) for Visual Studio
Add IPO support for Visual Studio (which is referred to by VS as "Link Time Code Generation" and "Whole Program Optimization"), for VS version >= 10. This allows CMake/VS users to enable IPO by setting property `INTERPROCEDURAL_OPTIMIZATION`. Fixes: #16748
Diffstat (limited to 'Modules/CheckIPOSupported.cmake')
-rw-r--r--Modules/CheckIPOSupported.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/CheckIPOSupported.cmake b/Modules/CheckIPOSupported.cmake
index 3344834cd4..ad8852c069 100644
--- a/Modules/CheckIPOSupported.cmake
+++ b/Modules/CheckIPOSupported.cmake
@@ -226,7 +226,7 @@ function(check_ipo_supported)
endif()
endforeach()
- if(CMAKE_GENERATOR MATCHES "^Visual Studio ")
+ if(CMAKE_GENERATOR MATCHES "^Visual Studio 9 ")
_ipo_not_supported("CMake doesn't support IPO for current generator")
return()
endif()