[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: dpkg: should it remove in reverse depends order?

Lars Wirzenius <liw@liw.iki.fi> writes:

> Below is a log of a transaction with apt-get and dpkg to first install
> fontconfig and libfontconfig1, and then removing them. Installation goes
> nicely, but the removal fails, because dpkg removes libfontconfig1 first
> and only after it's done that does it remove fontconfig. Unfortunately,
> fontconfig's maintainer script calls fc-cache (via defoma Perl scripts
> that I don't really understand), which is linked against libfontconfig1
> and therefore fails in the dynamic linker. fontconfig does depend on
> libfontconfig1, so I expected dpkg to remove the packages in the right
> order.

It does remove them in exactly the right order:

Package: libfontconfig1
Depends: ..., fontconfig

See, libfontconfig1 needs to be removed before fontconfig. The order
is completly correct. BUT on the other hand:

Package: fontconfig
Depends: ..., libfontconfig1 (>= 2.3.0), ...

The same goes for fontconfig.

The problem is fontconfig / libfontconfig1. No one else is to
blame. Cyclic depends will be broken at random places and will cause

This exact same cycle has come up in a recent discussion about depends
cycle and I think the proposed solution was to move fc-cache into the
library package and then remove the libfontconfig1 depends fontconfig.
I think. Check for the thread for the full summary.


Reply to: