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

Re: Advice requested with tricky dependencies in records.deb



On Sun, Oct 28, 2001 at 08:53:58PM +0200, Tommi Virtanen wrote:
> 	Eww. And it was worse before I noticed most XEmacsen provide
> 	xemacs21, and GNU Emacsen provide emacsNN or mule2. To ease
> 	parsing, read that as
> 
>         perl5 AND (
>                 ($GNU_Emacs AND mailcrypt) 
>                 OR $XEmacs
>         )
> 
> 	This is just something the dependency system can't express. 
> 	The current package approximates that with

Actually (as others have noted), the dependency system can express
it just fine.  Unfortunately that doesn't help, because the problem
is already present in your expression.  Consider that the combination
perl5 + $GNU_Emacs + $XEmacs does satisfy it, while your point is
that it shouldn't.

What you need to express is that $GNU_Emacs IMPLIES mailcrypt, regardless
of the status of $XEmacs.  And for that you need negations, which our
dependency system can not express.  The Conflicts line is a kind
of negation, but it is too limited for this purpose.

But if you look at it another way, such a dependency would be too
strong.  Suppose a user has perl5 + $GNU_Emacs + $XEmacs, and no
mailcrypt package.  This user might want to install the records
package in order to use it with $XEmacs, and have no interest in
using it with $GNU_Emacs.  The exact dependency (which we can't
achieve) would force that user to install mailcrypt anyway.

Therefore, the solution I recommend is to capture your original
expression in the Dependency line, and arrange the package so
that it is only compiled for $GNU_Emacs if mailcrypt is installed.
There's no need to fail if there's no mailcrypt, because the package
can still be used with $XEmacs.

The main problem with this solution is that if the user later
installs mailcrypt, nothing will trigger the recompilation of
records.  Perhaps mailcrypt could include a hook for that.

Richard Braakman



Reply to: