Problem with mysql driver
-
Hi,
I'm trying to create application that connects to mysql database. However I'm getting an error:
QSqlDatabase: QMYSQL driver not loaded QSqlDatabase: available drivers: QSQLITE QMYSQL QMYSQL3 QPSQL QPSQL7I spent last 3 hours searching solution on the internet and found out, that running
ldd /opt/Qt/5.5/gcc_64/plugins/sqldrivers/libqsqlmysql.so | grep "not found"outputs:libmysqlclient_r.so.16 => not found libssl.so.10 => not found libcrypto.so.10 => not foundI'm unable to find those three anywhere on the web. Where can I find them and where should I put them?
I'm using Linux Mint 17.3 x64, Qt 5.5
-
Hi,
Do you have the MySQL client libraries installed and OpenSSL libraries installed in you system ? If so check their versions. They are likely to be more recent.
If that's the case, the most simple way is to install the dev packages for OpenSSL and MySQL and rebuild the MySQL plugin. The build process is explained in Qt's SQL driver documentation.
-
Hi,
Do you have the MySQL client libraries installed and OpenSSL libraries installed in you system ? If so check their versions. They are likely to be more recent.
If that's the case, the most simple way is to install the dev packages for OpenSSL and MySQL and rebuild the MySQL plugin. The build process is explained in Qt's SQL driver documentation.