Bug 852828 - excess dependencies due to pkg-config
excess dependencies due to pkg-config
Status: CLOSED NEXTRELEASE
Product: Fedora
Classification: Fedora
Component: systemd (Show other bugs)
18
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: systemd-maint
Fedora Extras Quality Assurance
:
Depends On:
Blocks: 854355
  Show dependency treegraph
 
Reported: 2012-08-29 13:21 EDT by Bill Nottingham
Modified: 2014-03-16 23:32 EDT (History)
10 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-09-13 09:55:53 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Bill Nottingham 2012-08-29 13:21:30 EDT
Description of problem:

The placement of pkg-config files in the main systemd package causes systemd to have a requirement on /usr/bin/pkg-config.

This brings into any minimal installation:
pkgconfig
glib2
gamin
eject
libxml2
libffi
shared-mime-info

Fixes:
1) Move pkgconfig files to systemd-devel
2) Filter the pkg-config requirement out

Tangentially, journalctl is now bringing in:
qrencode
libpng

which is a little odd.

Version-Release number of selected component (if applicable):

189-2

How reproducible:

100%
Comment 1 Lennart Poettering 2012-09-11 23:05:07 EDT
Hmm, so we'd really like to keep that .pc file in the main package as that file encodes system info rather than development info. We have another set of .pc files for the devel packages which actually encodes information about the headers of the libs.

One simple solution would be to simply make the pkg-config dir owned by multiple packages and drop the explicit dep on pkg-config. Do you think that would be acceptable?

(At least the eject dep should go away now btw, given that eject has been moved into util-linux. And why does glib require eject anyway given that it makes use of udisks properly? And I really wonder if gamin isn't an obsolete dep these days.).

The qrencode stuff is pulled in to show the QR code for the sealing stuff. I thought about implementing my own QR code generator for that, but this turned out to be more complex than I thought and since the library was otherwise pretty OK I chose to simply make use of it. To deal with that we'd have a couple of options:

a) split out the qrencode lib into a separate package. Only the qrencode tool needs libpng, and we don't need that.

b) drop qrcode support in systemd, it's an optional dep

c) use a drop-in version of the relevant code from qrencode in systemd.

I'd vote for a) here.

Opinions?
Comment 2 Bill Nottingham 2012-09-12 15:44:00 EDT
(In reply to comment #1)
> One simple solution would be to simply make the pkg-config dir owned by
> multiple packages and drop the explicit dep on pkg-config. Do you think that
> would be acceptable?

It's not an explicit dependency - it's added by RPM any time a pkgconfig file is included in a package. It would need to be filtered out.

> The qrencode stuff is pulled in to show the QR code for the sealing stuff. I
> thought about implementing my own QR code generator for that, but this
> turned out to be more complex than I thought and since the library was
> otherwise pretty OK I chose to simply make use of it. To deal with that we'd
> have a couple of options:
> 
> a) split out the qrencode lib into a separate package. Only the qrencode
> tool needs libpng, and we don't need that.
> 
> b) drop qrcode support in systemd, it's an optional dep
> 
> c) use a drop-in version of the relevant code from qrencode in systemd.
> 
> I'd vote for a) here.
> 
> Opinions?

a) is simplest.
Comment 3 Lennart Poettering 2012-09-12 16:24:11 EDT
I filed https://bugzilla.redhat.com/show_bug.cgi?id=856808 for the second issue.
Comment 4 Lennart Poettering 2012-09-12 18:43:58 EDT
I tried filtering pkg-config from the deps, but couldn't get it to work.


Adding this didn't make the dep go away. It just moved it from the top of the dep list to the end... weird.

%filter_requires_in %{datadir}/pkgconfig
%filter_setup

This caused all .so deps to go away too...

%filter_from_requires /usr/bin/pkg-config
%filter_setup

Not sure what is going on here. It appears to me that filtering automatic deps is completely broken in RPM.
Comment 5 Lennart Poettering 2012-09-13 09:55:53 EDT
OK, seems the new way to do this is this:

%global __requires_exclude pkg-config

and that works well and is not broken like the %filter stuff. I have now added this to the RPM and the dep on pkg-config is gone, so I guess this bug can be closed now.

Note You need to log in before you can comment on or make changes to this bug.