← Back to team overview

maria-discuss team mailing list archive

Re: MariaDB 10.2.7 and libmysql compatibility

 

well, if someone has the same problem and wants to avoid multiple packages for now a dirty hack to just ship the 10.1 libmysqlclient, it works currently on my testsserver with every software linked against 10.1 while mysqld is 10.2
__________________________________________

* copy the existing "libmysqlclient.so.18.0.0"
  from 10.1 to rpmbuild/SOURCES
* Source6: libmysqlclient.so.18.0.0

at bottom of %install:
# hack to ship binary 'libmysqlclient.so.18.0.0' to support software linked against 10.1.x
cp %{SOURCE6} %{buildroot}%{_libdir}/mysql/
pushd %{buildroot}%{_libdir}/mysql/
 ln -s libmysqlclient.so.18.0.0 libmysqlclient.so.18
popd
__________________________________________

%files libs
%dir %{_libdir}/mysql
%dir %{_datadir}/mysql
%{_datadir}/mysql/charsets
%{_datadir}/mysql/english
%{_libdir}/mysql/libmariadb.so.*
%{_libdir}/mysql/libmysqlclient.so.*
%{_sysconfdir}/ld.so.conf.d/*
%lang(cs) %{_datadir}/mysql/czech
%lang(da) %{_datadir}/mysql/danish
%lang(de) %{_datadir}/mysql/german
%lang(el) %{_datadir}/mysql/greek
%lang(es) %{_datadir}/mysql/spanish
%lang(et) %{_datadir}/mysql/estonian
%lang(fr) %{_datadir}/mysql/french
%lang(hu) %{_datadir}/mysql/hungarian
%lang(it) %{_datadir}/mysql/italian
%lang(ja) %{_datadir}/mysql/japanese
%lang(ko) %{_datadir}/mysql/korean
%lang(nl) %{_datadir}/mysql/dutch
%lang(no) %{_datadir}/mysql/norwegian
%lang(no) %{_datadir}/mysql/norwegian-ny
%lang(pl) %{_datadir}/mysql/polish
%lang(pt) %{_datadir}/mysql/portuguese
%lang(ro) %{_datadir}/mysql/romanian
%lang(ru) %{_datadir}/mysql/russian
%lang(sk) %{_datadir}/mysql/slovak
%lang(sr) %{_datadir}/mysql/serbian
%lang(sv) %{_datadir}/mysql/swedish
%lang(uk) %{_datadir}/mysql/ukrainian

Am 13.07.2017 um 14:00 schrieb Reindl Harald:
i am missing something (probably simple like symbol versioning however done with some hack) or is it really not possible by providing symlinks to avoid "libmysqlclient.so.18 => not found" and all clients linked against 10.1.x failing?

attached my current rpm-spec - the server itself works fine and i really want to avoid building a "server-only" package for the whole lifetime of Fedora25/26 as well as not wait for Fedora 27 to get 10.2.x

[root@testserver:/usr/lib64/mysql]$ ls
insgesamt 308K
lrwxrwxrwx 1 root root 13 2017-07-13 13:15 libmysqlclient.so.18.0.0 -> libmariadb.so lrwxrwxrwx 1 root root 13 2017-07-13 13:15 libmysqlclient.so.18 -> libmariadb.so
-rwxr-xr-x 1 root root 305K 2017-07-13 13:15 libmariadb.so.3
lrwxrwxrwx 1 root root 15 2017-07-13 13:15 libmariadb.so -> libmariadb.so.3 lrwxrwxrwx 1 root root 17 2017-07-13 13:15 libmysqlclient_r.so -> libmysqlclient.so lrwxrwxrwx 1 root root 13 2017-07-13 13:15 libmysqlclient.so -> libmariadb.so

[root@testserver:/usr/lib64/mysql]$ ldd /usr/sbin/dbmail-imapd
         linux-vdso.so.1 (0x00007fff2fdfd000)
         libgmime-2.6.so.0 => /lib64/libgmime-2.6.so.0 (0x00007f0b0fd94000)
libgobject-2.0.so.0 => /lib64/libgobject-2.0.so.0 (0x00007f0b0fb42000)
         libglib-2.0.so.0 => /lib64/libglib-2.0.so.0 (0x00007f0b0f82f000)
         libevent-2.0.so.5 => /lib64/libevent-2.0.so.5 (0x00007f0b0f7e5000)
         libzdb.so.11 => /lib64/libzdb.so.11 (0x00007f0b0f7d0000)
libdbmail.so.0 => /usr/lib64/dbmail/libdbmail.so.0 (0x00007f0b0f759000)
         libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f0b0f53b000)
         libc.so.6 => /lib64/libc.so.6 (0x00007f0b0f175000)
         libgio-2.0.so.0 => /lib64/libgio-2.0.so.0 (0x00007f0b0ede2000)
         libz.so.1 => /lib64/libz.so.1 (0x00007f0b0ebcc000)
         libpcre.so.1 => /lib64/libpcre.so.1 (0x00007f0b0e95a000)
         libffi.so.6 => /lib64/libffi.so.6 (0x00007f0b0e750000)
         libmysqlclient.so.18 => not found
         libm.so.6 => /lib64/libm.so.6 (0x00007f0b0e447000)
         libdl.so.2 => /lib64/libdl.so.2 (0x00007f0b0e243000)
         libssl.so.10 => /lib64/libssl.so.10 (0x00007f0b0dfd1000)
         libcrypto.so.10 => /lib64/libcrypto.so.10 (0x00007f0b0db70000)
libgmodule-2.0.so.0 => /lib64/libgmodule-2.0.so.0 (0x00007f0b0d96a000) libgthread-2.0.so.0 => /lib64/libgthread-2.0.so.0 (0x00007f0b0d768000)
         libmhash.so.2 => /lib64/libmhash.so.2 (0x00007f0b0d53c000)
libevent_pthreads-2.0.so.5 => /lib64/libevent_pthreads-2.0.so.5 (0x00007f0b0d538000)
         libcrypt.so.1 => /lib64/libcrypt.so.1 (0x00007f0b0d302000)
         /lib64/ld-linux-x86-64.so.2 (0x0000559e18ffe000)
         libselinux.so.1 => /lib64/libselinux.so.1 (0x00007f0b0d0db000)
         libresolv.so.2 => /lib64/libresolv.so.2 (0x00007f0b0cebe000)
         libmount.so.1 => /lib64/libmount.so.1 (0x00007f0b0cc74000)
         libgomp.so.1 => /lib64/libgomp.so.1 (0x00007f0b0ca46000)
libgssapi_krb5.so.2 => /lib64/libgssapi_krb5.so.2 (0x00007f0b0c7f9000)
         libkrb5.so.3 => /lib64/libkrb5.so.3 (0x00007f0b0c513000)
         libcom_err.so.2 => /lib64/libcom_err.so.2 (0x00007f0b0c30f000)
         libk5crypto.so.3 => /lib64/libk5crypto.so.3 (0x00007f0b0c0dc000)
         libfreebl3.so => /lib64/libfreebl3.so (0x00007f0b0bed9000)
         libblkid.so.1 => /lib64/libblkid.so.1 (0x00007f0b0bc96000)
         libuuid.so.1 => /lib64/libuuid.so.1 (0x00007f0b0ba91000)
         librt.so.1 => /lib64/librt.so.1 (0x00007f0b0b889000)
libkrb5support.so.0 => /lib64/libkrb5support.so.0 (0x00007f0b0b678000)
         libkeyutils.so.1 => /lib64/libkeyutils.so.1 (0x00007f0b0b474000)


References