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

Re: mucking with dpkg control files in maintainer scripts?

Goswin von Brederlow <brederlo@informatik.uni-tuebingen.de> wrote:

> Tollef Fog Heen <tfheen@err.no> writes:
>> * sean finney 
>> | is this even remotely acceptable?  i had the impressions that packages
>> | must not assume the inner workings of dpkg.  but, i can't back this up
>> | with anything in policy from what i can tell, hence the posting of
>> | this question.
>> Before responding, please read the bug report (390823) mentioned in
>> the changelog.  Oh, and if we deem this unacceptable, please do
>> suggest a different way and file bugs on a lot of the archive,
>> including all doing stuff like:
>> [...]
>>         old_md5sum="`sed -n -e \"/^Conffiles:/,/^[^ ]/{\\\\' $CONFFILE'{s/.* //;p}}\" /var/lib/dpkg/status`"
>> [...]
> I think this is different from messing with the maintainer
> scripts. But none the less I think a better way for this would be to
> call 'dpkg -s package'.

I think the main reason why this is not being done is that there's a
general fear that calling "dpkg -s" from a script that has been called
by dpkg might give unpredictable, or at least not the desired results.

If it were documented how dpkg behaves under such circumstances (same
for "dpkg -l"), people might be willing to change this.

Regards, Frank
Dr. Frank Küster
Single Molecule Spectroscopy, Protein Folding @ Inst. f. Biochemie, Univ. Zürich
Debian Developer (teTeX/TeXLive)

Reply to: