Results 1 to 8 of 8

Thread: Latest SQLite

  1. #1
    Join Date
    Jan 2011
    Posts
    34
    Thanks
    6
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Latest SQLite

    I want to upgrade SQLite to the latest version, but didn't found how to build Qt plugin from SQLite source code available at their website.

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Latest SQLite

    I don't think you need to rebuild the plugin. Just replace the older SQLite library with the new one when deploying your app.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  3. #3
    Join Date
    Jan 2011
    Posts
    34
    Thanks
    6
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Latest SQLite

    Library from SQLite website don't work with Qt.

  4. #4
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Latest SQLite

    Quote Originally Posted by giantdragon View Post
    Library from SQLite website don't work with Qt.
    Really? Why not?
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  5. #5
    Join Date
    Jan 2011
    Posts
    34
    Thanks
    6
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Latest SQLite

    Problem solved!
    Attached Images Attached Images
    Last edited by giantdragon; 17th May 2011 at 23:52. Reason: Solved

  6. #6
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Latest SQLite

    No, they didn't forget to change the include. And if you want to use a different sqlite version than the one that comes with Qt then you need to tell Qt to use the system sqlite library instead of using the sources of sqlite directly (or you can just replace the source files and rebuild the driver). Consult "configure -help" for more info.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  7. #7
    Join Date
    Jan 2011
    Posts
    34
    Thanks
    6
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Latest SQLite

    Fortunately I have successfully compiled latest SQLite version. It seems works!!!

    1. Download latest SQLite sources, unpack them, copy to "C:\QtSDK\QtSources\4.7.3\src\3rdparty\sqlite"
    2. Open file "C:\QtSDK\QtSources\4.7.3\src\sql\drivers\sqlite\q sql_sqlite.h" Replace "#include <QtSql/private/qsqlcachedresult_p.h>" to "#include <C:/QtSDK/QtSources/4.7.3/src/sql/kernel/qsqlcachedresult_p.h>"
    3. cd "C:\QtSDK\QtSources\4.7.3\src\plugins\sqldrivers\s qlite"
    4. qmake "INCLUDEPATH+=C:\QtSDK\QtSources\4.7.3\src\plugins \sqldrivers\" "LIBS+=C:\QtSDK\QtSources\4.7.3\src\plugins\sqldri vers\"
    5. mingw32-make release

    Spent whole day solving this problem. I think Nokia must write tutorial how to do this and update include path.
    Last edited by giantdragon; 18th May 2011 at 00:02.

  8. #8
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Latest SQLite

    I think Nokia must write tutorial how to do this and update include path.
    There's a perfectly good option to build the Qt libraries using a system (external) Sqlite, rather than the bundled Sqlite. It is documented in the configure options referred to by the existing install docs (See Step 4), and also pointed out by Wysota above. Had you used that option this exercise would have been trivial.
    configure --help
    ...
    -system-sqlite ..... Use sqlite from the operating system.
    ...
    -I <string> ........ Add an explicit include path.
    -L <string> ........ Add an explicit library path.
    ...
    • Download, unpack, build, and install the SQlite library.
    • Unpack the Qt source or clean the configuration of an existing copy
    • Configure the Qt source with the "-system-sqlite" option. You will probably also need the -I and -L options.
    • Build Qt

    After this updating the version of Sqlite used is as simple as replacing the shared library.
    Last edited by ChrisW67; 18th May 2011 at 01:00.

Similar Threads

  1. QwtPolar with latest QWT
    By liran ritkop in forum Qwt
    Replies: 3
    Last Post: 14th April 2011, 07:14
  2. Latest QT Runtime Library RPM's ?
    By codematic in forum Installation and Deployment
    Replies: 2
    Last Post: 1st November 2010, 20:04
  3. Latest Qtopia
    By jaikumar in forum Qt for Embedded and Mobile
    Replies: 1
    Last Post: 7th December 2009, 13:37
  4. Mac--works w/latest snapshot, but not w/Qt 4.3
    By ber_44 in forum Installation and Deployment
    Replies: 2
    Last Post: 8th August 2007, 16:26
  5. Latest PDA's features...
    By AP.Sakkthivel in forum Qt for Embedded and Mobile
    Replies: 1
    Last Post: 2nd March 2006, 14:15

Tags for this Thread

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.