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

Re: dpkg rewrite in Java



Ben Collins <bcollins@debian.org> writes:

> On Sun, Apr 25, 2004 at 09:33:48PM -0700, Tobias Hertkorn wrote:
>> Hi community!
>> 
>> I am currently starting to rewrite parts of the dpkg functionality in
>> Java (For startes the dpkg --info part and a package list parser). I
>> need this for my senior programming project apt-got[1,2], which is a
>> partial mirror application that focuses as a subproject on Debian
>> archives.
>> 
>> My question is: Is there a complete specification of the Debian
>> package list. I especially need information on what situations are
>> possible. (Eg. can you have 2 different versions of the same package
>> in one list?) Are there any further restrictions? Is there a specific
>> set of keyword in one package information or is it supposed to be
>> extendable?

You can have multiple packages and even multiple archs in the Packages
file. There is a specific set of keaywords that will always be present
because the debs must have them but you can specify extra keywords as
long as they are rfc822 conform.

Given Maintainer names in UTF-8 you even get some violations of
rfc-822 format in there too.

Your parser should be as flexible as possible and has to handle even
maliciously broken Packages files. Recovering nicely after a broken
Package entry is a big plus but you could error on it too.

>> I think I already figured out how to extract the information from
>> Debian packages directly, but would be glad about any (_very_
>> detailed) information about Debian packages.

Reading rfc-822, after which the Packages file are modelled, would be
a good start. And then the policy manual, maintainer guide and so on
to see what deb files have in their control files.

>> Please cc me, as I am not subscribed to the mailing list.
>
> man deb
> man deb-control

And of cause those too. :)

MfG
        Goswin

PS: you might even want to support pkg:abi or {abi} for multiarch
support. Check on the progress on multiarch on debian-amd64.



Reply to: