| Home · All Namespaces · All Classes · Main Classes · Grouped Classes · Modules · Functions |
Qt アプリケーションを配布するには C++ のプログラミングは必要ありません。行うことは Qt とアプリケーションをこのドキュメントに書いてある手順に従ってリリースモードでビルドするだけです。Qt のサンプルにある Plug & Paint アプリケーションを配布する手順を示します。
アプリケーションの配布には2つの方法があります:
静的リンクは1つのスタンドアローンの実行ファイルを作ります.この方法の良い点は配布するファイルが数個のみとなることです。悪い点は実行ファイルが大きくなり、融通が利かない(アプリケーションか Qt が新しいバージョンになる度に配布するファイルを同じように作り直す必要がある)ことと、プラグインを配布できないことです。
プラグインを使用するアプリケーションを配布するには、共有ライブラリを使用する方法をとることができます。この方法ではサイズが小さく、融通の利く実行ファイルを配布できます。例えば、共有ライブラリを使用すると、ユーザーがこのアプリケーションで使用する Qt ライブラリをアプリケーションに依存せずにアップグレードすることができます。
共有ライブラリを選択するもう一つの理由としては、複数のアプリケーションで同じ共有ライブラリを使用することができるということです。実際、もし Qt のインストールバイナリをダウンロードした場合は、 共有ライブラリ形式の Qt を取得します。
共有ライブラリの悪い点はたくさんのファイルを配布することです。
| Qt's Libraries | |||
|---|---|---|---|
| QtAssistant | QAxContainer | QAxServer | QtCore |
| QtDBus | QtDesigner | QtGui | QtHelp |
| QtNetwork | QtOpenGL | QtScript | QtSql |
| QtSvg | QtWebKit | QtXml | QtXmlPatterns |
| Phonon | Qt3Support | ||
Since Qt is not a system library, it has to be redistributed along with your application; the minimum is to redistribute the run-time of the libraries used by the application. Using static linking, however, the Qt run-time is compiled into the executable.
In particular, you will need to deploy Qt plugins, such as JPEG support or SQL drivers. For more information about plugins, see the How to Create Qt Plugins documentation.
When deploying an application using the shared library approach you must ensure that the Qt libraries will use the correct path to find the Qt plugins, documentation, translation etc. To do this you can use a qt.conf file. For more information, see the Using qt.conf documentation.
Depending on configuration, compiler specific libraries must be redistributed as well. For more information, see the platform specific Application Dependencies sections: X11, Windows, Mac.
Some of Qt's libraries are based on third party libraries that are not licensed using the same dual-license model as Qt. As a result, care must be taken when deploying applications that use these libraries, particularly when the application is statically linked to them.
The following table contains an inexhaustive summary of the issues you should be aware of.
| Qt Library | Dependency | Licensing Issue |
|---|---|---|
| QtHelp | CLucene | The version of clucene distributed with Qt is licensed under the GNU LGPL version 2.1 or later. This has implications for developers of closed source applications. Please see the QtHelp module documentation for more information. |
| QtNetwork | OpenSSL | Some configurations of QtNetwork use OpenSSL at run-time. Deployment of OpenSSL libraries is subject to both licensing and export restrictions. More information can be found in the Secure Sockets Layer (SSL) Classes を参照してください。 |
| QtWebKit | WebKit | WebKit is licensed under the GNU LGPL version 2 or later. This has implications for developers of closed source applications. Please see the QtWebKit module documentation for more information. |
| Phonon | Phonon | Phonon relies on the native multimedia engines on different platforms. Phonon itself is licensed under the GNU LGPL version 2. Please see the Phonon module documentation for more information. |
Qt アプリケーションの配布の手順はそれぞれのプラットフォームで異なります:
また、 Installation と Window System Specific Notesも参照してください。
| Copyright © 2009 Nokia Corporation and/or its subsidiary(-ies) | Trademarks | Qt 4.5.0 |