Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Upgrade QT3 to QT4



  • Here at work we run Centos and have QT3 and QT4 installed along with OpenGL. Everyone uses 3 but I am trying to get 4 going so we can get partway to 4 and eventually to there and then maybe 5. I am a Linux novice and having trouble getting 4 to work. After working this for three days my latest attempts include: prefixing PATH with

    /usr/lib64/qt4:usr/include/Qt
    

    replacing qmake with qmake-qt4
    removing app.setMainWidget() from main.cpp, because it is not in QT4
    Editing Make file to add

    -I/usr/include/Qt  
    

    because it could not find qgl.h with the needed directory in PATH. (Did not need to do that for QT3.)
    The latest attempt at make claims there is no matching function for call to

    QDialog::QDialog( QWidget*&, const char*&)
    

    I have visited some qt.io sites about the conversion but they discuss code changes. I am starting from the beginning with simple examples from the books: “C++ GUI Programming with QT3” and with “… QT 4”

    What should I try next? Where might I look for some guidance?


  • Lifetime Qt Champion

    Hi
    Sadly im not good with Centos.

    However, how did you install it ?
    it seems to have an RPM for it
    https://centos.pkgs.org/7/centos-x86_64/qt-4.8.7-2.el7.x86_64.rpm.html

    on Ubuntu there is a tool qtchooser
    there is not something like that for Centos?


  • Lifetime Qt Champion

    @BKBK said in Upgrade QT3 to QT4:

    The latest attempt at make claims there is no matching function for call to

    Check the QDialog documentation from Qt4 to see what the correct QDialog constructor in Qt4 is.


Log in to reply