PDA

View Full Version : Error when including QtGui ( undefined reference to `_Unwind_Resume)



Abdu
18th February 2011, 19:56
Hi all

I`m using Qt (4.7.1) and Eclipse integration. I`m writing a Qtcore project and It`s working fine. But whenever I include QtGui by writing : #include <QtGui> and compiling , I get the following error:



C:\\iwmake\\build_mingw_opensource\\src\\winmain/qtmain_win.cpp:93: undefined reference to `_Unwind_Resume'
mingw32-make[1]: Leaving directory `Z:/workspace/Bismellah'
C:\\iwmake\\build_mingw_opensource\\src\\winmain/qtmain_win.cpp:135: undefined reference to `_Unwind_Resume'
c:\Users\alhussab\Downloads\devtools\QT\lib/libqtmaind.a(qtmain_win.o):C:\\iwmake\\build_mingw _opensource\\src\\winmain/../../include/QtCore/../../src/corelib/tools/qvector.h:484: undefined reference to `_Unwind_Resume'
c:\Users\alhussab\Downloads\devtools\QT\lib/libqtmaind.a(qtmain_win.o):C:\\iwmake\\build_mingw _opensource\\src\\winmain/../../include/QtCore/../../src/corelib/tools/qvector.h:485: undefined reference to `_Unwind_Resume'
c:\Users\alhussab\Downloads\devtools\QT\lib/libqtmaind.a(qtmain_win.o):qtmain_win.cpp:(.eh_fra me+0x12): undefined reference to `__gxx_personality_v0'
collect2: ld returned 1 exit status
mingw32-make[1]: *** [debug\Bismellah.exe] Error 1
mingw32-make: *** [debug] Error 2



Without including QtGui, it just works fine. I tried totally a new Qt example that includes both QtCore and QtGui, and I get the same error. I made sure that QtGui exists in the Include path.

For your information, I use MinGW 4.4

Could you please help me with this error ?

Thanks a lot in advance

high_flyer
21st February 2011, 10:02
You have configured your project as a core application (non gui)
So your project is not linking against QtGui.dll.
You have to change the QT field in your pro file to include 'gui'.