Netbeans debugger for QT not stopping at breakpoints - qt

I have Netbeans 8.2, Linux operating system, QT 4.8. I am remotely working on a QT application. I can run the application from Netbeans, but the debugger does not stop at the breakpoints, nor do those breakpoints show up in the window. I know this is not a remote issue, as I can debug a project that is not QT. Any suggestions?

I solved this problem. I put CONFIG += qt debug_and_release_target instead of CONFIG += qt debug in my .pro file, ran qmake again and now the debugger works.

Related

QT Creator QPrintDialog appears on development machine, but not on other machines

I am having trouble deploying an application on machines other than my development machine.
I have a Print button on several menus which works well on the development machine, when running in a Release build in QT Creator. However when I build the project into a .msi file using WiX and distributing it to other computers the Print dialog will not appear. Is this most likely a problem with my WiX file? The version of the .dll file I am using? The .pro file (which includes printersupport in it)? How is it that QT Creator can find and run the code needed for the dialog but other systems cannot?

Qt application not a valid 32bit application

I made a simple Qt application. Everything is working well on mt PC. I use Windows 7 SP1 and Qt Creator for building and debugging. When I try to run my program on Win XP I get the error "Not a valid 32 application". I had the same problem when I was making applications with Visual Studio 2012. However I fixed that problem with Visual Studio. In Tools -> Options I made it wo be compiling for Win XP. And everything was working on my PC and on the PC with XP. But I can't find such option in Qt Creator. How can I run my application on Windows XP?
Qt-Creator is only IDE, it uses compiler you tell it to use (I'm assuming it would be VS2012 in your case).
You can check compiler/linker flags in your other VS2012 solution that make a difference (what changes as you set "option compiling for Win XP" when you look to command line input to compiler/linker), and set same flags in your Qt .pro file.
You can see actual input to compiler/linker by going to project properties->C/C++->Command line and Linker->Commnd line respectively in your VS2012 project.
You can set compiler/linker flags in qt using
QMAKE_CXXFLAGS +=
and
QMAKE_LFLAGS +=
in qt .pro file respectively.

Cannot deploy my Quick 2 app to a Windows system without Qt installed

I am using Qt 5 with Visual Studio compiler. I have a Quick 2 application with a c++ backend.
I have bundled together my exe, a bunch of dll files, and all of the plugins from Qt, into a single folder. When I run the exe in this folder on a system with Qt installed but Qt Creator closed, it runs fine. When I run it on a system without Qt installed, it does not crash, but it just opens a small 1-inch square window that is all white, nothing else.
I am using a Qt resource file for the QML, so there are no standalone QML files that could be getting missed by the exe. Again, it runs fine on a system with Qt, so what else could I be missing? Dependency walker does not report any problems.
Here is what is in my app directory:
I've been looking at this for hours and I cannot understand what I must be missing (or why Windows deployment is so challenging with Qt).
The problem was resolved by also adding these directories:

A qt5 simple app doesn't run in windows 7

I use Qt 5.0.1 and Qt Creator 2.6.2 in W7. I tried to run a simple app from examples which contains only a window ("Widgets tutorial - creating a window"). When I run it in Qt Creator, it works. But when I run it as a standalone app (Release), it doesn't.
I filled the folder with every dll it had asked (26 MB of dlls, while the app is 10KB!!!). Now it doesn't ask for any files, it just doesn't run at all with no explanations.
I tried to add some files as it is advised in Application deployed with QT5 libraries does not start on Windows 7
but no luck. In
HelloWorld Deployment with QtQuick 2.0 in Windows 7 and XP
there are no problems in w7.
May be this a dependency problem, These links describes it:
Qt 5.0 program runs in QtCreator but not outside
How to build QTcore4.dll without dependency to MSVCx80.dll?
platforms/qwindows.dll is a "non-required" required DLL to run Qt5 apps. Build your app in Release mode and steal the DLL from Qt Creator's folder (or find it into Qt's bin/platforms folder)

OpenCV windows in Qt gui application

I have Qt gui application working with OpenCV.
Sometimes it's nice to use OpenCV imshow() to show images during program work (for debug).
I just simply use:
cv::imshow("roi",roiImg);
in Qt application.
In Windows 7 everything works fine. Only when debugging in QtCreator I'm getting segfault when trying to show OpenCV window.
But my problem is that in WindowsXP even when running application exe both compiled as debug and release version program crashes.
Has anyone similiar problem? What is the best solution? What solution do you use as debug image output in applications written in Qt for example?

Resources