Results 1 to 1 of 1

Thread: QMYSQL Driver installation

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    May 2013
    Posts
    1
    Thanked 1 Time in 1 Post
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows

    Default QMYSQL Driver installation

    Hello, for the past 3 days I've been trying to install the QMYSQL driver but I can't get it anyhow to work. I've tried a lot of guides and in all of them I get stuck in a moment.

    I'm running on a mac OS and using the qt 4.8.4 source and have the mysql connector c 6.1.0 installed.
    Here's the steps I've done so far:
    1. I've changed the working directory to /Users/Alexandru/Downloads/mysql-connector-c-6.1.0/lib then used the following commands to link the libraries in the /usr/lib folder:

    sudo ln -s libmysqlclient.18.dylib /usr/lib/libmysqlclient.dylib
    sudo ln -s libmysqlclient.18.dylib /usr/lib/libmysqlclient_r.dylib
    sudo ln -s libmysqlclient.18.dylib /usr/lib/libmysqlclient_r.18.dylib
    sudo ln -s libmysqlclient.18.dylib /usr/lib/libmysqlclient.18.dylib

    2. Changed the working directory to $QTDIR/src/plugins/sqldrivers/mysql and ran the following command:

    qmake -spec macx-g++ -o Makefile "INCLUDEPATH+=/Users/Alexandru/Downloads/mysql-connector-c-6.1.0/include" "LIBS+=-L/usr/lib -lmysqlclient_r" mysql.pro

    3. In the same folder I issue the command:

    make

    And I get the following error:
    ld: library not found for -lmysqlclient_r
    collect2: ld returned 1 exit status
    make[1]: *** [libqsqlmysql_debug.dylib] Error 1
    make: *** [debug] Error 2


    I also found this article: http://www.techsmog.com/index.php/20...on-osx-w-mamp/ where it says how to fix the problem but I don't have any ".la" library files which to link and when I tried with the ".a" file I still get the same error.
    Can someone please help me?

  2. The following user says thank you to alex_BongoJump for this useful post:


Similar Threads

  1. Help with QMYSQL driver for QT 4.4.0: driver not loaded
    By khikho in forum Installation and Deployment
    Replies: 4
    Last Post: 1st April 2011, 15:00
  2. QMYSQL database driver installation files
    By babygal in forum Newbie
    Replies: 28
    Last Post: 12th August 2010, 11:55
  3. QMYSQL driver not loaded
    By akhila in forum Newbie
    Replies: 1
    Last Post: 22nd February 2010, 18:24
  4. QMYSQL driver
    By pcaeiro in forum Qt Programming
    Replies: 2
    Last Post: 3rd September 2009, 14:35
  5. QMYSQL driver
    By Fastman in forum Installation and Deployment
    Replies: 2
    Last Post: 26th October 2007, 08:14

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.