6

I am trying to install Qt3d on Qt5. When I install QT5, in the installation folder there is a src folder. In this folder, the qt3d library is present.

If I understand correct, I must build it in order to use the various header files.

But I wanted the latest source. So in order to download the source of qt3d to build with QT5 I click on master on this https://qt.gitorious.org/qt/qt3d then i download the master.tar.gz, i save it in the folder where I want to build the qt3d library.

Then I follow all the steps given on the build qt3d with QT sdk page When I click on build, I get the following error

16:28:14: Running steps for project qt3d...
16:28:14: Starting: "C:\Qt\Qt5.0.1\5.0.1\msvc2010\bin\qmake.exe" C:\libraries\qt3d\qt-qt3d_tdk\qt3d.pro -r -spec win32-msvc2010 "CONFIG+=debug"Reading C:/libraries/qt3d/qt-qt3d_tdk/src/src.pro [C:/libraries/qt3d/Debug/src]
Reading C:/libraries/qt3d/qt-qt3d_tdk/src/threed/threed.pro [C:/libraries/qt3d/Debugsrc/threed]
'perl.exe' is not recognized as an internal or external command,operable program or batch file.
Project MESSAGE: C:\Qt\Qt5.0.1\5.0.1\msvc2010\bin\syncqt.bat -module Qt3D-mkspecsdirC:\Qt\Qt5.0.1\5.0.1\msvc2010/mkspecs -outdir C:/libraries/qt3d/Debug /librariesqt3d/qt-qt3d_tdk
Project ERROR: Failed to run: C:\Qt\Qt5.0.1\5.0.1\msvc2010\bin\syncqt.bat -module Qt3D -mkspecsdir C:\Qt\Qt5.0.1\5.0.1\msvc2010/mkspecs -outdir C:/libraries/qt3d/Debug C:/libraries/qt3d/qt-qt3d_tdk
16:28:15: The process "C:\Qt\Qt5.0.1\5.0.1\msvc2010\bin\qmake.exe" exited with code 3.Error while building/deploying project qt3d (kit: Desktop Qt 5.0.1 MSVC2010 32bit)

When executing step 'qmake'

What i am confused about is, why does the compiler say that perl.exe is not recognised when the file perl.exe is nowhere to be found in neither src.pro nor threed.pro. How does perl come in to the picture.

Also, I am using the master.tar.gz because if i try to use the clone repository using GIT gui, it shows an error message saying that the directory exists. To be very hopnest, I am completely lost with all this GIT stuff.

Any advice will be helpful.

Thanking you in advance.

4

4 に答える 4

2

Git から Qt5 をビルドするの手順にも従ってください。Perl は、Perl スクリプトを介して行われる Qt5 ソース ビルドの構成手順に必要です。

于 2013-03-08T15:51:22.257 に答える
2

QT をソースから再コンパイルせずに Windows 上の QT インストールにアドオンをインストールする方法を探して、一日中インターネットを検索しました。私は私の仕事を手に入れました(とにかくこれまでのところ。私は1つの例をテストしただけで、エラーなしで実行してGUIをロードしました)試してごらん。

要件: QT の最新バージョンを入手してインストールします (私は QT 5.1.1 (Mingw32 ビット) を使用しましたが、これは VSS で動作するはずです) perl をインストールします (私は Activeperl 5.18 64 ビットをインストールしました) git クライアントを入手します (私は MAC でクライアントを使用しました) (XCODE))

== Git cleint を使用して完全な Git クローン リポジトリを取得します。https://qt.gitorious.org/qt/qtlocationからダウンロードしたアーカイブでは、必要なすべてのファイルが含まれているわけではありません == sudo git clone git://gitorious.org/qt/qtlocation.git これは、ダウンロードした GIT Flat ファイルを Windows OS にコピーします (例: C:\qtlocation にコピーします)。

==お使いの Windows OS の場合 === Windows から。Perl パスを QT コマンド ラインに追加します。これを行うには、C:\Qt\Qt5.1.1\5.1.1\mingw48_32\bin\qtenv.bat を編集し、パス C:\Perl64\site\bin;C:\Perl64\bin; に次を追加します。set PATH=C:\Perl64\site\bin;C:\Perl64\bin;C:\Qt\Qt5.1.1\5.1.1\mingw48_32\bin;C:\Qt\Qt5.1.1/Tools/ mingw48_32\bin;%PATH%

(perl は後で mingw32-make.exe で必要になります)。

[スタート] -> [すべてのプログラム] -> -> -> -> [デスクトップ用 Qt 5.1.1 (MinGw バージョン)]に移動してデスクトップ用 Qt 5.1.1 を起動し、QT パスを使用してコマンド プロンプトを起動します。

cd c:\qtlocationなどに qtlocation git ファイルを置いたフォルダーに CD を入れて 実行します。

qmake

この実行の後

mingw32-make.exe

これが完了するまでに数分かかります。その時点で、.dll がコンパイルされます。

===QT に DLL を認識させる=== もっと簡単なプロセスがあると思いますが、ファイルを必要な場所にコピーしました。これを行うには、QT 5.1.1 のインストール中に最初に「アドオン」をインストールしました。(アドオンの例は qtsensor ですが、これを行う必要はありません)。これは、センサー アドオン自体がインストールしたすべてのフォルダーを確認できるようにするためでした。次に、qt mingw フォルダー内のすべてのフォルダーに移動しました。

たとえば、C:\Qt\Qt5.1.1\5.1.1\mingw48_32 およびセンサー プラグインへの参照が表示された場所で、同様のファイルを qtlocation フォルダーからそれにコピーしました。基本的に以下をコピーしました(コマンドプロンプトでこれを行うことができます)

C:\qtlocation\include\QtPositioning C:\Qt\Qt5.1.1\5.1.1\mingw48_32\include コピー C:\qtlocation\examples*.* C:\Qt\Qt5.1.1\5.1.1\mingw48_32\例 copy C:\qtlocation\mkspecs\modules*.* C:\Qt\Qt5.1.1\5.1.1\mingw48_32\mkspecs\modules copy C:\qtlocation\plugins\position C:\Qt\Qt5.1.1\5.1 .1\mingw48_32\plugins コピー C:\qtlocation\lib\cmake\Qt5Positioning C:\Qt\Qt5.1.1\5.1.1\mingw48_32\lib\cmake コピー C:\qtlocation\lib\pkgconfig*.* C:\ Qt\Qt5.1.1\5.1.1\mingw48_32\lib\pkgconfig コピー C:\qtlocation\lib*.a C:\Qt\Qt5.1.1\5.1.1\mingw48_32\lib コピー C:\qtlocation\lib*. prl C:\Qt\Qt5.1.1\5.1.1\mingw48_32\lib コピー C:\qtlocation\lib*.dll C:\Qt\Qt5.1.1\5.1.1\mingw48_32\bin

以上です。上記で行ったすべてのファイルをコピーする必要はなかったと確信していますが、必要なものを見つけるために試行錯誤するのではなく、徹底的に行う必要があると考えました。

この後、Fireup QT. qtlocation に付属の例の 1 つをロードします。

PS VSSを使用してこれを行うには、「mingw32-make.exe」「nmake install」と交換すると思います?? おもう。

上記の手順は、QTのアドオンでも機能するはずです。

于 2013-11-18T21:18:37.153 に答える
1

ダークナイトよりも先に進んだので、これに少し追加したかったのですが、まだ問題があります. ActivePerl をインストールし、perl bin ディレクトリを %PATH% に追加した後、ソースから (QtCreator を使用して) Qt3D リポジトリを構築することができました。今困っているのは「make install」の部分です。ファイルを Qt ディレクトリに手動でコピーし、qmldir ファイルを最初から作成しようとしましたが、QtCreator は Qt3D ライブラリを「認識」しますが、.dll のロードを拒否します。エラーは言う:

C:/Qt/5.1.1/msvc2010/qml/Qt3D/qthreedqmlplugin.dll: The specified module could not be found.

MinGW をインストールして、ビルド ディレクトリから "mingw32-make install" を実行しようとしましたが、失敗しました。そのファイルは間違いなくそこにありますが。これ以上の考えはありますか?または、Qt3D を Windows で動作させるための他の方法はありますか?

編集: MSVC をコンパイラとして使用していたため、Linux の Qt3D インストール手順に従って make install の代わりに、Visual Studio コマンド プロンプトを使用し、nmake install を使用する必要があることがわかりました。今それは動作します!

于 2013-11-07T15:37:22.930 に答える
0

このリンクから次の手順に従いました: http://qt-project.org/forums/viewthread/38263

そのページからの抜粋です

ついに、私は成功しました!というわけで、まずはQtの最新版、Qt 5.2.1をダウンロードし、gitクライアントでgitリポジトリからQt3Dのソースを「C:\qt3d」フォルダにターミナル「Qt 5.2.1 for Desktop (MinGW) 4.8 32 ビット)」 cd C:\qt3D qmake mingw32-make.exe インストール

すべてのファイルが Qt 構成フォルダーにコピーされるように、「インストール」が重要です。次に、.pro ファイルに QT += 3d を追加し、main.qml ファイルに: import QtQuick 2.0 import Qt3D 2.0 import Qt3D.Shapes 2.0

私の悩みの主な理由は、git で利用可能なダウンロード ボタンを使用して Qt3D をダウンロードしたことです。ただし、これにより、ソース ファイルが適切なファイルにコピーされます。そのため、git clone を使用して git client を使用してソース コードをダウンロードするのが最善です。

于 2015-01-10T17:12:55.830 に答える