Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. [SOLVED] Qt mysql driver not loaded (mint)

[SOLVED] Qt mysql driver not loaded (mint)

Scheduled Pinned Locked Moved Installation and Deployment
6 Posts 2 Posters 3.5k 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.
  • J Offline
    J Offline
    jaco87
    wrote on last edited by
    #1

    i guy i have a problem with qt and mysq, i try to connect with this code the db but i have this error:

    QSqlDatabase: QMYSQL driver not loaded
    QSqlDatabase: available drivers: QSQLITE

    i tried to install mysql driver with this guide: http://qt-project.org/doc/qt-4.8/sql-driver.html

    but i dont'have the mysql folder, when i go to the installation folder of my qt i foud this situation

    /usr/lib/i386-linux-gnu/qt5/plugins/sqldrivers there are two file: libsqllite.so and libsqlmysql.so.

    help me!!! :-) please

    1 Reply Last reply
    0
    • IamSumitI Offline
      IamSumitI Offline
      IamSumit
      wrote on last edited by
      #2

      http://qt-project.org/forums/viewthread/41828/

      Be Cute

      1 Reply Last reply
      0
      • J Offline
        J Offline
        jaco87
        wrote on last edited by
        #3

        thank's for the reply,but I use linux mint the guide is for windows.

        1 Reply Last reply
        0
        • IamSumitI Offline
          IamSumitI Offline
          IamSumit
          wrote on last edited by
          #4

          oops ..

          http://techies-home.blogspot.in/2011/09/install-qt-mysql-driver-for-linux.html

          Be Cute

          1 Reply Last reply
          0
          • J Offline
            J Offline
            jaco87
            wrote on last edited by
            #5

            thank's for this guide, but the error is the same, the driver is not avaible, i try more tutorial :-(

            1 Reply Last reply
            0
            • J Offline
              J Offline
              jaco87
              wrote on last edited by
              #6

              I have solved the problem with this procedure:
              @usename@usename-pc ~ $ sudo apt-get install tasksel
              usename@usename-pc ~ $ sudo tasksel install LAMP
              usename@usename-pc ~ $ sudo tasksel install libmysqlclient-dev
              usename@usename-pc ~ $ cd /home/usename/Qt5.0.2/5.0.2/Src/qtbase/src/plugins/sqldrivers/mysql
              usename@usename-pc ~ $ /home/usename/Qt5.0.2/5.0.2/gcc_64/bin/qmake "INCLUDEPATH+=/usr/include/mysql" "LIBS+=-L/usr/lib/x86_64-linux-gnu -lmysqlclient_r" mysql.pro
              usename@usename-pc ~ $ make
              usename@usename-pc ~ $ make install@

              nb: usename=username
              thank's

              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