I have read the archives trying to find if there is any solution to the problem i have been having
Have seen a couple of related cases but nothing of this kind
I am trying to build the mysql plugin using
qmake -o Makefile "INCLUDEPATH+=D:\MYSQLserver\include" "LIBS+=D:\MYSQLserver\lib\opt\libmysql.lib" mysql.pro
nmake
at the qt4 command prompt. I keep getting the following error, and i don not know how to resolve it:
link /LIBPATH:"d:\Qt\4.2.0\lib" /LIBPATH:"d:\Qt\4.2.0\lib" /NOLOGO /DEBU
G /DEBUG /DLL /OUT:..\..\..\..\plugins\sqldrivers\qsqlmysqld.dll @C:\DOCUME~1\KE
ITHB~1\LOCALS~1\Temp\nm39A.tmp
LINK : fatal error LNK1104: cannot open file 'D:\MYSQL\lib\opt\libmysql.lib.lib'
NMAKE : fatal error U1077: 'link' : return code '0x450'
Stop.
NMAKE : fatal error U1077: '"D:\Program Files\Microsoft Visual Studio .NET 2003\
VC7\BIN\nmake.exe"' : return code '0x2'
the error basically concerns not being able to find libmysql.lib.lib:
error LNK:1104 libmsql.lib.lib
could some one please help me with this
all suggestions welcomed
thanks in advance
forgot to mention that i am using windows, also when i try the peice of code:
#include <QCoreApplication>
#include <QSqlDatabase>
#include <QSqlError>
#include <QStringList>
#include <QtDebug>
int main( int argc, char **argv )
{
qDebug() << db.lastError();
}
#include <QCoreApplication>
#include <QSqlDatabase>
#include <QSqlError>
#include <QStringList>
#include <QtDebug>
int main( int argc, char **argv )
{
QCoreApplication app( argc, argv );
qDebug() << QSqlDatabase::drivers();
QSqlDatabase db( QSqlDatabase::addDatabase( "QMYSQL" ) );
qDebug() << db.lastError();
}
To copy to clipboard, switch view to plain text mode
i get the output:
("QSQLITE", "QODBC3", "QODBC", "QPSQL7", "QPSQL")
QSqlDatabase: QMYSQL driver not loaded
QSqlDatabase: available drivers: QSQLITE QODBC3 QODBC QPSQL7 QPSQL
QSqlError(-1, "Driver not loaded", "Driver not loaded")
Press any key to continue
Bookmarks