Re: Request and Question about pkgconfig and related pkgs
Daniel Macks <[email protected]>
| Newsgroups | gmane.os.apple.fink.gnome |
|---|---|
| Message-ID | <[email protected]> |
On Sat, Jan 03, 2009 at 12:26:56AM +0900, Tomoaki Okayama wrote: > Hello, > > I would like to make a request and ask a question > about pkgconfig. > > 1. Why don't you remove the dependency on glib? > `glib' is obsolete, which should be replaced with `glib2'. > (some people hate to install glib) > And glib or glib2 feature may be not necessary for users, > so it is easier to simply remove it than to switch to glib2. I will use "glib1" to mean "the old glib" to avoid confusion here... pkg-config requires (glib1 or glib2) in order to parse .pc files, and glib2:BuildDepends:pkgconfig, so there is no clean solution as you would like. To switch to glib2 and avoid being circular, either pkg-config must not use glib2 or the glib2 build must not use pkg-config. The pkg-config distro actually contains its own full set of glib1 sources and can use them instead of relying on external glib2. Actually, the ability to use external glib1 is a fink hack. By default, pkg-config uses existing system-supplied glib2, which we don't have, or included glib1 source. So if we just wanted to break the dependency on external glib1 package, we could use that instead. But that's silly...we still wind up building glib1 and having its library, but (i) without any fink improvements, patches, etc. (ii) in duplicate if user does have anything else that uses glib1 and (iii) repeatedly every time a new pkg-config package is released. Since back to glib-2.0, glib2 configure does check for pkg-config being available. At this time (glib-2.18.2) that result is not used for anything (reading .pc files, determinging pathnames, etc.), but there are public .m4 macros that do use it. So for now, we could patch glib2 to avoid the BD:pkgconfig and switch pkg-config to use glib2. However, there is no guarantee that in the future, glib2 might not actually use pkg-config for something substantial that would be difficult or fragile to patch. Would be useful to file a gnome bugzilla about it being needed *only* by glib2 runtime files, not at glib2's build, which may not happen on the same machine and therefore does not truly enforce anything useful. > 2. Is "Depends: pkgconfig" good? > Some packages, for example shared-mime-info and gtk-doc, Depends > (not BuildDepends) on pkgconfig, just because the packages contain > *.pc files. I don't think they truly `Depends' on pkgconfig... > The packages in debian don't depend on pkgconfig, see: > http://packages.debian.org/sid/shared-mime-info > http://packages.debian.org/sid/gtk-doc-tools > If the dependency on pkgconfig is not necessary, it would be > advisable to remove it from the packages. > Could it be overkill to mark "BuildDependsOnly: True" on pkgconfig? :-} There is a whole fink-wiki page with info about when and why one might want Depends:pkgconfig in a package that supplies .pc files. I'm not back to a machine that has CVS yet, but will add the wiki URL to DescUsage soon. BDO:true is bad overkill (even without the previous answer). Some packages do use pkgconfig at runtime (example: the perl bindings package for it). To turn around the question: why would one *not* want to have Depends:pkgconfig? dan -- Daniel Macks [email protected] http://www.netspace.org/~dmacks ------------------------------------------------------------------------------