[Qt-creator] Defining project dependencies?
Oliver.Knoll at comit.ch
Oliver.Knoll at comit.ch
Mon Nov 3 14:49:01 CET 2008
Hi there,
with great interest I tried the Qt Creator Technical Preview!
One of the first things I have tried was to setup a Project with several sub-projects, typically the main application ("Qt 4 Gui Application") which depends on several "C++ Libraries".
So first I created ("New") a Qt 4 Gui Application and then another "C++ Library" Project, but I did not find out how to set a dependency from the application to the DLL.
In the library creation wizard one of the last screens offers:
Add to Project [ ]
Project [MainApp.pro]
Add to version control [ ]
But all these 3 options are greyed out. So I assume this is "work in progress"?
Once the Shared Library has been added besides the other Project I also don't see any way how I would specify the dependency afterwards. In Visual Studio for example I would right-click on the DLL project and choose "Project Dependencies...". In Qt Creator I don't see any such option, not even greyed out or so...
So my question would be: is it planned to specify Project dependencies (in the Creator GUI), such that the build order is accordingly and the linker has the correct link settings (so that MainApp.exe links with Utils.dll etc.)? Or am I supposed to hack the *.pro files manually?
As a side-note: what is the "philosophy" of Qt Creator? Am I supposed to edit the *.pro files? Or are they "Don't touch! Your changes will be lost the next time Qt Creator thinks it is appropriate"? For example I did not find a project "Properties" dialog where I could set the *.exe/*.dll output directory, additional Qt dependencies (QtXml, QtOpenGL etc.), additional INCLUDE/LIB directories etc. and yes, I am thinking "Visual Studio Project Properties" dialog here ;) Is this the direction of the Qt Creator ("edit all the possible QMake options in the Creator GUI"), or is it more "Edit the *.pro files yourself" approach (which would be also fine for now)?
And going a bit back again to my Project dependencies problem: can I specify the "output directory", so all *.DLLs and *.exe go into one single output directory (so that the DLLs are found when I start debugging)? Or even more flexible: a desired feature would be "custom build steps", so that I could specify where to copy the resulting binary files, together with additional 3rd party DLL dependencies etc. (in Visual Studio: "Post build step") and then off course: specify which *.exe to debug (namely the one which has been just copied to my final output directory).
As of now I will try to "port" my existing Visual Studio project (with "Custom Build Steps" and DLL Project dependencies) to Qt Creator, but it seems there is still a lot of "manual *.pro file hacking" involved.
Great work!
Oliver
More information about the Qt-creator-old
mailing list