Unable to link with library in qt creator 2.8.1 with MinGW 4.8



  • Well I just gave qt creator a go and tried to port my project from eclipse CDT...but when I link with libraries compiled with MinGW 4.7.2, build fails with undefined like these :
    "c:/qt/qt5.1.1/tools/mingw48_32/bin/../lib/gcc/i686-w64-mingw32/4.8.0/../../../../i686-w64-mingw32/lib/../lib/crt2.o:crtexe.c:(.text+0x14): undefined reference to _newmode' c:/qt/qt5.1.1/tools/mingw48_32/bin/../lib/gcc/i686-w64-mingw32/4.8.0/../../../../i686-w64-mingw32/lib/../lib/crt2.o:crtexe.c:(.text+0x36): undefined reference to_dowildcard'
    c:/qt/qt5.1.1/tools/mingw48_32/bin/../lib/gcc/i686-w64-mingw32/4.8.0/../../../../i686-w64-mingw32/lib/../lib/crt2.o:crtexe.c:(.text+0x8e): undefined reference to mingw_initcharmax' c:/qt/qt5.1.1/tools/mingw48_32/bin/../lib/gcc/i686-w64-mingw32/4.8.0/../../../../i686-w64-mingw32/lib/../lib/crt2.o:crtexe.c:(.text+0x9e): undefined reference tomingw_app_type'
    c:/qt/qt5.1.1/tools/mingw48_32/bin/../lib/gcc/i686-w64-mingw32/4.8.0/../../../../i686-w64-mingw32/lib/../lib/crt2.o:crtexe.c:(.text+0xba): undefined reference to _encode_pointer' c:/qt/qt5.1.1/tools/mingw48_32/bin/../lib/gcc/i686-w64-mingw32/4.8.0/../../../../i686-w64-mingw32/lib/../lib/crt2.o:crtexe.c:(.text+0xc5): undefined reference to__onexitend'
    c:/qt/qt5.1.1/tools/mingw48_32/bin/../lib/gcc/i686-w64-mingw32/4.8.0/../../../../i686-w64-mingw32/lib/../lib/crt2.o"
    Has anyone encountered these? How did you fix it? Thanks for any answer.


  • Lifetime Qt Champion

    Hi and welcome to devnet,

    AFAIK, mixing libraries build from various MinGW versions will not work (I'll be happy to be proven wrong though)



  • @SGaist Thanks alot for that clarification.


  • Lifetime Qt Champion

    You're welcome

    Just to clarify, I was thinking between minor releases (major also), patch release should be fine.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.