Commit e8213404 authored by Brad King's avatar Brad King
Browse files

FindDoxygen: Ensure policy settings allow use of IN_LIST

In commit v3.9.0-rc1~55^2 (Improve Doxygen support, 2017-04-10)
use of the `IN_LIST` condition was added, but this is only supported
when policy CMP0057 is set to NEW.  Add a policy scope around the
module and enable the policy within it.  Otherwise it works only
in projects that happen to enable the policy.

Fixes: #18361
parent f478fa63
...@@ -370,6 +370,9 @@ Deprecated Hint Variables ...@@ -370,6 +370,9 @@ Deprecated Hint Variables
#]=======================================================================] #]=======================================================================]
cmake_policy(PUSH)
cmake_policy(SET CMP0057 NEW) # if IN_LIST
# For backwards compatibility support # For backwards compatibility support
if(Doxygen_FIND_QUIETLY) if(Doxygen_FIND_QUIETLY)
set(DOXYGEN_FIND_QUIETLY TRUE) set(DOXYGEN_FIND_QUIETLY TRUE)
...@@ -1108,3 +1111,5 @@ doxygen_add_docs() for target ${targetName}") ...@@ -1108,3 +1111,5 @@ doxygen_add_docs() for target ${targetName}")
) )
endfunction() endfunction()
cmake_policy(POP)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment