Bug 910774

Summary: clean up libuser.pc
Product: [Fedora] Fedora Reporter: Karel Zak <kzak>
Component: libuserAssignee: Miloslav Trmač <mitr>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 19CC: lnie, mitr
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: libuser-0.60-3.fc20 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-11-10 07:58:50 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:
Embargoed:

Description Karel Zak 2013-02-13 14:20:52 UTC
Description of problem:

$ pkg-config --libs libuser                                      
-pthread -luser -lcrypt -lgobject-2.0 -lgmodule-2.0 -lrt -lglib-2.0  

I guess that not all of the libs are used by libuser API. It seems that
--libs also returns libs used internally by libuser. It's pretty common mistake and it generates unwanted dependencies.

For example:

$ readelf -a ./chfn  | grep NEED
  [ 8] .gnu.version_r    VERNEED          00000000004010a8  000010a8
 0x0000000000000001 (NEEDED)             Shared library: [libuser.so.1]
 0x0000000000000001 (NEEDED)             Shared library: [libcrypt.so.1]
 0x0000000000000001 (NEEDED)             Shared library: [libgobject-2.0.so.0]
 0x0000000000000001 (NEEDED)             Shared library: [libgmodule-2.0.so.0]
 0x0000000000000001 (NEEDED)             Shared library: [librt.so.1]
 0x0000000000000001 (NEEDED)             Shared library: [libglib-2.0.so.0]
 0x0000000000000001 (NEEDED)             Shared library: [libpam.so.0]
 0x0000000000000001 (NEEDED)             Shared library: [libpam_misc.so.0]
 0x0000000000000001 (NEEDED)             Shared library: [libselinux.so.1]
 0x0000000000000001 (NEEDED)             Shared library: [libpthread.so.0]
 0x0000000000000001 (NEEDED)             Shared library: [libc.so.6]


The solution is to use Requires.private in libuser.pc for all private stuff.

The pkg-config is smart enough to use Requires.private for "--lisb --static" output.

Comment 1 Fedora End Of Life 2013-04-03 16:21:15 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 19 development cycle.
Changing version to '19'.

(As we did not run this process for some time, it could affect also pre-Fedora 19 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 19 End Of Life. Thank you.)

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora19

Comment 2 Miloslav Trmač 2013-09-20 15:11:48 UTC
Fixed in upstream commit b60e0b0c7eb3 .  The output of (pkg-config --libs libuser) now reads
> -luser -lgobject-2.0 -lglib-2.0 
(Removing these two would be useful only in very rare cases, and would cause extra work fixing some users.)

Thanks for your report.

Comment 3 Fedora Update System 2013-10-16 14:06:25 UTC
libuser-0.60-3.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/libuser-0.60-3.fc20

Comment 4 Fedora Update System 2013-10-17 20:33:01 UTC
Package libuser-0.60-3.fc20:
* should fix your issue,
* was pushed to the Fedora 20 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing libuser-0.60-3.fc20'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2013-19208/libuser-0.60-3.fc20
then log in and leave karma (feedback).

Comment 5 lnie 2013-10-21 03:29:33 UTC
seems fine with libuser-0.60-3.fc20

Comment 6 Fedora Update System 2013-11-10 07:58:50 UTC
libuser-0.60-3.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.