Results 1 to 5 of 5

Thread: Problem deploying Qt app (plugin)

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Sep 2015
    Posts
    22
    Thanks
    4
    Qt products
    Qt5
    Platforms
    Windows

    Post Problem deploying Qt app (plugin)

    i'm trying to deploy my app built in Qt 5.6 MSVC2015. currently i have a problem loading qsqlite.dll plugin for reading my database. i made my research and i found some ways to edit Plugin path to find the plugin in my deployed-app directory but any of them works....any helps? I've tried copying the plugin into the app folder, using qt.conf(using this method make my app no start, with other methods simply shows Driver not loaded)

  2. #2
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Problem deploying Qt app (plugin)

    Maybe qsqlite.dll is missing one of its dependencies?
    E.g. sqlite.dll?

    Cheers,
    _

  3. #3
    Join Date
    Sep 2015
    Posts
    22
    Thanks
    4
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: Problem deploying Qt app (plugin)

    still not working. using QCoreApplication::addLibrary("plugins") in main doesn't works, using qt.conf w Plugin=plugins also not working, copying the qsqlite in plugins folder or in .exe folder or in plugins/sqldrivers also not working...any other ideas?.......i disable all Qt folders to check one by one if my app needs some extra dll but it looks like just need qsqlite.dll

    the code for the connections...

    Qt Code:
    1. #include "connection.h"
    2. #include <QtCore>
    3. #include <QDir>
    4. #include <QUrl>
    5. #include <QMessageBox>
    6.  
    7.  
    8. QSqlDatabase Connection::_db=QSqlDatabase::addDatabase("QSQLITE");
    9. Connection *Connection::_conn = new Connection;
    10.  
    11. //create connection singleton
    12. Connection::Connection(QObject *parent) : QObject(parent){
    13.  
    14. _db.setDatabaseName(QString("%1/lib/database.sqlite").arg(QDir::currentPath()));
    15.  
    16. if(_db.open()){
    17. qDebug()<<"database open";
    18. }else qDebug()<<"database not open";
    19. }
    20.  
    21. //open connection
    22. Connection *Connection::openConn(){
    23. if(!_conn){
    24. _conn=new Connection();
    25. }return _conn;
    26. }
    27.  
    28. //close conection
    29. Connection *Connection::closeConn(){
    30. _db.close();
    31. _db.removeDatabase(QSqlDatabase::defaultConnection);
    32. return _conn;
    33. }
    34.  
    35. QSqlDatabase Connection::db(){
    36. return _db;
    37. }
    To copy to clipboard, switch view to plain text mode 

    maybe some directive am i missing?

  4. #4
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Problem deploying Qt app (plugin)

    And that folder contains both qsqlite.dll and sqlite.dll?

    Cheers,
    _

  5. #5
    Join Date
    Sep 2015
    Posts
    22
    Thanks
    4
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: Problem deploying Qt app (plugin)

    yes, i put both of them next to .exe, also in /sqldrivers/, /plugins/sqldrivers/

Similar Threads

  1. Problem after deploying with JPG and GIFs
    By danoc93 in forum Newbie
    Replies: 2
    Last Post: 15th February 2012, 03:49
  2. Deploying sqlite plugin.
    By zim in forum Newbie
    Replies: 1
    Last Post: 28th December 2010, 06:46
  3. Replies: 5
    Last Post: 20th December 2010, 10:01
  4. Problem with deploying
    By ardisaz in forum Qt for Embedded and Mobile
    Replies: 1
    Last Post: 6th December 2010, 14:16
  5. problem with deploying static application in windows
    By remy06 in forum Installation and Deployment
    Replies: 3
    Last Post: 2nd June 2009, 07:46

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.