We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 56a90d6 commit 7b2ca27Copy full SHA for 7b2ca27
tools/pybind11Tools.cmake
@@ -184,6 +184,11 @@ function(pybind11_add_module target_name)
184
if(CMAKE_VERSION VERSION_LESS 3.9 OR PYBIND11_CLASSIC_LTO)
185
_pybind11_add_lto_flags(${target_name} ${ARG_THIN_LTO})
186
elseif(NOT DEFINED CMAKE_INTERPROCEDURAL_OPTIMIZATION)
187
+ cmake_policy(GET CMP0069 IPO_POL)
188
+ if(CMP0069 STREQUAL "NEW")
189
+ cmake_policy(SET CMP0069 NEW)
190
+ endif()
191
+
192
include(CheckIPOSupported)
193
check_ipo_supported(RESULT supported OUTPUT error)
194
if(supported)
0 commit comments