Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
cmake-policies.qdoc
Go to the documentation of this file.
1// Copyright (C) 2026 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
3
4/*!
5\page cmake-policies-qml.html
6\title CMake Policies for QML
7\brief Overview of CMake policies affecting QML module behavior
8
9Qt Qml provides several CMake policies to control backward compatibility and behavior
10of QML-related CMake commands.
11
12\section1 Available Policies
13
14\list
15\li \l{QTP0001} - Controls QML module versioning behavior
16\li \l{QTP0004} - Controls QML module output directory structure
17\li \l{QTP0005} - Controls QML type registration behavior
18\endlist
19
20\section1 Setting Policies
21
22Use \c{qt_policy()} or \c{cmake_policy()} to set these policies in your CMakeLists.txt:
23
24\code
25qt_policy(SET QTP0001 NEW)
26\endcode
27
28\sa {CMake Integration for QML}, {qt_add_qml_module}
29*/