Results 1 to 18 of 18

Thread: why linking problem with QGLWidget???

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #11
    Join Date
    Dec 2006
    Posts
    103
    Qt products
    Qt4
    Platforms
    Windows
    Thanks
    31

    Default Re: why linking problem with QGLWidget???

    Quote Originally Posted by jpn View Post
    Could you show the full compiler command with all the arguments?
    [root@localhost 2and3D]# qmake -project
    //changed .pro file and added QT += opengl
    [root@localhost 2and3D]# qmake
    [root@localhost 2and3D]# make
    g++ -c -pipe -O2 -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_OPENGL_LIB -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -I/root/qt-x11-opensource-src-4.2.2/mkspecs/linux-g++ -I. \
    -I/usr/local/Trolltech/Qt-4.2.2/include/QtCore -I/usr/local/Trolltech/Qt-4.2.2/include/QtCore -I/usr/local/Trolltech/Qt-4.2.2/include/QtGui \
    -I/usr/local/Trolltech/Qt-4.2.2/include/QtGui -I/usr/local/Trolltech/Qt-4.2.2/include/QtOpenGL -I/usr/local/Trolltech/Qt-4.2.2/include -I. -I/usr/X11R6/include -I. -I. -o form.o form.cpp
    In file included from form.h:5,
    from form.cpp:2:
    glwidget.h:5:30: error: QtOpenGL/QGLWidget: No such file or directory
    glwidget.h:8: error: expected class-name before ‘{’ token
    glwidget.h:36: error: ‘GLuint’ does not name a type
    glwidget.h:37: error: ‘GLdouble’ has not been declared
    glwidget.h:37: error: ‘GLdouble’ has not been declared
    glwidget.h:37: error: ‘GLdouble’ has not been declared
    glwidget.h:37: error: ‘GLdouble’ has not been declared
    glwidget.h:38: error: ‘GLdouble’ has not been declared
    glwidget.h:38: error: ‘GLdouble’ has not been declared
    glwidget.h:38: error: ‘GLdouble’ has not been declared
    glwidget.h:38: error: ‘GLdouble’ has not been declared
    glwidget.h:39: error: ‘GLdouble’ has not been declared
    glwidget.h:39: error: ‘GLdouble’ has not been declared
    glwidget.h:39: error: ‘GLdouble’ has not been declared
    glwidget.h:39: error: ‘GLdouble’ has not been declared
    glwidget.h:42: error: ‘GLuint’ does not name a type
    glwidget.h:8: warning: ‘class GLWidget’ has virtual functions but non-virtual destructor
    form.cpp: In constructor ‘MainWindow::MainWindow(QMainWindow*)â€℠¢:
    form.cpp:41: error: ‘class GLWidget’ has no member named ‘setGeometry’
    make: *** [form.o] Error 1
    [root@localhost 2and3D]#

    [root@localhost ~]# env
    SSH_AGENT_PID=2598
    HOSTNAME=localhost.localdomain
    DESKTOP_STARTUP_ID=
    SHELL=/bin/bash
    TERM=xterm
    HISTSIZE=1000
    GTK_RC_FILES=/etc/gtk/gtkrc:/root/.gtkrc-1.2-gnome2
    WINDOWID=41950507
    QTDIR=/root/qt-x11-opensource-src-4.2.2
    QTINC=/root/qt-x11-opensource-src-4.2.2/include
    USER=root
    LS_COLORS=no=00:fi=00:di=00;34:ln=00;36:pi=40;33:s o=00;35:bd=40;33;01:cd=40;33;01:or=01;05;37;41:mi= 01;05;37;41:ex=00;32:*.cmd=00;32:*.exe=00;32:*.com =00;32:*.btm=00;32:*.bat=00;32:*.sh=00;32:*.csh=00 ;32:*.tar=00;31:*.tgz=00;31:*.arj=00;31:*.taz=00;3 1:*.lzh=00;31:*.zip=00;31:*.z=00;31:*.Z=00;31:*.gz =00;31:*.bz2=00;31:*.bz=00;31:*.tz=00;31:*.rpm=00; 31:*.cpio=00;31:*.jpg=00;35:*.gif=00;35:*.bmp=00;3 5:\
    *.xbm=00;35:*.xpm=00;35:*.png=00;35:*.tif=00;35:
    GNOME_KEYRING_SOCKET=/tmp/keyring-lB9HNn/socket
    SSH_AUTH_SOCK=/tmp/ssh-TkJpfF2555/agent.2555
    KDEDIR=/usr
    SESSION_MANAGER=local/localhost.localdomain:/tmp/.ICE-unix/2555
    MAIL=/var/spool/mail/root
    DESKTOP_SESSION=default
    PATH=/root/qt-x11-opensource-src-4.2.2/bin:/root/qt-x11-opensource-src-4.2.2/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:\
    /usr/X11R6/bin:/root/qt-x11-opensource-src-4.2.2/bin:/root/bin
    GDM_XSERVER_LOCATION=local
    INPUTRC=/etc/inputrc
    PWD=/root
    LANG=en_US.UTF-8
    QMAKESPEC=/root/qt-x11-opensource-src-4.2.2/mkspecs/linux-g++
    GDMSESSION=default
    SSH_ASKPASS=/usr/libexec/openssh/gnome-ssh-askpass
    HOME=/root
    SHLVL=2
    GNOME_DESKTOP_SESSION_ID=Default
    LOGNAME=root
    QTLIB=/root/qt-x11-opensource-src-4.2.2/lib
    CVS_RSH=ssh
    DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-XG0E1vGhF5,guid=752ef945ca242e50a5d2bb9767ffcd00
    LESSOPEN=|/usr/bin/lesspipe.sh %s
    DISPLAY=:0.0
    G_BROKEN_FILENAMES=1
    COLORTERM=gnome-terminal
    XAUTHORITY=/root/.Xauthority
    _=/bin/env
    [root@localhost ~]#
    Last edited by jacek; 15th March 2007 at 11:54. Reason: wrapped too long lines
    I worked on windows Xp with Qt 4.2.2(Open Source Version) and MinGw
    now i am trying the same things on Fedora Core 5 (linux-gcc) and Qt 4.2.2 open source edition.

Similar Threads

  1. Problem combining QWorkspace & QGLWidget
    By Nb2Qt in forum Qt Programming
    Replies: 1
    Last Post: 18th December 2006, 21:45
  2. Permission denied error during linking
    By bashamehboob in forum Newbie
    Replies: 2
    Last Post: 15th April 2006, 13:02
  3. QGLWidget renderText problem
    By mbjerkne in forum Qt Programming
    Replies: 1
    Last Post: 7th April 2006, 21:35
  4. Replies: 4
    Last Post: 20th February 2006, 09:11
  5. Runtime dynamic linking + Qt4 problem
    By _Ramirez_ in forum Qt Programming
    Replies: 5
    Last Post: 11th February 2006, 14:28

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.