Seems to be a popular question but I can't find a suitable answer from those past questions....
Am following instructions at http://doc-snapshot.qt-project.org/q...ql-driver.html
I run qmake like so:
~/Qt/5.4/clang_64/bin/qmake "INCLUDEPATH+=/usr/local/mysql-5.6.22-osx10.8-x86_64/include" "LIBS+=-L/usr/local/lib -lmysqlclient_r" mysql.pro
~/Qt/5.4/clang_64/bin/qmake "INCLUDEPATH+=/usr/local/mysql-5.6.22-osx10.8-x86_64/include" "LIBS+=-L/usr/local/lib -lmysqlclient_r" mysql.pro
To copy to clipboard, switch view to plain text mode
So far, so good.
make
make
To copy to clipboard, switch view to plain text mode
Chugs along, and then:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -headerpad_max_install_names -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -stdlib=libc++ -mmacosx-version-min=10.7 -single_module -dynamiclib -o libqsqlmysql.dylib .obj/release/main.o .obj/release/qsql_mysql.o .obj/release/moc_qsql_mysql_p.o -F/Users/vi/Qt/5.4/clang_64/lib -L/usr/local/lib -L/opt/local/lib/mysql55/mysql -lmysqlclient_r -lz -framework QtSql -framework QtCore -framework DiskArbitration -framework IOKit
ld: warning: directory not found for option '-L/opt/local/lib/mysql55/mysql'
ld: library not found for -lmysqlclient_r
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [../../../../plugins/sqldrivers/libqsqlmysql.dylib] Error 1
make: *** [release-all] Error 2
I don't seem to have the file mysqlclient_r OR mysql55 folder on my system... Is Xcode looking for them ?
Bookmarks