Bug 1034988

Summary: gloox-devel should require gnutls-devel and libidn-devel
Product: [Fedora] Fedora Reporter: Jan Včelák <jv+fedora>
Component: glooxAssignee: Pavel Alexeev <pahan>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 20CC: i, pahan
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-05-09 11:23:39 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Jan Včelák 2013-11-26 20:00:51 UTC
Bug summary tells it all.

Gloox package config contains linker flags for GnuTLS library and IDN library, but corresponding -devel packages are not specified as requirements.

% cat /usr/lib64/pkgconfig/gloox.pc
prefix=/usr
exec_prefix=/usr
libdir=/usr/lib64
includedir=/usr/include

Name: gloox
Description: A high-level XMPP/Jabber library for C++
Version: 1.0.3
Libs: -L${libdir} -lgloox -lresolv -lresolv -lresolv   -lidn -lgnutls  -lgcrypt -lz
Cflags: -I${includedir}  -pthread

% rpm -q gloox-devel --requires
/bin/sh
/usr/bin/pkg-config
gloox = 1:1.0.3-1.fc20
libgloox.so.8()(64bit)
pkgconfig
rpmlib(CompressedFileNames) <= 3.0.4-1
rpmlib(FileDigests) <= 4.6.0-1
rpmlib(PayloadFilesHavePrefix) <= 4.0-1
rpmlib(PayloadIsXz) <= 5.2-1

Comment 1 Michael Schwendt 2013-11-26 20:59:46 UTC
Rather, since both libidn-devel and gnutls-devel contain a pkgconfig file, the gloox.pc file should "Requires: gnutls libidn" for sane pkgconfig inter-dependencies and corresponding automatic RPM dependencies.

Comment 2 Jan Včelák 2013-11-26 21:06:33 UTC
I didn't know that rpmbuild understands requirements in pkgconfig. Nice.

Anyway, I forgot about libgcrypt-devel, which is missing as well.

Comment 3 Michael Schwendt 2013-11-26 21:22:34 UTC
Oh, and libgloox already is linked dynamically with those two libs, so relinking isn't necessary: http://koji.fedoraproject.org/koji/rpminfo?rpmID=4295220
Mission objective would be to examine whether headers from libidn-devel and gnutls-devel are include by gloox-devel headers (it doesn't seem so), and then no dependency on those two -devel packages would be needed.

Further, there's a gloox-config script that contains a hardcoded /usr/lib for x86_64, which is a bug. And it relinks with the same libs (even three times -lresolv), too. Some polishing would be interesting. Also upstream. Occasionally such "Libs:" are specified incorrectly and should be moved to "Libs.private:" instead.

Comment 4 Pavel Alexeev 2013-12-15 09:02:28 UTC
Hello. Thanks for the bugreport.
Is that gloox-config script used anywhere to have worth fix it?

Comment 5 Michael Schwendt 2014-02-18 23:45:29 UTC
Well, you could ask upstream about whether they are aware of any users of that script.

It's quite common to simply query pkg-config in such a script and retrieve the needed values (such as --libdir).

Comment 6 Christopher Meng 2014-02-21 10:00:35 UTC
RPM may have problems somewhile, so is it better to add hard dependencies in -devel sub or do what?

Comment 7 Michael Schwendt 2014-02-21 11:44:12 UTC
Which problems in RPM do you refer to?

Comment 8 Pavel Alexeev 2014-03-03 11:40:52 UTC
Rawhide build http://koji.fedoraproject.org/koji/taskinfo?taskID=6589561

Comment 9 Fedora Update System 2014-03-03 12:03:32 UTC
gloox-1.0.9-2.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/gloox-1.0.9-2.fc20

Comment 10 Michael Schwendt 2014-03-03 12:34:32 UTC
If you had used %{?_isa} in those deps, that would have been more strict.

Comment 11 Pavel Alexeev 2014-03-03 13:33:28 UTC
Requires: gnutls-devel%{?_isa}, libidn-devel%{?_isa}?

Comment 12 Michael Schwendt 2014-03-03 18:42:46 UTC
Yes.

Comment 13 Pavel Alexeev 2014-03-04 08:15:48 UTC
Ok, let it be. Thanks. But where it is described?

Rawhide build: http://koji.fedoraproject.org/koji/taskinfo?taskID=6593687

Comment 14 Fedora Update System 2014-03-04 08:46:51 UTC
gloox-1.0.9-3.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/gloox-1.0.9-3.fc20

Comment 15 Michael Schwendt 2014-03-04 10:29:40 UTC
> But where it is described?

https://fedoraproject.org/wiki/Packaging:Guidelines#Requires_2

Comment 16 Pavel Alexeev 2014-03-05 08:14:22 UTC
Thanks.

Comment 17 Fedora Update System 2014-03-13 05:09:44 UTC
gloox-1.0.9-3.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.