libmysqlclient.so mismatch on fedora 33
-
I have installed libmysqlclient.so as part of "community-mysql-libs" package using yum. It is confirmed installed, and yum shows the package to include:
community-mysql-libs-8.0.25-1.fc33.x86_64 : The shared libraries required for MySQL clients Repo : updates Matched from: Filename : /usr/lib64/mysql/libmysqlclient.so.21 Filename : /usr/lib64/mysql/libmysqlclient.so.21.1.25
But I get driver not found errors in my apps. ldd shows that libqsqlmysql.so is expecting libmysqlclient.so.18, but yum has installed libmysqlclient.so.21 (see below). How do I bring these two into alignment? I'm running on Fedora 33
[root@localhost Qt]# ldd /opt/Qt/5.9.9/gcc_64/plugins/sqldrivers/libqsqlmysql.so linux-vdso.so.1 (0x00007ffe5ff1e000) libQt5Sql.so.5 => /opt/Qt/5.9.9/gcc_64/plugins/sqldrivers/../../lib/libQt5Sql.so.5 (0x00007fbc10e8a000) libQt5Core.so.5 => /opt/Qt/5.9.9/gcc_64/plugins/sqldrivers/../../lib/libQt5Core.so.5 (0x00007fbc10743000) libpthread.so.0 => /lib64/libpthread.so.0 (0x00007fbc10708000) libmysqlclient.so.18 => not found libstdc++.so.6 => /lib64/libstdc++.so.6 (0x00007fbc10520000) libm.so.6 => /lib64/libm.so.6 (0x00007fbc103da000) libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007fbc103bd000) libc.so.6 => /lib64/libc.so.6 (0x00007fbc101f1000) libz.so.1 => /lib64/libz.so.1 (0x00007fbc101d7000) libicui18n.so.56 => /opt/Qt/5.9.9/gcc_64/plugins/sqldrivers/../../lib/libicui18n.so.56 (0x00007fbc0fd3e000) libicuuc.so.56 => /opt/Qt/5.9.9/gcc_64/plugins/sqldrivers/../../lib/libicuuc.so.56 (0x00007fbc0f986000) libicudata.so.56 => /opt/Qt/5.9.9/gcc_64/plugins/sqldrivers/../../lib/libicudata.so.56 (0x00007fbc0dfa3000) libdl.so.2 => /lib64/libdl.so.2 (0x00007fbc0df9a000) libgthread-2.0.so.0 => /lib64/libgthread-2.0.so.0 (0x00007fbc0df95000) libglib-2.0.so.0 => /lib64/libglib-2.0.so.0 (0x00007fbc0de66000) /lib64/ld-linux-x86-64.so.2 (0x00007fbc112e6000) libpcre.so.1 => /lib64/libpcre.so.1 (0x00007fbc0dded000)
-
I tried installing a fresh Fedora 34, Qt from Qt website, and Fedora development tools. SAME error...now under F34 it is still looking for libmysqlclient.so.18
I tried compiling the Qt SQL drivers from source (in the Qt installed tree) and then the problem was solved. However, I don't that should be necessary. Is this a bug??
-
your version of Qt should either be the fedora 33 version, or you must build your chosen version of Qt for fedora33. qt-5.9 is probably a much older version than what is supplied in fedora 33.
There are ways to hack the .so links but often break if the newer version of the library isn't backwards compatible.
-
I tried installing a fresh Fedora 34, Qt from Qt website, and Fedora development tools. SAME error...now under F34 it is still looking for libmysqlclient.so.18
I tried compiling the Qt SQL drivers from source (in the Qt installed tree) and then the problem was solved. However, I don't that should be necessary. Is this a bug??
-
@ocgltd said in libmysqlclient.so mismatch on fedora 33:
Is this a bug?
No, it just means that Qt MySQL plug-in was built using older MySQL version...