I've just installed Qt 5.0.2 for Windows 64-bit (VS 2012, 500 MB) (Info) and trying to accomplish the "hello world" tutorial
http://qt-project.org/wiki/Qt_for_beginners_Hello_World
However when I press Run the project doesn't build at all, I mean the folders for build are created which are empty, plus I dont have any error generated.
My configuration is Win64 Pro with VS2012 installed. On Option Window and on Compilers Tab I have MS Visual C++ 11 correctly recognized. On Qt Versions Tab I don't have any errors. On Kits tab I have a worning sign indicating that Debugger is not found (normally it shouldn't break the building process). Can someone assist on this?
thanks
Fortunately I found the answer. It seems QT don't like non-Unicode characters in Project Path.
Once I moved my projects to C:\ everything started to work
well use this ligne in the .pro
` TEMPLATE = app
TARGET = name_of_the_app
QT = core gui widget
`
Related
I create a Qt project,build the project with msvc2017-32bit kit, and debug the project in Qt Creator. The problem is I can not step into the Qt functions. I can stop at break-points in my own source code, but cannot stop at break-points in files in Qt src directory. When I step into a Qt function, a message Stopped: "end-stepping-range" appears by the debugging buttons. Why could this happen?
According to #user13088490's suggestion, I installed the debugger tools for windows in windows 10 SDK, but the problem persists.
Follow the instructions from Qt here.
For Mac, the instructions are:
In Projects->Build&Run->Run->Run Settings->Run, select "Use debug version of frameworks".
There are different instructions for Windows, but I have not tried it yet.
You probably also need to have QT sources installed.
Go to the MaintenanceTool and check if Qt Creator 4.15.2 CDB Debugger Support and Debugging Tools for Windows has been selected.
I run Qt on Windows, although a different compiler than you, and you can set the debug target paths by going to Tools->Options->Debugger. From here you can click a button Add Qt sources.... Below is an image of my setup and this works for me.
Whenever I make a Qt project, the qmake command includes this parameter:
"CONFIG+=qml_debug"
I never use qml and dont want to manually click three times and ignore the warning every time I generate a new project.
It happened to me in a project. I just added this to the .pro file :
CONFIG -= qml_debug
It seems to work.
You can download Microsoft Visual Studio 2017 Community Edition, it's free to use. And it is not only a great IDE but also it has got Qt support. By downloading Qt plug in for Microsoft Visuals Studio you can create Qt projects and build and debug them...
Everything that you do with Qt Creator and it has got no such problem as yours.
Also if you want to stay with Qt creator, check Projects -> Build & Run -> Run Settings. There is Enable QML setting which mine is disabled. Maybe you can disable it from there.
If not I advice you to check Tools -> Options -> Build & Run and Tools -> Options -> Debuggers. If it can be solved within Qt Creator it must be solved from these places.
I've downloaded and installed Qt Creator from its online installer and the latest version but when i try to create a Qt Console Application i get the following error. I haven't touched options. The picture is an error from when i tried to open a file from my professor but i get the same error when i try to create a new one. It could be pretty simple but its the 1st time im using this program as a student and have no idea whats going on. Thanks in regards for your timeenter image description here
If you are using Qt Creator with MSVC Compiler (Visual Studio), you need to also download the Visual Studio Compiler. Qt for MSVC doesn't come with a compiler.
It seems that you are trying to compile with VS 2017. You can Download Visual Studio 2017 from: https://www.visualstudio.com/es/downloads/
Express is free, the other two are paid, but don't download VS Code, it's for another purpose.
Alternatively, you can download only the compiler from: http://landinghub.visualstudio.com/visual-cpp-build-tools It's ligther but you don't get the IDE.
Also, for debugging, if you are on x86 or x64, download Windows CDB from: https://learn.microsoft.com/en-us/windows-hardware/drivers/debugger/debugger-download-tools
After you install this, you can reboot Qt and then it will show it has the appropiate compiler and debugger, like this (note that I use VS 2013):
There is another option if you don't want to download or use Visual Studio. Go to the Qt Maintenance Tool (uninstaller), Add or remove components, then install MinGW binaries of your favorite Qt Version, like this:
MinGW is free and it comes bundled with Qt, so you can build and run (and debug!) right away.
Want to manually install 32-bit versions of Qt 5.7 so that I will be able to deploy my app to not only 32-bit but 64-bit machines as well.
Initially when I installed it on my 64-bit Windows 7 machine, I only selected the 64-bit components and, hence, I can only select the MSVC2015_64 bit kits in Qt Creator to build my app with.
Since I want to deploy my app to a 32-bit Windows 10 machine, I am trying to add the 32-bit Qt versions to my installation; tried through Tools > Options > Build & Run > Add... with no success. Searched for some answer/guide to the documentation and to other online sources but could not find how to achieve this in Windows.
Is it possible to manually add other Qt versions on a current install or is do I have to reinstall Qt? Also, could I simple install Qt with the desired Qt versions on a different directory than the first installation or will that mess up the PATH variables?
You have to launch Qt Maintenance Tool : Start -> Programs -> Qt -> Qt Maintenance Tool.
Skip the Qt login (unless you are using a commercial version of Qt).
Select "Add or remove components" and click yes. You'll be able to select other kits to download and install*.
Then Qt Creator should automatically add those kits, you'll just have to add them to your project : go to project settings once your project is open, and you'll find "Add kit" button in the upper left corner.
*Qt Maintenance Tool may prompt you to update components first if there's a new version available.
Kits are the key to your problem. A kit in Qt is composed of:
Version of Qt (and i'm not talking about Qt creator)
Compiler (you have to choose the correct compiler corresponding to your Qt Version, i will explain that more in detail, below )
Debugger (correct version 32 or 64 bits).
You can install as many versions of Qt as you wish Qt Creator will usually autodetect them all. Don't worry it won't damage your path, you can also install 2 different compilers (MingW and MSVC a.k.a VS compiler for example).
in Qt site : https://www.qt.io/download-open-source/
pick the version or versions of Qt you want to install and install them (the package include Qt Creator so no need to install it twice)
you also download the correct version of your compilers and debbuggers (if you don't already have them) and install them.
Once you've downloaded all the components and installed them, you go to Qt Creator :
Tools -> Options
in the lhs menu select Build & Run
you can go and check Qt Versions, Compiler and debugger to see if everything was auto-detected well.
if it's ok you can then create your kit :
go to the kits Tab
you can either add a new kit, but i prefer cloning an existing one and then edit it.
select the clone and choose the correct compiler, the correct version of Qt and the correct Debugger, rename your kit so you can recognize it. Save and close.
to use the kit you created you have to choose it in the project menu
see the screenshot below :
you can create as many kits as you wish, so you can have different configurations.
QtCreator can handle any number of "kits", where a kit is a combination of compiler + Qt version + (optionally) a deployment target.
See http://doc.qt.io/qtcreator/creator-configuring.html
Qt was messing up on Windows so I deleted it and re installed it with the qt libraries and Qt Creator. Now, whenever I try to open my old project, I get the error that "Qmake is does not exist or is not executable", and none of the Qt headers can be located.
Assuming you're using a recent version of Qt, such as version 4.7.4, and a recent version of Qt Creator, such as the branch 2.3 .*.
Probably somewhere in this process, Qt Creator or the settings for this specific project lost the reference to Qt install.
We first need to find out if Qt Creator knows where Qt is installed. Go to Tools > Options.... Then click in Qt4. Here will show all installed and detected Qt versions.
As you can see, I have one Qt version installed (4.7.4), which was automatically detected.
If you do not have any installed version, you need to indicate a one manually. Simply click Add and point it to the right qmake.exe. Use the paths of the figure as reference. If you are developing a windows/mingw application, just need to add the qmake.exe associated with mingw (c:\qtsdk\desktop\qt\4.7.4\mingw\bin\qmake.exe on my computer) and remember the Version name, we'll need that in next step.
After that, open the project and click on Projects in the lateral bar. You need to Substitute the Qt version. Click on Manage next to it and select the correct version. This should resolve the problem.
Any trouble just comment. Sorry about the creepy english.