I have cloned the following GitHub project to my hard drive.
https://github.com/leozide/leocad
I have also installed Qt Creator 4.5.0. However, when I try to load the project in Qt Creator, it says there are no valid "kits", and will not let me configure the project. (Presumably, this is a necessary step before I can build the project.)
What do I need to do to get this to work? Thanks.
Windows 10 Home, Qt Creator 4.5.0
Qt is a cross platform framework, thus supporting a bunch of c++ compilers like MinGW GCC, Clang ...etc. a Kit is a set of Qt packages designed for a specific C++ compiler and implements the Qt libraries for that compiler, this is what you need to compile your project in Qt creator .. and they are not part of Qt Creator itself, they must be downloaded. below steps are suitable to get Qt fully functioning.
The Qt open source.
There are two ways to get Qt, the first is to download the source code packages/files and build Qt yourself (but this would be needed if you have a reason to build qt packages from sources yourself). this not covered here.
Steps to install and Configure prebuild Qt Open Source.
Download Qt Online Installer for Windows, usually from this location Qt Online Installer for Windows, this is an online installer for Qt.
Run the downloaded installer, it will guide you through few steps like creating an Qt account and logging in ...
You will end up to the component selection screen and this is the most part.
Expand the Qt Selector tree, you will get 2 groups, A list of available prebuild Qt versions, And to the bottom a Tools selector tree.
make your selection of which Qt version you wish to be downloaded and installed.
Then expand the tree for that version and Choose the components of your interest, these are package kits for a list of compilers .. (For example: a windows user might choose "MinGw x.x.x 32" suite for development under windows .. and "Android" component to develop Android Apps on Qt Creator.
Go down to the Tools tree, expand and select which components to download and install. For Windows usually you need : Qt Creator Debugger, MinGW x.x.x (same as above) and Qt installer framework (which is a maintenance tool for Qt upgrades ...etc).
If you have selected MinGw kit in Qt Version , then you must download the corresponding MingW framework, from Tools branch, unless you have it.
After all selections are made press Next and complete the installation.
Note: with a clean installation of Qt, it configures itself automatically and no further configurations are needed -> Kits are automatically configured based on your installed components.
Related
I develop applications with Netbeans on my Windows PC for the Raspberry Pi and build them remotely on the Raspberry Pi. Now I also would like to develop some GUIs with Qt. Because of remote building I need neither MinGW nor Qt modules (RPi of course has everything necessary installed), only Qt Designer to edit the Qt Forms.
How can I install Qt Designer only or at least with as little additional stuff as possible?
The easiest way would be to download a Qt binary, unzip it, then remove the parts used for compiling user code - i.e. leave only the bin, plugins, resources and translation folders. You can further pare down what's in the bin and translation folders.
The Qt standalone installer binary built with Qt installer framework which accepts scripts also, you can write scripts and customize which you want to install with those scripts, look here https://stackoverflow.com/a/21279733/4490542 and
https://stackoverflow.com/a/34032216/4490542
For anyone else ending up here. Here is a standalone installer someone made:
https://build-system.fman.io/qt-designer-download
This is similar to my question about Step into Qt Sources from Qt Creator on Windows (NOT built from source), but I can't make it work for Linux.
Instead of building from source, I have downloaded the Qt SDK installer, and I've installed Qt to /opt/Qt, and I have the sources at /opt/Qt/5.4/Src.
I cannot step into Qt Sources, so I tried adding a Source Mapping using "Add Qt Sources":
I have tried mapping /var/tmp/qt-src to /opt/Qt/5.4/Src, /opt/Qt/5.4/Src/qtbase, and /opt/Qt/5.4/Src/qtbase/src, none of which worked.
What am I doing wrong? Is the source mapping not /var/tmp/qt-src, or is the target mapping wrong? Does "Add Qt Sources" work at all for the Qt SDK?
I saw a suggestion in a forum thread that it's because the Qt SDK for Linux ships only stripped binaries, while it ships both debug and release DLLs for Windows (which would explain why it worked for Windows, but not for Linux).
I have installed (and reinstalled) the QtSDK Community version on Windows 7 64-bit. When I launch Qt Creator there is no option for C++ Project. Others have solved this problem by making sure qmake.exe is properly detected under Tools-->Options-->Build & Run-->Qt Versions but it appears to be in my installation:
First go to File->New and check the drop-down box in the top right: Is it set to show the relevant templates ("All templates" is the save bet).
If it does: Please check the Kits tab in Tools>Options>Build & Run: Is there a kit using the desktop device type with a compiler and Qt version? Do compiler and Qt version match (same type and version)?
With the Qt in the screenshot you need to have MSVC 2013 set up and detected. MSVC 2010 or any other version does not work, nor does mingw since the binaries that result from building with one compiler and linking to a Qt built with a different compiler does tend to crash more or less randomly.
Once you have a Kit with a Qt version the additional wizards should become available.
I'm asking for a good re-confirmation! (don't take it otherwise).. As I'm quite new in the Qt platform, I've found it quite confusing!! In Windows platform, you've: Qt 5.4.1 for Windows 32-bit (VS 2012, OpenGL) which is a whooping 644 MB file! & also the info about "Qt Creator" in download says:
Blockquote Qt Creator 3.3.1 is included in the Qt 5.4.1 binary packages. If you need a standalone installer, please select the file according to your operating system from the list below to get the latest Qt Creator for your computer
--- this a layman would understand as Qt Creator is the GUI of Qt IDE
&
also you need to download "Qt 5.4.1 for Windows" which is a whooping 644MB !!
so, WAIT FOR A MOMENT...
Blockquote is this the case? or I've to download just the Qt Creator for my work?
Marco's comment explains it all. I don't know why you're bothered with the size of the package. What i want to add is, you can download Qt alone if you'd like to use a different IDE eg. CodeBlocks and set it up for Qt development but it's advisable to use Qt creator with Qt. Qt creator can't build and debug any code (except perhaps, you want to use it for other reasons) without Qt because Qt contains the necessary tools for that purpose.
So download Qt Creator alone if you already have Qt or want to update your old Qt creator and download Qt 5.4.1 for Windows if you want to do development on windows and already have Qt creator installed or any other IDE that can be setup for Qt development.
I want to ask your opinion about one specific aspect of endless "Qt vs wxWidgets" question. Using wxWidgets in Windows, I may continue to work with my prefered build tools and compilers (in my case, Visual Studio). I only need to add wxWidgets include and lib directories to the compiler/linker path. When necessary, I just open some wxWidgets form designer (like DialogBlocks) and make form layout. Executables don't have any additional dependencies and don't cause any problems in redistribution.
On the other hand, Qt comes with its own IDE which tends to be the main development tool (which I don't want). It installs MinGW. It uses qmake, this is one more challenge in integrating Qt to existing build environment. I don't know how to use my existing libraries, developed with VC++, in Qt application. Can I continue to work with Visual Studio or I need to switch completely to Qt Creator? Or use both, building everything but UI in Visual Studio, and UI in Qt Creator? How Qt-based application can be redistributed: should I require MinGW installation on target computer?
How all these problems are solved - I need some directions and opinions from C++ developers working with Qt in Windows.
Edit: It looks like most promising directions are Visual Studio plugin and CMake. I found that Qt plugin supports VS2010, but it requires rebuilding Qt from the source. For VS2008 this plugin works with binary Qt installation - good enough.
You don't have to use the whole Qt SDK, you can only install the libraries for VS (or build from source, if you prefer. The pre-built libraries are for VS2008 but there is a makespec for VS2010 so you can build one yourself, if necessary) and use the Visual Studio integration.
You can use Visual Studio. There is a Visual Studio integration plugin that makes it a lot lot easier to develop with Qt in Visual Studio.
As for the wxWidgets vs Qt debate... I use both (on different projects). I have to say that I would rather use Qt - it has fewer bugs IMO and in general there is an easier workaround if you have problems with the framework (Qt4 is much better in this regard than Qt3 was because the 'pimpl' data is accessible). However, distribution is slightly more complicated with Qt as you must make sure that you have set included any plugins correctly in your distro (be sure to check that it works on a clean machine that does not have Qt installed).
You can download the Qt "source-only", take a look here for the latest version. You can build this library youself using the provided configure tool and MS' nmake...
For example, my typical build looks like this:
configure -shared -release -opensource -no-webkit -nomake demos -nomake examples
nmake
This will build release-mode Qt dlls, assumes you want to use the LGPL-license (with the -opensource flag), no webkit and upon calling nmake it will not build the demos and examples... Of course, you will have to take a look at all the possible options provided by configure
You don't have to use Qt Creator, many people use other IDEs or simple text editors.
qmake is not difficult to use, from a template config you can easily modify a project file by hand. In fact qmake will generate a basic project file for you to get started with.
Use existing libraries as you would in any other project.
You don't need to require a mingw install, you can include essential DLLs in your application directory; but this is the same problem as any other "DLL hell" problem.
If you use cmake as a build system, you can use that to generate project files for visual studio (and eclipse, and ordinary Makefiles, and ..., on any OS). Just install the cmake GUI and select visual studio [myversion] in the appropriate dropdown menu. The only thing to remember then is that you need to make changes to the structure of your project (e.g. adding files) to the cmake CMakeLists.txt files.
Setting up cmake + Qt is pretty easy, and you only have to figure it out once. Googling around a bit should get this setup running in no time.