qt_add_win_app_sdk

Windows App SDK ライブラリをアプリケーションに追加します。

このコマンドは Qt 6.9 で導入されました。

注意: このコマンドはテクノロジープレビューであり、将来のリリースで変更される可能性があります。

概要

qt_add_win_app_sdk(target)

バージョンレスコマンドが無効になっている場合は、代わりにqt6_add_win_app_sdk() を使用してください。このコマンドと同じ引数セットをサポートしています。

説明

Windows App SDK インクルードファイルをプロジェクトに追加し、必要なライブラリを指定された CMake ターゲットにリンクします。Windows App SDKはNuGetパッケージとして提供されるので、マネージドアプリで簡単に使用できます。しかし、アンマネージドC++アプリケーションではヘッダーファイルが必要です。この関数は以下のステップを踏みます:

  1. Windows App SDKとcppwinrt.exeツールの検索を試みます。
  2. cppwinrt.exeツールを使用してWindows App SDKヘッダーを生成します。
  3. これらのヘッダーファイルをインクルードし、ライブラリを指定されたCMakeターゲットにリンクします。

警告 このコマンドは、MSVC以外のプラットフォームではサポートされていません。

© 2025 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.