CMake: Fix missing dependencies in *Depends headers
In qt_internal_create_module_depends_file we're checking the target
property INTERFACE_MODULE_HAS_HEADERS. However, this property is not
exported, and in per-repo builds we do not have access to this.
As we cannot export INTERFACE_* properties, we export another one,
called _qt_module_has_headers.
This amends commit 598e873c84
.
Fixes: QTBUG-88503
Change-Id: I04b3e24add6e95b577a049c80683b7361ff72f59
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
This commit is contained in:
parent
d41eed01a4
commit
e0d709d8d3
@ -158,8 +158,11 @@ function(qt_internal_add_module target)
|
||||
endif()
|
||||
|
||||
# Module headers:
|
||||
set_property(TARGET "${target}" APPEND PROPERTY EXPORT_PROPERTIES _qt_module_has_headers)
|
||||
if(${arg_NO_MODULE_HEADERS} OR ${arg_NO_SYNC_QT})
|
||||
set_target_properties("${target}" PROPERTIES INTERFACE_MODULE_HAS_HEADERS OFF)
|
||||
set_target_properties("${target}" PROPERTIES
|
||||
INTERFACE_MODULE_HAS_HEADERS OFF
|
||||
_qt_module_has_headers OFF)
|
||||
else()
|
||||
set_target_properties("${target}" PROPERTIES INTERFACE_MODULE_INCLUDE_NAME "${module_include_name}")
|
||||
|
||||
@ -178,7 +181,9 @@ function(qt_internal_add_module target)
|
||||
message(STATUS "Running syncqt for module: '${module_include_name}' ")
|
||||
execute_process(COMMAND ${syncqt_full_command})
|
||||
|
||||
set_target_properties("${target}" PROPERTIES INTERFACE_MODULE_HAS_HEADERS ON)
|
||||
set_target_properties("${target}" PROPERTIES
|
||||
INTERFACE_MODULE_HAS_HEADERS ON
|
||||
_qt_module_has_headers ON)
|
||||
|
||||
### FIXME: Can we replace headers.pri?
|
||||
set(module_include_dir "${QT_BUILD_DIR}/include/${module_include_name}")
|
||||
|
@ -139,7 +139,13 @@ function(qt_internal_create_module_depends_file target)
|
||||
continue()
|
||||
endif()
|
||||
else()
|
||||
get_target_property(module_has_headers Qt::${dep} INTERFACE_MODULE_HAS_HEADERS)
|
||||
get_target_property(is_versionless_target Qt::${dep} _qt_is_versionless_target)
|
||||
if(is_versionless_target)
|
||||
get_target_property(module_has_headers ${QT_CMAKE_EXPORT_NAMESPACE}::${dep}
|
||||
_qt_module_has_headers)
|
||||
else()
|
||||
get_target_property(module_has_headers Qt::${dep} _qt_module_has_headers)
|
||||
endif()
|
||||
if (NOT module_has_headers)
|
||||
continue()
|
||||
endif()
|
||||
|
Loading…
Reference in New Issue
Block a user