On Fri, May 12, 2006 at 05:46:34PM +0200, Jörg Sommer wrote:
> Debian Bug Tracking System schrieb am Wed 10. May, 12:48 (-0700):
> > From: Marcin Owsiany <[EMAIL PROTECTED]>
> > To: [EMAIL PROTECTED]
> > Subject: Re: Bug#366616: cruft: Don't report .pyc and .pyo files if a .py 
> > file exist
> > Date: Wed, 10 May 2006 20:34:07 +0100
> > User-Agent: Mutt/1.5.11+cvs20060403
> > 
> > Version: 0.9.6-0.11
> > 
> > On Tue, May 09, 2006 at 06:50:01PM +0200, Jörg Sommer wrote:
> > > files ending with .pyc or .pyo are OK if a file the the ending .py exist.
> > 
> > Only if the package containing them calls compileall.py in postinst or
> > similar. Since this is package-dependant, it should be added to the
> > package's explain script.
> 
> Why is this package dependent? Why not look in
> /var/lib/dpkg/info/$pkg.postint for the strings "Automatically added by
> dh_python" and "compileall.py" and if they are found you accept all
> .pyo and .pyc files in the directories enumerated in DIRLIST

This would be quite fragile design. Actually that way would not work any
more even now, since e.g. pycentral (and there is one more tool, can't
remember its name) has taken over the role of dh_python.

> > In fact cruft already does that for five packages, thus closing this
> > bug.
> 
> This isn't a really generic way and I'm sure it can be done in a more
> generic way that makes it obsolete to have for every package a special
> file.

I think ultimately the right way would be to have the python helper
generate a cruft filter file as well, either during build or perhaps at
runtime.

This bug still applies in a more general sense, though. In that there is
no mechanism in place to provide filters/explanations for very similar
issues in different packages. The python compilation is just one example
of this. I'm going to retitle this bug.

Marcin
-- 
Marcin Owsiany <[EMAIL PROTECTED]>             http://marcin.owsiany.pl/
GnuPG: 1024D/60F41216  FE67 DA2D 0ACA FC5E 3F75  D6F6 3A0D 8AA0 60F4 1216


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to