summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexey Edelev <alexey.edelev@qt.io>2024-02-14 14:38:34 +0100
committerAlexey Edelev <alexey.edelev@qt.io>2024-02-15 14:04:44 +0100
commit02e516281b9552e37b479cdd6207cde4d1e745b9 (patch)
tree99e3897ba8f29e4ee643fb86f9d18a3f1af216d7
parent0d9c92bfdfc267722e04ca0364f873abe261e5ec (diff)
Fix framework headers copying when module don't have header files
Amends 103eca1070a75bfa97d0b72b94e0c759ef0bcd1c Change-Id: I3caae60c022cd46a6d33691760b619920d6e778e Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
-rw-r--r--cmake/QtFrameworkHelpers.cmake24
1 files changed, 13 insertions, 11 deletions
diff --git a/cmake/QtFrameworkHelpers.cmake b/cmake/QtFrameworkHelpers.cmake
index 338febbb8c..750caf2cb8 100644
--- a/cmake/QtFrameworkHelpers.cmake
+++ b/cmake/QtFrameworkHelpers.cmake
@@ -131,17 +131,19 @@ function(qt_copy_framework_headers target)
COMMAND ${copy_fw_sync_headers_command})
endif()
- add_custom_command(
- OUTPUT ${out_files}
- DEPENDS ${target}_copy_fw_sync_headers ${in_files}
- COMMAND
- ${CMAKE_COMMAND} -E make_directory ${out_dirs}
- ${copy_commands}
- VERBATIM
- COMMENT "Copy the ${target} header files to the framework directory"
- )
- set_property(TARGET ${target} APPEND PROPERTY
- QT_COPIED_FRAMEWORK_HEADERS "${out_files}")
+ if(out_files)
+ add_custom_command(
+ OUTPUT ${out_files}
+ DEPENDS ${target}_copy_fw_sync_headers ${in_files}
+ COMMAND
+ ${CMAKE_COMMAND} -E make_directory ${out_dirs}
+ ${copy_commands}
+ VERBATIM
+ COMMENT "Copy the ${target} header files to the framework directory"
+ )
+ set_property(TARGET ${target} APPEND PROPERTY
+ QT_COPIED_FRAMEWORK_HEADERS "${out_files}")
+ endif()
endfunction()
function(qt_internal_generate_fake_framework_header target)