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

Re: dkms needs a pre-depends entry (Policy 3.5)

On Tue, Jul 20, 2010 at 12:02:48PM -0700, Russ Allbery wrote:
> The problem here is that the package that's being triggered isn't either
> of the packages that are involved, I believe.  The package being triggered
> is python-support, which is a dependency of lsb-release, but the package
> failing is dkms, which has no dependency on python-support, only on
> lsb-release.  What's happening, as I understand it, is:

> * nvidia-kernel-dkms is requested to be installed.
> * dkms is added due to dependency.
> * lsb-release is added due to dkms dependency.
> * python-support is already installed.
> * lsb-release, dkms, and nvidia-kernel-dkms are unpacked.
> * Pending trigger added for python-support.
> * lsb-release is configured.
>      <== does this force python-support's trigger to run?
> * dkms is configured.
> * nvidia-kernel-dkms is configured and attempts to build the module.

> Now, this was definitely broken before because dkms only recommended
> lsb-release and didn't depend on it.  But does this work properly if
> there's an actual dependency?

> Right now, it's pre-depending, it looks like, which should be too strong
> and not required.

> So, nvidia-kernel-dkms's postinst shouldn't run until all of its
> dependencies are configured, so I think my question is: does dpkg wait to
> call the postinst of nvidia-kernel-dkms until after python-support's
> trigger runs, when python-support is a dependency of lsb-release and
> lsb-release is in turn a dependency of dkms, which is a dependency of
> nvidia-kernel-dkms?

As Ian has described it, yes:  lsb-release is not "installed" until after
the python-support trigger is run, so dpkg will run that trigger before
trying to move up the stack and configure dkms.  And since dkms is not yet
configured, nvidia-kernel-dkms won't be configured either.

The only exceptions would be a bug in dpkg trigger support, or a bug in a
higher level package manager passing --force-depends to dpkg.

Steve Langasek                   Give me a lever long enough and a Free OS
Debian Developer                   to set it on, and I can move the world.
Ubuntu Developer                                    http://www.debian.org/
slangasek@ubuntu.com                                     vorlon@debian.org

Attachment: signature.asc
Description: Digital signature

Reply to: