Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. [SOLVED] SQL Driver problem with Qt 5.3.2
Qt 6.11 is out! See what's new in the release blog

[SOLVED] SQL Driver problem with Qt 5.3.2

Scheduled Pinned Locked Moved General and Desktop
3 Posts 2 Posters 2.6k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    mikeosoft
    wrote on last edited by
    #1

    My configuration is:
    Qt Creator 3.2.1
    Based on Qt 5.3.2 (GCC 4.6.1, 64 bit)
    From revision 602746950b

    Running on Linux Mint 17 KDE 64 Bit

    I just upgraded to the new version today, using the maintenance tool and now my mysql drivers won't work. I had managed to get these working recently using the process below:

    @
    cd /home/mike/Qt/5.3/Src/qtbase/src/plugins/sqldrivers/mysql
    /home/mike/Qt/5.3/gcc_64/bin/qmake mysql.pro
    make
    sudo make install
    @

    I didn't think such a minor version change would have caused them to stop working.

    I checked all the paths were the same and ran the commands above as I did before, but I get the error:
    @
    g++ -c -pipe -I/usr/include/mysql -O2 -fvisibility=hidden -fvisibility-inlines-hidden -std=c++0x -fno-exceptions -Wall -W -D_REENTRANT -fPIC -DQT_NO_MTDEV -DQT_NO_LIBUDEV -DQT_NO_CAST_TO_ASCII -DQT_NO_CAST_FROM_ASCII -DQT_NO_EXCEPTIONS -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -DQT_NO_DEBUG -DQT_PLUGIN -DQT_SQL_LIB -DQT_CORE_LIB -I../../../../mkspecs/linux-g++ -I. -I/work/build/icu_install/include -I/home/mike/Qt/5.3/Src/qtbase/include/QtSql/5.3.1 -I/home/mike/Qt/5.3/Src/qtbase/include/QtSql/5.3.1/QtSql -I../../../../include -I../../../../include/QtSql -I/home/mike/Qt/5.3/Src/qtbase/include/QtCore/5.3.1 -I/home/mike/Qt/5.3/Src/qtbase/include/QtCore/5.3.1/QtCore -I../../../../include/QtCore -I.moc -o .obj/qsql_mysql.o ../../../sql/drivers/mysql/qsql_mysql.cpp
    ../../../sql/drivers/mysql/qsql_mysql.cpp:44:40: fatal error: QtSql/private/qsqldriver_p.h: No such file or directory
    #include <QtSql/private/qsqldriver_p.h>
    ^
    compilation terminated.
    make: *** [.obj/qsql_mysql.o] Error 1
    @

    When I run make.

    I get:
    @
    g++ -c -pipe -I/usr/include/mysql -O2 -fvisibility=hidden -fvisibility-inlines-hidden -std=c++0x -fno-exceptions -Wall -W -D_REENTRANT -fPIC -DQT_NO_MTDEV -DQT_NO_LIBUDEV -DQT_NO_CAST_TO_ASCII -DQT_NO_CAST_FROM_ASCII -DQT_NO_EXCEPTIONS -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -DQT_NO_DEBUG -DQT_PLUGIN -DQT_SQL_LIB -DQT_CORE_LIB -I../../../../mkspecs/linux-g++ -I. -I/work/build/icu_install/include -I/home/mike/Qt/5.3/Src/qtbase/include/QtSql/5.3.1 -I/home/mike/Qt/5.3/Src/qtbase/include/QtSql/5.3.1/QtSql -I../../../../include -I../../../../include/QtSql -I/home/mike/Qt/5.3/Src/qtbase/include/QtCore/5.3.1 -I/home/mike/Qt/5.3/Src/qtbase/include/QtCore/5.3.1/QtCore -I../../../../include/QtCore -I.moc -o .obj/qsql_mysql.o ../../../sql/drivers/mysql/qsql_mysql.cpp
    ../../../sql/drivers/mysql/qsql_mysql.cpp:44:40: fatal error: QtSql/private/qsqldriver_p.h: No such file or directory
    #include <QtSql/private/qsqldriver_p.h>
    ^
    compilation terminated.
    make: *** [.obj/qsql_mysql.o] Error 1
    @

    when I run sudo make install
    Any suggestions as to what I can do to make this work or is it a problem with the new version?

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      Since you upgraded to 5.3.2, why are you using 5.3.1 sources ? Also, you should not need to use sudo since you installed Qt in your home directory.

      Where did you get the sources from ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • M Offline
        M Offline
        mikeosoft
        wrote on last edited by
        #3

        I down loaded the installer from the website, but missed checking which tick boxes were selected/unselected in the selection criteria.

        I uninstalled and reinstalled and it now works perfectly. Sorry about that.

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved