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

Re: Depends vs. Pre-Depends



On Sun, May 02, 1999 at 08:23:26AM -0700, Tonnesen Steve wrote:
> 
> I am developing a package which uses a Mysql database.  I would like to
> create the database and populate it with some data during the postinst
> script.  If I add the following Dependencies:
> 
> Depends: mysql-server
> Depends: libdbd-mysql-perl
> Depends: libdbi-perl
> 
> Can I be certain that Mysql and DBD/DBI will be installed and configured
> before my postinst script runs?  If I can't, would it be better to bomb
> out of my postinst script until the next run, or use a Pre-Depends?

Depends are resolved before the postinst is run. Pre-Depends are resolved even
before the package is unpacked. Pre-Depends should be used if it would break
the system otherwise. Think of a new bash which requires another library -
after unpacking your old bash is gone and the new one will not run.

As a side effect you will probably be unable to install any new packages
because most {pre,post}inst-scripts use sh which is linked to /bin/bash
normally...

cu
    Torsten

Attachment: pgp_rh3a8MIwj.pgp
Description: PGP signature


Reply to: