Description of problem: /usr/bin/mysql_config --libs output is: -L/usr/lib64/ -lmariadb -lz -ldl -lm -lpthread -lssl -lcrypto this implies zlib-devel is required to link. Up until https://src.fedoraproject.org/rpms/openssl/c/7a654fc69c499b54f38543ca40f765fbaf9bdf84?branch=master openssl-devel Requires: zlib-devel but this is no longer true. Version-Release number of selected component (if applicable): mariadb-connector-c-devel-3.0.9-2.fc31.x86_64 How reproducible: https://kojipkgs.fedoraproject.org/work/tasks/906/33810906/build.log Steps to Reproduce: 1. link using mysql_config --libs Actual results: fail w/o zlib-devel Expected results: success Additional info:
It would be very nice if libmariadb.pc was cleaned up, so it had a Libs/Libs.private split: Libs: -lmariadb Libs.Private: -lz -ldl -lm -lpthread -lssl -lcrypto since all I really need to link against is libmariadb.so and the dynamic linker will do the rest.
^ should be Libs.private: though I'm not sure it's case-sensitive.
PR: https://src.fedoraproject.org/rpms/mariadb-connector-c/pull-request/8
This looks like an upstream material. However I haven't understood it deep enought yet, to be able to defent such PR. -- The base problem is that you have a software building on top of "mariadb-connector-c", you are correctly using "mysql_config", but the build fail since the "-lz" linker flag was passed, but "zlib-devel" is not in the buildroot. The fisrt part is adding "zlib-devel" as a "Requires" to the "mariadb-connector-c-devel" subpackage. We do build the "mariadb-connector-c" package using "zlib", so this is a reasonable request. Fixing now: https://src.fedoraproject.org/rpms/mariadb-connector-c/c/8781fc38b459e984dddc0139028c1286d06452e4?branch=master https://koji.fedoraproject.org/koji/taskinfo?taskID=33813071 -- For the rest of the problem: I haven't really ever used pkgconfig, so I need to do some research on how it works and how it doesn't. I'll be glad for a detailed description, what exactly are you trying to achieve and how does that work. If that would make sense to me, I'd brought to the upstream. Anyway - the first part of the fix (requiring "zlib-devel") should be enough for you for now, right?
Yup sure, fixing the -devel requirement for now is fine. I rebased the PR anyway. There is a good discussion of "overlinking" and why you should use Libs.private here https://wiki.openmandriva.org/en/Overlinking_issues_in_packaging Essentially consumers of libmariadb.so only need to link against -lmariadb, not against -lmariadb -lz -lssl etc apr-util's mysql plugin picks up library deps expressed in `mysql_config --libs` even though they are not needed in this binary. If the pkg-config file used Libs.private, I could use the library list from there (just -lmariadb) and have a cleaner, less fragile and bugs like this would have been avoided. $ ldd -u -r /usr/lib64/apr-util-1/apr_dbd_mysql-1.so Unused direct dependencies: /lib64/libz.so.1 /lib64/libdl.so.2 /lib64/libm.so.6 /lib64/libpthread.so.0 /lib64/libssl.so.1.1 /lib64/libcrypto.so.1.1
mariadb-connector-c-3.0.9-3.fc30 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-77efb803f9
mariadb-connector-c-3.0.9-3.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-77efb803f9
mariadb-connector-c-3.0.9-3.fc30 has been pushed to the Fedora 30 stable repository. If problems still persist, please make note of it in this bug report.
After upgrading to F30, I found that this build is missing /usr/lib64/mariadb/plugin/auth_gssapi_client.so The last reported version containing that file is 3.0.9-2.fc30
Anthony Messina ! THANKS FOR HEADS UP ! A krb5-devel package was removed from the buildroot, which made the plugin not building, since it didn't have the needed files. Fix is on the way, together with 3.0.10 version. https://koji.fedoraproject.org/koji/taskinfo?taskID=34872897 (Rawhide build)
Partial fix for this BZ was released. Second part still awaits. Moving back to Assigned.
(In reply to Anthony Messina from comment #9) > After upgrading to F30, I found that this build is missing > /usr/lib64/mariadb/plugin/auth_gssapi_client.so Michal, issues like this might be discovered sooner if we have more specific %files section, i.e. instead of plugin/* to include more specific list. It makes the spec longer, but maybe worth it. Keeping up to you to decide.
Patch prepared and applied: https://src.fedoraproject.org/rpms/mariadb-connector-c/c/ad54a14b2c46f9a75936fe1af80043deb6f77d87?branch=master Please test in Rawhide by rebuilding the apr-util.
This bug appears to have been reported against 'rawhide' during the Fedora 31 development cycle. Changing version to '31'.
This bug appears to have been reported against 'rawhide' during the Fedora 31 development cycle. Changing version to 31.
NOT actively working on this task.
Resolved by a PR accepted by upstream, see https://src.fedoraproject.org/rpms/mariadb-connector-c/pull-request/8 for more info