このページでは

QML の CMake ポリシー

Qt QML では、QML 関連の CMake コマンドの後方互換性や動作を制御するために、いくつかの CMake ポリシーを提供しています。

利用可能なポリシー

  • QTP0001- QML モジュールのバージョン管理動作を制御します。
  • QTP0004- QML モジュールの出力ディレクトリ構造を制御します。
  • QTP0005- QML タイプ登録の動作を制御する

ポリシーの設定

qt_policy() またはcmake_policy() を使用して、CMakeLists.txt にこれらのポリシーを設定します:

qt_policy(SET QTP0001 NEW)

CMake Integration for QMLおよびqt_add_qml_moduleも参照してください

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.