From a6c11d3e09f8ebc923eb043e6c090997d21f2ac9 Mon Sep 17 00:00:00 2001 From: Simon Hausmann Date: Wed, 5 Jun 2019 13:49:08 +0200 Subject: Add support for private module .pri files Generate a pri file for public and private interfaces, but map CONFIG += internal_module to a cmake option and skip the former if set. Task-number: QTBUG-75666 Change-Id: I3f4baf1277094f4c22149a9e8769734baf9a235f Reviewed-by: Alexandru Croitor --- cmake/QtBuild.cmake | 61 ++++++++++++++++++---- src/platformsupport/accessibility/CMakeLists.txt | 1 + src/platformsupport/clipboard/CMakeLists.txt | 1 + src/platformsupport/devicediscovery/CMakeLists.txt | 1 + src/platformsupport/edid/CMakeLists.txt | 1 + .../eglconvenience/.prev_CMakeLists.txt | 1 + src/platformsupport/eglconvenience/CMakeLists.txt | 1 + .../eventdispatchers/.prev_CMakeLists.txt | 1 + .../eventdispatchers/CMakeLists.txt | 1 + src/platformsupport/fbconvenience/CMakeLists.txt | 1 + .../fontdatabases/.prev_CMakeLists.txt | 1 + src/platformsupport/fontdatabases/CMakeLists.txt | 1 + .../glxconvenience/.prev_CMakeLists.txt | 1 + src/platformsupport/glxconvenience/CMakeLists.txt | 1 + src/platformsupport/graphics/CMakeLists.txt | 1 + src/platformsupport/input/.prev_CMakeLists.txt | 1 + src/platformsupport/input/CMakeLists.txt | 1 + src/platformsupport/input/xkbcommon/CMakeLists.txt | 1 + .../kmsconvenience/.prev_CMakeLists.txt | 1 + src/platformsupport/kmsconvenience/CMakeLists.txt | 1 + .../linuxaccessibility/.prev_CMakeLists.txt | 1 + .../linuxaccessibility/CMakeLists.txt | 1 + .../platformcompositor/CMakeLists.txt | 1 + src/platformsupport/services/CMakeLists.txt | 1 + src/platformsupport/themes/CMakeLists.txt | 1 + .../vkconvenience/.prev_CMakeLists.txt | 1 + src/platformsupport/vkconvenience/CMakeLists.txt | 1 + .../windowsuiautomation/CMakeLists.txt | 1 + src/plugins/platforms/eglfs/.prev_CMakeLists.txt | 1 + src/plugins/platforms/eglfs/CMakeLists.txt | 1 + .../eglfs_kms_support/CMakeLists.txt | 1 + src/plugins/platforms/xcb/.prev_CMakeLists.txt | 1 + src/plugins/platforms/xcb/CMakeLists.txt | 1 + util/cmake/pro2cmake.py | 2 + 34 files changed, 84 insertions(+), 11 deletions(-) diff --git a/cmake/QtBuild.cmake b/cmake/QtBuild.cmake index 854a5f3a45..afd50c55ac 100644 --- a/cmake/QtBuild.cmake +++ b/cmake/QtBuild.cmake @@ -294,20 +294,28 @@ function(qt_set_up_developer_build) endfunction() # Generates module .pri files for consumption by qmake -function(qt_generate_module_pri_file target target_path pri_file_name_var) - set(flags) +function(qt_generate_module_pri_file target target_path pri_files_var) + set(flags INTERNAL_MODULE) set(options) set(multiopts QMAKE_MODULE_CONFIG) cmake_parse_arguments(arg "${flags}" "${options}" "${multiopts}" ${ARGN}) qt_internal_module_info(module "${target}") qt_path_join(pri_file_name "${target_path}" "qt_lib_${module_lower}.pri") - set("${pri_file_name_var}" "${pri_file_name}" PARENT_SCOPE) + set(pri_files "${pri_file_name}") get_target_property(enabled_features "${target}" QT_ENABLED_PUBLIC_FEATURES) get_target_property(disabled_features "${target}" QT_DISABLED_PUBLIC_FEATURES) - string (REPLACE ";" " " enabled_features "${enabled_features}") - string (REPLACE ";" " " disabled_features "${disabled_features}") + get_target_property(enabled_private_features "${target}" QT_ENABLED_PRIVATE_FEATURES) + get_target_property(disabled_private_features "${target}" QT_DISABLED_PRIVATE_FEATURES) + + foreach(var enabled_features disabled_features enabled_private_features disabled_private_features) + if(${var} STREQUAL "${var}-NOTFOUND") + set(${var} "") + else() + string (REPLACE ";" " " ${var} "${${var}}") + endif() + endforeach() if(arg_QMAKE_MODULE_CONFIG) string(REPLACE ";" " " module_config "${arg_QMAKE_MODULE_CONFIG}") @@ -316,9 +324,10 @@ function(qt_generate_module_pri_file target target_path pri_file_name_var) set(module_config "") endif() - file(GENERATE - OUTPUT "${pri_file_name}" - CONTENT + if (NOT ${arg_INTERNAL_MODULE}) + file(GENERATE + OUTPUT "${pri_file_name}" + CONTENT "QT.${module_lower}.VERSION = ${PROJECT_VERSION} QT.${module_lower}.name = ${module} QT.${module_lower}.module = ${module_versioned} @@ -333,8 +342,31 @@ QT.${module_lower}.DEFINES = QT_${module_define}_LIB QT.${module_lower}.enabled_features = ${enabled_features} QT.${module_lower}.disabled_features = ${disabled_features}${module_config} QT_MODULES += ${module_lower} +" + ) + endif() + + qt_path_join(private_pri_file "${target_path}" "qt_lib_${module_lower}_private.pri") + list(APPEND pri_files "${private_pri_file}") + + file(GENERATE + OUTPUT "${private_pri_file}" + CONTENT + "QT.${module_lower}_private.VERSION = ${PROJECT_VERSION} +QT.${module_lower}_private.name = ${module} +QT.${module_lower}_private.module = +QT.${module_lower}_private.libs = $$QT_MODULE_LIB_BASE +QT.${module_lower}_private.includes = $$QT_MODULE_INCLUDE_BASE/${module}/${PROJECT_VERSION} $$QT_MODULE_INCLUDE_BASE/${module}/${PROJECT_VERSION}/${module} +QT.${module_lower}_private.frameworks = +QT.${module_lower}_private.depends = ${module_lower} +QT.${module_lower}_private.uses = +QT.${module_lower}_private.module_config = v2 +QT.${module_lower}_private.enabled_features = ${enabled_private_features} +QT.${module_lower}_private.disabled_features = ${disabled_private_features} " ) + + set("${pri_files_var}" "${pri_files}" PARENT_SCOPE) endfunction() function(qt_generate_global_config_pri_file) @@ -1071,7 +1103,7 @@ function(add_qt_module target) # Process arguments: qt_parse_all_arguments(arg "add_qt_module" - "NO_MODULE_HEADERS;STATIC;DISABLE_TOOLS_EXPORT;EXCEPTIONS" + "NO_MODULE_HEADERS;STATIC;DISABLE_TOOLS_EXPORT;EXCEPTIONS;INTERNAL_MODULE" "CONFIG_MODULE_NAME" "${__default_private_args};${__default_public_args};QMAKE_MODULE_CONFIG" ${ARGN}) @@ -1311,12 +1343,19 @@ set(QT_CMAKE_EXPORT_NAMESPACE ${QT_CMAKE_EXPORT_NAMESPACE})") EXPORT_NAME_PREFIX ${INSTALL_CMAKE_NAMESPACE}${target} CONFIG_INSTALL_DIR "${config_install_dir}") + if (${arg_INTERNAL_MODULE}) + set(arg_INTERNAL_MODULE "INTERNAL_MODULE") + else() + unset(arg_INTERNAL_MODULE) + endif() + qt_path_join(pri_target_path ${PROJECT_BINARY_DIR} mkspecs/modules) - qt_generate_module_pri_file("${target}" "${pri_target_path}" module_pri_file_name + qt_generate_module_pri_file("${target}" "${pri_target_path}" module_pri_files + ${arg_INTERNAL_MODULE} QMAKE_MODULE_CONFIG ${arg_QMAKE_MODULE_CONFIG} ) - qt_install(FILES "${module_pri_file_name}" DESTINATION mkspecs/modules) + qt_install(FILES "${module_pri_files}" DESTINATION mkspecs/modules) ### fixme: cmake is missing a built-in variable for this. We want to apply it only to modules and plugins # that belong to Qt. diff --git a/src/platformsupport/accessibility/CMakeLists.txt b/src/platformsupport/accessibility/CMakeLists.txt index 2a6588764a..3475b62c3e 100644 --- a/src/platformsupport/accessibility/CMakeLists.txt +++ b/src/platformsupport/accessibility/CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(AccessibilitySupport STATIC + INTERNAL_MODULE SOURCES qaccessiblebridgeutils.cpp qaccessiblebridgeutils_p.h DEFINES diff --git a/src/platformsupport/clipboard/CMakeLists.txt b/src/platformsupport/clipboard/CMakeLists.txt index 4a93b240cd..2d7734ebdf 100644 --- a/src/platformsupport/clipboard/CMakeLists.txt +++ b/src/platformsupport/clipboard/CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(ClipboardSupport STATIC + INTERNAL_MODULE SOURCES qmacmime.mm qmacmime_p.h DEFINES diff --git a/src/platformsupport/devicediscovery/CMakeLists.txt b/src/platformsupport/devicediscovery/CMakeLists.txt index a704fc3ba2..a0b5192d74 100644 --- a/src/platformsupport/devicediscovery/CMakeLists.txt +++ b/src/platformsupport/devicediscovery/CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(DeviceDiscoverySupport STATIC + INTERNAL_MODULE SOURCES qdevicediscovery_p.h DEFINES diff --git a/src/platformsupport/edid/CMakeLists.txt b/src/platformsupport/edid/CMakeLists.txt index fd4a53239f..948cb7e091 100644 --- a/src/platformsupport/edid/CMakeLists.txt +++ b/src/platformsupport/edid/CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(EdidSupport STATIC + INTERNAL_MODULE SOURCES qedidparser.cpp qedidparser_p.h DEFINES diff --git a/src/platformsupport/eglconvenience/.prev_CMakeLists.txt b/src/platformsupport/eglconvenience/.prev_CMakeLists.txt index 48648f3900..d286ff76ad 100644 --- a/src/platformsupport/eglconvenience/.prev_CMakeLists.txt +++ b/src/platformsupport/eglconvenience/.prev_CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(EglSupport STATIC + INTERNAL_MODULE SOURCES qeglconvenience.cpp qeglconvenience_p.h qeglstreamconvenience.cpp qeglstreamconvenience_p.h diff --git a/src/platformsupport/eglconvenience/CMakeLists.txt b/src/platformsupport/eglconvenience/CMakeLists.txt index f2db6c746e..a6a6633d03 100644 --- a/src/platformsupport/eglconvenience/CMakeLists.txt +++ b/src/platformsupport/eglconvenience/CMakeLists.txt @@ -6,6 +6,7 @@ qt_find_package(EGL) # special case add_qt_module(EglSupport STATIC + INTERNAL_MODULE SOURCES qeglconvenience.cpp qeglconvenience_p.h qeglstreamconvenience.cpp qeglstreamconvenience_p.h diff --git a/src/platformsupport/eventdispatchers/.prev_CMakeLists.txt b/src/platformsupport/eventdispatchers/.prev_CMakeLists.txt index 3e2215da81..85d9c967e3 100644 --- a/src/platformsupport/eventdispatchers/.prev_CMakeLists.txt +++ b/src/platformsupport/eventdispatchers/.prev_CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(EventDispatcherSupport STATIC + INTERNAL_MODULE DEFINES QT_NO_CAST_FROM_ASCII LIBRARIES diff --git a/src/platformsupport/eventdispatchers/CMakeLists.txt b/src/platformsupport/eventdispatchers/CMakeLists.txt index 9f5b4a0669..5e88450023 100644 --- a/src/platformsupport/eventdispatchers/CMakeLists.txt +++ b/src/platformsupport/eventdispatchers/CMakeLists.txt @@ -8,6 +8,7 @@ qt_find_package(GLIB2) # special case add_qt_module(EventDispatcherSupport STATIC + INTERNAL_MODULE DEFINES QT_NO_CAST_FROM_ASCII LIBRARIES diff --git a/src/platformsupport/fbconvenience/CMakeLists.txt b/src/platformsupport/fbconvenience/CMakeLists.txt index d4b1d469b0..05ee44b967 100644 --- a/src/platformsupport/fbconvenience/CMakeLists.txt +++ b/src/platformsupport/fbconvenience/CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(FbSupport STATIC + INTERNAL_MODULE SOURCES qfbbackingstore.cpp qfbbackingstore_p.h qfbcursor.cpp qfbcursor_p.h diff --git a/src/platformsupport/fontdatabases/.prev_CMakeLists.txt b/src/platformsupport/fontdatabases/.prev_CMakeLists.txt index 7d3e5957cc..66c4b5314b 100644 --- a/src/platformsupport/fontdatabases/.prev_CMakeLists.txt +++ b/src/platformsupport/fontdatabases/.prev_CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(FontDatabaseSupport STATIC + INTERNAL_MODULE DEFINES QT_NO_CAST_FROM_ASCII LIBRARIES diff --git a/src/platformsupport/fontdatabases/CMakeLists.txt b/src/platformsupport/fontdatabases/CMakeLists.txt index e93ec38237..2e42a71cb2 100644 --- a/src/platformsupport/fontdatabases/CMakeLists.txt +++ b/src/platformsupport/fontdatabases/CMakeLists.txt @@ -9,6 +9,7 @@ qt_find_package(Fontconfig) # special case add_qt_module(FontDatabaseSupport STATIC + INTERNAL_MODULE DEFINES QT_NO_CAST_FROM_ASCII LIBRARIES diff --git a/src/platformsupport/glxconvenience/.prev_CMakeLists.txt b/src/platformsupport/glxconvenience/.prev_CMakeLists.txt index 8abf9530d8..5a407885cf 100644 --- a/src/platformsupport/glxconvenience/.prev_CMakeLists.txt +++ b/src/platformsupport/glxconvenience/.prev_CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(GlxSupport STATIC + INTERNAL_MODULE SOURCES qglxconvenience.cpp qglxconvenience_p.h DEFINES diff --git a/src/platformsupport/glxconvenience/CMakeLists.txt b/src/platformsupport/glxconvenience/CMakeLists.txt index a435de85ee..484fabf234 100644 --- a/src/platformsupport/glxconvenience/CMakeLists.txt +++ b/src/platformsupport/glxconvenience/CMakeLists.txt @@ -8,6 +8,7 @@ qt_find_package(X11) # special case add_qt_module(GlxSupport STATIC + INTERNAL_MODULE SOURCES qglxconvenience.cpp qglxconvenience_p.h DEFINES diff --git a/src/platformsupport/graphics/CMakeLists.txt b/src/platformsupport/graphics/CMakeLists.txt index f6a429fa3a..4dd6db7ebd 100644 --- a/src/platformsupport/graphics/CMakeLists.txt +++ b/src/platformsupport/graphics/CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(GraphicsSupport STATIC + INTERNAL_MODULE SOURCES qrasterbackingstore.cpp qrasterbackingstore_p.h DEFINES diff --git a/src/platformsupport/input/.prev_CMakeLists.txt b/src/platformsupport/input/.prev_CMakeLists.txt index df330e7c8a..902e61f4a5 100644 --- a/src/platformsupport/input/.prev_CMakeLists.txt +++ b/src/platformsupport/input/.prev_CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(InputSupport STATIC + INTERNAL_MODULE DEFINES QT_NO_CAST_FROM_ASCII LIBRARIES diff --git a/src/platformsupport/input/CMakeLists.txt b/src/platformsupport/input/CMakeLists.txt index 5ecbbbbe30..f3d1b66a95 100644 --- a/src/platformsupport/input/CMakeLists.txt +++ b/src/platformsupport/input/CMakeLists.txt @@ -11,6 +11,7 @@ qt_find_package(Mtdev) # special case add_qt_module(InputSupport STATIC + INTERNAL_MODULE DEFINES QT_NO_CAST_FROM_ASCII LIBRARIES diff --git a/src/platformsupport/input/xkbcommon/CMakeLists.txt b/src/platformsupport/input/xkbcommon/CMakeLists.txt index 5f4eca9fc8..1a96d5eafe 100644 --- a/src/platformsupport/input/xkbcommon/CMakeLists.txt +++ b/src/platformsupport/input/xkbcommon/CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(XkbCommonSupport STATIC + INTERNAL_MODULE SOURCES qxkbcommon.cpp qxkbcommon_p.h qxkbcommon_3rdparty.cpp diff --git a/src/platformsupport/kmsconvenience/.prev_CMakeLists.txt b/src/platformsupport/kmsconvenience/.prev_CMakeLists.txt index a6e206d5cd..ec29be7f4e 100644 --- a/src/platformsupport/kmsconvenience/.prev_CMakeLists.txt +++ b/src/platformsupport/kmsconvenience/.prev_CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(KmsSupport STATIC + INTERNAL_MODULE SOURCES qkmsdevice.cpp qkmsdevice_p.h DEFINES diff --git a/src/platformsupport/kmsconvenience/CMakeLists.txt b/src/platformsupport/kmsconvenience/CMakeLists.txt index 3300c2d98d..a2ad5ecc9f 100644 --- a/src/platformsupport/kmsconvenience/CMakeLists.txt +++ b/src/platformsupport/kmsconvenience/CMakeLists.txt @@ -8,6 +8,7 @@ qt_find_package(Libdrm) # special case add_qt_module(KmsSupport STATIC + INTERNAL_MODULE SOURCES qkmsdevice.cpp qkmsdevice_p.h DEFINES diff --git a/src/platformsupport/linuxaccessibility/.prev_CMakeLists.txt b/src/platformsupport/linuxaccessibility/.prev_CMakeLists.txt index f18b0597ce..a5ad155a7a 100644 --- a/src/platformsupport/linuxaccessibility/.prev_CMakeLists.txt +++ b/src/platformsupport/linuxaccessibility/.prev_CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(LinuxAccessibilitySupport STATIC + INTERNAL_MODULE SOURCES application.cpp application_p.h atspiadaptor.cpp atspiadaptor_p.h diff --git a/src/platformsupport/linuxaccessibility/CMakeLists.txt b/src/platformsupport/linuxaccessibility/CMakeLists.txt index 41c86236d2..af48f9d57d 100644 --- a/src/platformsupport/linuxaccessibility/CMakeLists.txt +++ b/src/platformsupport/linuxaccessibility/CMakeLists.txt @@ -8,6 +8,7 @@ qt_find_package(ATSPI2) # special case add_qt_module(LinuxAccessibilitySupport STATIC + INTERNAL_MODULE SOURCES application.cpp application_p.h atspiadaptor.cpp atspiadaptor_p.h diff --git a/src/platformsupport/platformcompositor/CMakeLists.txt b/src/platformsupport/platformcompositor/CMakeLists.txt index 1cb4752ead..c37ba600b3 100644 --- a/src/platformsupport/platformcompositor/CMakeLists.txt +++ b/src/platformsupport/platformcompositor/CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(PlatformCompositorSupport STATIC + INTERNAL_MODULE SOURCES qopenglcompositor.cpp qopenglcompositor_p.h qopenglcompositorbackingstore.cpp qopenglcompositorbackingstore_p.h diff --git a/src/platformsupport/services/CMakeLists.txt b/src/platformsupport/services/CMakeLists.txt index 23e1d5e4cd..b926030e12 100644 --- a/src/platformsupport/services/CMakeLists.txt +++ b/src/platformsupport/services/CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(ServiceSupport STATIC + INTERNAL_MODULE SOURCES genericunix/qgenericunixservices.cpp genericunix/qgenericunixservices_p.h DEFINES diff --git a/src/platformsupport/themes/CMakeLists.txt b/src/platformsupport/themes/CMakeLists.txt index 9dca636b92..d5bb3e1279 100644 --- a/src/platformsupport/themes/CMakeLists.txt +++ b/src/platformsupport/themes/CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(ThemeSupport STATIC + INTERNAL_MODULE SOURCES qabstractfileiconengine.cpp qabstractfileiconengine_p.h DEFINES diff --git a/src/platformsupport/vkconvenience/.prev_CMakeLists.txt b/src/platformsupport/vkconvenience/.prev_CMakeLists.txt index 92f672b8f3..e48ce7f9ad 100644 --- a/src/platformsupport/vkconvenience/.prev_CMakeLists.txt +++ b/src/platformsupport/vkconvenience/.prev_CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(VulkanSupport STATIC + INTERNAL_MODULE SOURCES qbasicvulkanplatforminstance.cpp qbasicvulkanplatforminstance_p.h qvkconvenience.cpp qvkconvenience_p.h diff --git a/src/platformsupport/vkconvenience/CMakeLists.txt b/src/platformsupport/vkconvenience/CMakeLists.txt index cc97c4041b..325da3f8f8 100644 --- a/src/platformsupport/vkconvenience/CMakeLists.txt +++ b/src/platformsupport/vkconvenience/CMakeLists.txt @@ -8,6 +8,7 @@ qt_find_package(Vulkan) # special case add_qt_module(VulkanSupport STATIC + INTERNAL_MODULE SOURCES qbasicvulkanplatforminstance.cpp qbasicvulkanplatforminstance_p.h qvkconvenience.cpp qvkconvenience_p.h diff --git a/src/platformsupport/windowsuiautomation/CMakeLists.txt b/src/platformsupport/windowsuiautomation/CMakeLists.txt index e4e0eed64a..1f0b545c83 100644 --- a/src/platformsupport/windowsuiautomation/CMakeLists.txt +++ b/src/platformsupport/windowsuiautomation/CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_module(WindowsUIAutomationSupport STATIC + INTERNAL_MODULE SOURCES qwindowsuiawrapper.cpp qwindowsuiawrapper_p.h uiaattributeids_p.h diff --git a/src/plugins/platforms/eglfs/.prev_CMakeLists.txt b/src/plugins/platforms/eglfs/.prev_CMakeLists.txt index 4af52dd0fe..e747e1d3c1 100644 --- a/src/plugins/platforms/eglfs/.prev_CMakeLists.txt +++ b/src/plugins/platforms/eglfs/.prev_CMakeLists.txt @@ -5,6 +5,7 @@ ##################################################################### add_qt_module(EglFSDeviceIntegration + INTERNAL_MODULE SOURCES api/qeglfsdeviceintegration.cpp api/qeglfsdeviceintegration_p.h api/qeglfsglobal_p.h diff --git a/src/plugins/platforms/eglfs/CMakeLists.txt b/src/plugins/platforms/eglfs/CMakeLists.txt index 47b5f3cf64..d7ca11acb6 100644 --- a/src/plugins/platforms/eglfs/CMakeLists.txt +++ b/src/plugins/platforms/eglfs/CMakeLists.txt @@ -6,6 +6,7 @@ qt_find_package(EGL) # special case ##################################################################### add_qt_module(EglFSDeviceIntegration + INTERNAL_MODULE SOURCES api/qeglfsdeviceintegration.cpp api/qeglfsdeviceintegration_p.h api/qeglfsglobal_p.h diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/CMakeLists.txt b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/CMakeLists.txt index fd7ba3cefb..be26d40f4d 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/CMakeLists.txt +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/CMakeLists.txt @@ -5,6 +5,7 @@ ##################################################################### add_qt_module(EglFsKmsSupport + INTERNAL_MODULE NO_MODULE_HEADERS SOURCES qeglfskmsdevice.cpp qeglfskmsdevice.h diff --git a/src/plugins/platforms/xcb/.prev_CMakeLists.txt b/src/plugins/platforms/xcb/.prev_CMakeLists.txt index c3d469f0c6..d7ce4e4489 100644 --- a/src/plugins/platforms/xcb/.prev_CMakeLists.txt +++ b/src/plugins/platforms/xcb/.prev_CMakeLists.txt @@ -5,6 +5,7 @@ ##################################################################### add_qt_module(XcbQpa + INTERNAL_MODULE NO_MODULE_HEADERS SOURCES gl_integrations/qxcbglintegration.cpp gl_integrations/qxcbglintegration.h diff --git a/src/plugins/platforms/xcb/CMakeLists.txt b/src/plugins/platforms/xcb/CMakeLists.txt index aa2c0732f2..6849c75e2e 100644 --- a/src/plugins/platforms/xcb/CMakeLists.txt +++ b/src/plugins/platforms/xcb/CMakeLists.txt @@ -27,6 +27,7 @@ qt_find_package(XKB_COMMON_X11 PROVIDED_TARGETS PkgConfig::XKB_COMMON_X11) ##################################################################### add_qt_module(XcbQpa + INTERNAL_MODULE NO_MODULE_HEADERS SOURCES gl_integrations/qxcbglintegration.cpp gl_integrations/qxcbglintegration.h diff --git a/util/cmake/pro2cmake.py b/util/cmake/pro2cmake.py index bd26e5782a..bfd791a196 100755 --- a/util/cmake/pro2cmake.py +++ b/util/cmake/pro2cmake.py @@ -1605,6 +1605,8 @@ def write_module(cm_fh: typing.IO[str], scope: Scope, *, extra = [] if 'static' in scope.get('CONFIG'): extra.append('STATIC') + if 'internal_module' in scope.get('CONFIG'): + extra.append('INTERNAL_MODULE') if 'no_module_headers' in scope.get('CONFIG'): extra.append('NO_MODULE_HEADERS') -- cgit v1.2.3