Qt Application Deployment. Can't Connect to Database on Foreign Machine.

  • I'm building a client-side application using the OCI Sql Plugin to connect with an Oracle Database for windows machines. After hours of struggling through I finally managed to build the corresponding libraries. I pretty much followed this post this since the Qt guide was outdated. I'm at the point where I would like to run my application on different computers, but I'm still running into trouble with the 32bit app I thought I'd created successfully.

    I've read this qt webpage on application deployment several times along with other stackoverflow posts and I'm still stumped. I thought I had all of the corresponding.dlls because my program executes on foreign computers. By executing on foreign computers, I mean it loads the plugin and executes normally, except it immediately fails when trying to connect to the Oracle database.

    Here's what I have done up to this point:
    -Successfully built OCI library using mingw32
    -Connected to the database on my local machine (even from the deployment directory called 'vast')
    -Included the OCI plugin in the deployment directory in a folder called 'sqldrivers'
    -Included qwindows.dll in it's own 'platforms' folder also in the deployment directory
    -Included all corresponding qt .dll files from mingw32 directory
    -Copied oci.dll (oracle client dll) into every directory into my deployment folder

    Here's my deployment directory:
    alt text
    alt text
    alt text

    I've tried my application on two different computers and it hasn't worked on either of them. I've also verified that no there's firewall issue so I know that's not the cause. Again, the application loads and runs fine. However, as soon as an attempt is made to connect to the database, it immediately denies the connection instead of waiting a second or so for the server's response.

    In addition, I've opened it using dependency walker which has spotted some errors. I briefly read over some of the api-ms-xxx dependencies and I've gotten the idea that they're a false positive. I'm not familiar with dependency walker, but here is a snapshot of the output:
    alt text

    My program runs on foreign devices so I'm not sure if there is a dependency issue. Is it possible a program could execute while still missing dependencies?

    If anymore information is needed I will gladly provide it.

    Thanks for reading.

  • Moderators

    @Pratted What error message do you get when trying to connect on other machines? http://doc.qt.io/qt-5/qsqldatabase.html#lastError

Log in to reply

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.