CMP0069-NEW-compiler.cmake 228 Bytes
Newer Older
1 2
cmake_policy(SET CMP0069 NEW)

3 4
set(_CMAKE_CXX_IPO_SUPPORTED_BY_CMAKE YES)
set(_CMAKE_CXX_IPO_MAY_BE_SUPPORTED_BY_COMPILER NO)
5 6 7

add_executable(foo main.cpp)
set_target_properties(foo PROPERTIES INTERPROCEDURAL_OPTIMIZATION TRUE)