Qt for iOS - ソースからのビルド
ソースからQt for iOS をビルドするには、Xcodeに Command Line Tools をインストールする必要があります。ターミナルからxcode-select –install
を使って Xcode Command Line Tools を直接インストールするか、Homebrew を使ってパッケージとしてインストールすることができます。Qt のソースは、リポジトリをクローンするか、ソースパッケージをダウンロードすることで入手できます。
その後、Qt の設定とビルドを行います。これはQtのトップディレクトリから行います:
> ./configure -platform macx-ios-clang -release -qt-host-path <path_to_host_qt_installation>
注意: ninja
の実行ファイルがある場合、configure は常にNinjaジェネレーターとビルドツールを使用します。Ninjaは、クロスプラットフォームで、機能が豊富で、パフォーマンスが高く、すべてのプラットフォームで推奨されています。他のジェネレータを使用しても動作するかもしれませんが、公式にはサポートされていません。
その他の configure オプションについてはQt Configure Options を参照してください。
その後、cmake --build . --parallel
を実行してください。
注意: デフォルトのビルドには、シミュレータとデバイスの両方のライブラリが含まれます。単一のターゲット用にビルドしたい場合は、iphoneos
かiphonesimulator
のどちらかと一緒に-sdk
を指定してください。
© 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.