Results 1 to 4 of 4

Thread: compiling errors when using opengl and debug

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Feb 2007
    Posts
    61
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    12
    Thanked 2 Times in 2 Posts

    Default compiling errors when using opengl and debug

    Hi

    I am trying to get myself som debugging information from the application I am creating and in the project file I added:

    Qt Code:
    1. QT += opengl debug
    2. CONFIG += console
    To copy to clipboard, switch view to plain text mode 

    and then used qDebug() at the appropriate places within my code. However when I "make" the program I get the following error:

    g++ -enable-stdcall-fixup -Wl,-enable-auto-import -Wl,-enable-runtime-pseudo-rel
    oc -Wl,-s -Wl,-subsystem,console -mthreads -Wl -o release\gl.exe release/GLWidge
    t.o release/GLWindow.o release/main.o release/moc_GLWidget.o -L"c:\Qt\4.3.4\lib
    " -lopengl32 -lglu32 -lgdi32 -luser32 -lQtOpenGL4 -lQtGui4 -lQtCore4
    /mingw/lib/libmingw32.a(main.o)(.text+0x106):main.c: undefined reference to `Win
    Main@16'
    collect2: ld returned 1 exit status
    mingw32-make[1]: *** [release\gl.exe] Error 1
    If I instead try to compile with "make debug" I get the following error:

    g++ -enable-stdcall-fixup -Wl,-enable-auto-import -Wl,-enable-runtime-pseudo-rel
    oc -Wl,-subsystem,console -mthreads -Wl -o debug\gl.exe debug/GLWidget.o debug/G
    LWindow.o debug/main.o debug/moc_GLWidget.o -L"c:\Qt\4.3.4\lib" -lopengl32 -lgl
    u32 -lgdi32 -luser32 -lQtOpenGLd4 -lQtGuid4 -lQtCored4
    C:\MinGW\bin\..\lib\gcc\mingw32\3.4.2\..\..\..\..\ mingw32\bin\ld.exe: cannot fin
    d -lQtOpenGLd4
    collect2: ld returned 1 exit status
    mingw32-make[1]: *** [debug\gl.exe] Error 1
    This is getting waaaay confusing for me. I have no idea what either of these means. All I am trying to do is to get some easy access to information from my app while I write it, but QT isn't making it easy for me unfortunately...

    Any help?
    Last edited by jpn; 30th March 2008 at 11:01. Reason: missing tags

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.