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

dpkg 1.1.0: Pre-Depends



I have implemented Pre-Depends in dpkg.  The semantics are exactly the
same as those for an ordinary Depends, with one additional feature:
dpkg will refuse to unpack if the Pre-Depends is not satisfied.  For
this check it is not necessary for the depended-on package to be
configured; however, the depended-on package must be at least unpacked
and must have been configured before, and in this case both the
currently-unpacked and the most-recently-configured versions must
satisfy any version restriction in the pre-dependency.

In dselect I hope to be able to arrange for at least some of the
installation methods to find which packages need to be unpacked first,
and to install them first and in the right order.  I'm still
considering how to do this.

There is now a new dpkg option, --assert-support-predepends.  All
packages which have a Pre-Depends line should invoke
 dpkg --assert-support-predepends
in their preinst script, and should stop if the command fails.

It may fail with exit status 2 and produce a usage message to stderr,
indicating that /usr/bin/dpkg is too old to understand it.  It may
also fail with exit status 1 and produce a message to stdout, saying
why the situation is not satisfactory (this can happen, for example,
if dpkg itself has been unpacked but not configured, which would be
the case if the version of dpkg which was running the installation was
still the old version which didn't support Pre-Depends, but the new
version had already been unpacked).  Any other errors (bad status
databases, &c) will give exit status 2.

If dpkg --assert-support-predepends succeeds it will not produce any
output.

Future enhancements to dpkg which need to be tested before
installation can make use of the Pre-Depends option.

This dpkg is a.out, but should go in the devel tree.

dpkg (1.1.0); priority=LOW

  * dpkg supports Pre-Depends.
  * postinst script gets most-recently-configured version as $2.

  * lib/tarfn.c #includes <errno.h> (portability fix).

 -- Ian Jackson <iwj10@cus.cam.ac.uk>  Sun, 11 Feb 1996 21:07:03 +0000

c38f57844c384cbb67ba6f1630d30f58  dpkg-1.1.0.deb
aa98a6a811672a4bec87c879852286cf  dpkg-1.1.0.nondebbin.tar.gz
5925d6f1fab6b76fa6116c3f9de9bf40  dpkg-1.1.0.tar.gz
-rw-r--r--   1 root     ian        239740 Feb 11 21:29 dpkg-1.1.0.deb
-rw-rw-r--   1 root     ian        235434 Feb 11 21:28 dpkg-1.1.0.nondebbin.tar.gz
-rw-rw-r--   1 ian      ian        289156 Feb 11 21:07 dpkg-1.1.0.tar.gz


Reply to: