CMake 命令參考

Qt6::Core

qt_add_big_resources

將大型二進製資源編譯成對象代碼

qt_add_binary_resources

從 Qt 資源文件列錶創建 RCC 文件

qt_add_executable

創建並定稿特定平颱類型的應用程序目標

qt_add_library

創建並定稿庫

qt_add_plugin

創建 Qt 插件目標

qt_add_resources

將二進製資源編譯成源代碼

qt_allow_non_utf8_sources

防止強製將源文件視為 UTF-8 for Windows

qt_android_add_apk_target

定義運行 androiddeployqt 以産生 APK 的構建目標

qt_android_apply_arch_suffix

配置目標二進製名稱以包括特定體係結構後綴

qt_android_generate_deployment_settings

生成 androiddeployqt 所需的部署設置文件

qt_deploy_qt_conf

Write a qt.conf file at deployment time

qt_deploy_runtime_dependencies

Deploy Qt plugins, Qt and non-Qt libraries needed by an executable

qt_deploy_translations

Deploy Qt translations needed by an executable

qt_disable_unicode_defines

Prevents some unicode-related compiler definitions being set automatically on a target

qt_extract_metatypes

Extracts metatypes from a Qt target and generates an associated metatypes.json file

qt_finalize_project

Handles various common platform-specific tasks associated with a Qt project

qt_finalize_target

處理 Qt 目標關聯的各種常見特定平颱任務

qt_generate_deploy_app_script

Generate a deployment script for an application

qt_generate_deploy_script

Generate a custom deployment script

qt_generate_moc

當輸入文件時調用 moc

qt_import_plugins

Specifies a custom set of plugins to import or exclude

qt_policy

修 Qt CMake API 的默認行為

qt_set_finalizer_mode

Customizes aspects of a target's finalization

qt_standard_project_setup

Setup project-wide defaults to a standard arrangement

qt_wrap_cpp

從源創建 .moc 文件

Qt6::DBus

qt_add_dbus_adaptor

為 D-Bus 接口生成適配器類

qt_add_dbus_interface

生成實現 D-Bus 接口描述文件接口的 C++ 源

qt_add_dbus_interfaces

生成實現 D-Bus 接口描述文件接口的 C++ 源

qt_generate_dbus_interface

從頭文件生成 D-Bus 接口

Qt6::Grpc

qt_add_grpc

Generates Qt-based C++ services using a protobuf schema

Qt6::InterfaceFramework

qt_ifcodegen_add_plugin

Adds a plugin target which is generated by ifcodegen using a qface IDL file

qt_ifcodegen_add_qml_module

Adds a QML module which is generated by ifcodegen using a qface IDL file

qt_ifcodegen_extend_target

Extends a target with files generated from a qface IDL file

qt_ifcodegen_generate

Generates files from a qface IDL file

qt_ifcodegen_import_variables

Generates files from a qface IDL file and provides variables for use within CMake

qt_set_ifcodegen_variable

Sets the variable to the given value within an ifcodegen template

Qt6::LinguistTools

qt_add_lrelease

Add targets to transform Qt Linguist .ts files into .qm files

qt_add_lupdate

Add targets to generate or update Qt Linguist .ts files

qt_add_translation

將 Qt Linguist .ts 文件編譯成 .qm 文件

qt_add_translations

Add targets to update and transform Qt Linguist .ts files into .qm files

qt_collect_translation_source_targets

Collects targets that are eligible for translation

qt_create_translation

設置 Qt Linguist 翻譯工具鏈

Qt6::Multimedia

qt_add_ios_ffmpeg_libraries

Auxiliary function which embeds FFmpeg binaries in iOS app bundle

Qt6::Protobuf

qt_add_protobuf

Generates Qt-based C++ source code using a protobuf schema

Qt6::Qml

qt_add_qml_module

Defines a QML module

qt_add_qml_plugin

Defines a plugin associated with a QML module

qt_deploy_qml_imports

Deploy the runtime components of QML modules needed by an executable

qt_generate_deploy_qml_app_script

Generate a deployment script for a QML application

qt_generate_foreign_qml_types

Registers types from one target in a QML module

qt_import_qml_plugins

Ensures QML plugins needed by a target are imported for static builds

qt_query_qml_module

Retrieve information about a QML module

qt_target_compile_qml_to_cpp

qt_target_qml_sources

Add qml files and resources to an existing QML module target

Qt6::RemoteObjects

qt_add_repc_merged

Creates C++ header files for source and replica types from the Qt Remote Objects .rep files

qt_add_repc_replicas

Creates C++ header files for replica types from the Qt Remote Objects .rep files

qt_add_repc_sources

Creates C++ header files for source types from the Qt Remote Objects .rep files

qt_reps_from_headers

Creates .rep files from the QObject header files

Qt6::Scxml

qt_add_statecharts

Qt6::ShaderTools

Qt Shader Tools 構建係統集成

Compiles shaders and adds them to a Qt resource

Qt6::WaylandClient

qt_generate_wayland_protocol_client_sources

Generates client-side C++ bindings for a Wayland protocol .XML file

Qt6::WaylandCompositor

qt_generate_wayland_protocol_server_sources

Generates server-side C++ bindings for a Wayland protocol .XML file

Qt6::WebEngineCore

qt_add_webengine_dictionary

Converts the hunspell dictionary format into bdict binary format

Qt6::Widgets

qt_add_ui

把 .ui 文件添加到目標

qt_wrap_ui

創建 .ui 文件的源