PDA

View Full Version : Embed SQLite driver



NoRulez
7th October 2009, 10:15
Hey @all,

i want to embed the SQLite driver into my application, instead of deploying the qsqlite.dll as an extra file.

So, in the project file i use:

QTPLUGIN += qsqlite
in the main.cpp file i use:

Q_IMPORT_PLUGIN (qsqlite)

From ld i get the error that "-lsqlite" couldn't be found.

I configure and build Qt as:

configure ... -qt-sql-sqlite -plugin-sql-sqlite
The result is that i have both in the plugins folder
.) qsqlite.dll
.) qsqlited.dll
.) libqsqlite.a
.) libqsqlited.a

Best Regards
NoRulez

yan
7th October 2009, 10:26
To do it, you should have static plugin. So, you must rebuild sqlite plugin in static.
But i don't know exactely how to do it ...

NoRulez
7th October 2009, 10:41
The problem is that I don't want to build the complete Qt library as static. I only want to emebd the SQLite driver.