提交 2d778434 编写于 作者: A Augusto Fraga Giachero

Enable cmake CMP0077 policy

When building OpenCV as a sub-project using cmake's add_subdirectory()
the OpenCV's build options would be overwritten to its default
state. With cmake 3.13+ the CMP0077 policy, option() honors previous
definitions via set().
上级 8b438612
......@@ -68,6 +68,9 @@ if(POLICY CMP0075)
cmake_policy(SET CMP0075 NEW) # CMake 3.12+: Include file check macros honor `CMAKE_REQUIRED_LIBRARIES`
endif()
if(POLICY CMP0077)
cmake_policy(SET CMP0077 NEW) # CMake 3.13+: option() honors normal variables.
endif()
#
# Configure OpenCV CMake hooks
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册