Results 1 to 3 of 3

Thread: Qt 4.4.0 + MinGW + MySQL installation problem

  1. #1
    Join Date
    Oct 2007
    Posts
    27
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Qt 4.4.0 + MinGW + MySQL installation problem

    Hello,

    I'm using Qt 4.4.0 (opensource) with MinGW and I have to work with MySQL 5.x. I consulted this document: http://www.jiggerjuice.net/software/qt-sql-drivers.html and I done everything exept MySQL Embedded Server.
    I configured Qt with: configure.exe -debug-and-release -stl -qt-zlib -qt-gif -qt-libpng -qt-libmng -qt-libtiff -qt-libjpeg -qmake
    -qt-sql-sqlite -qt-sql-mysql -l mysql -I c:\MySQL\src\include -L c:\MySQL\lib\opt
    -platform win32-g++
    and build it.

    After this my application works with mysql server, but when I copy my app to another computer it didn't work. Possible some dll-s are missing. When I copy my app (exe file) to another computer I also copy these files:
    libmySQL.dll
    mingwm10.dll
    QtCore4.dll
    QtGui4.dll
    QtNetwork4.dll
    QtSql4.dll
    QtXml4.dll

    When I star my app on another PC it work fine exept connection with database. For connection with database I'm using QSqlDatabase class, and when I enter connections parameters on my PC, class QSqlDatabase accept these parameters, but when I enter same parameters on other PC, class could not accept these parameters and could not establish connection with database.

    Should I copy some other dll or something else, or build some libreries staticly and implement it in my exe file?
    What should I do to make my application work on other PC?

    Thanks!

  2. #2
    Join Date
    Feb 2008
    Posts
    50
    Thanks
    1
    Thanked 2 Times in 2 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Qt 4.4.0 + MinGW + MySQL installation problem

    Try to make directory "sqldrivers" in the program`s dir and put there the dlls from "C:\Qt\4.4.3\plugins\sqldrivers"

    In your case you`ll probably need qsqlmysql4.dll and qsqlmysqld4.dll. Hope it works.

  3. #3
    Join Date
    Oct 2007
    Posts
    27
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Qt 4.4.0 + MinGW + MySQL installation problem

    It's works! Thank you a lot!

Similar Threads

  1. Is Qt 4.4.0 compatible with the current MinGW 5.1.4 release?
    By BernieW in forum Installation and Deployment
    Replies: 4
    Last Post: 31st July 2008, 23:16
  2. Replies: 6
    Last Post: 25th July 2008, 21:22
  3. qt4.3.1 mysql problem
    By twells55555 in forum Qt Programming
    Replies: 5
    Last Post: 8th October 2007, 21:26
  4. MySQL starting problem
    By shamik in forum General Discussion
    Replies: 5
    Last Post: 25th April 2007, 07:20

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.