CMake: Fix qt_find_package PROVIDED_TARGETS check
Change-Id: Ia551dcbca2d881f8bac36158abb0ac60b79f16f0 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
This commit is contained in:
parent
ddd7af87ef
commit
37467028bb
@ -2077,6 +2077,7 @@ macro(qt_find_package)
|
||||
# qt_find_package(SQLite3) call it is our intention to use the cmake package
|
||||
# in module mode.
|
||||
if (${ARGV0}_FOUND AND arg_PROVIDED_TARGETS)
|
||||
unset(any_target_found)
|
||||
foreach(expected_target ${arg_PROVIDED_TARGETS})
|
||||
if (TARGET ${expected_target})
|
||||
set(any_target_found TRUE)
|
||||
@ -2084,7 +2085,7 @@ macro(qt_find_package)
|
||||
endif()
|
||||
endforeach()
|
||||
if(NOT any_target_found)
|
||||
set(${ARGV0}_FOUND)
|
||||
unset(${ARGV0}_FOUND)
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
Loading…
x
Reference in New Issue
Block a user