Re: FTP Installation & Package Naming Conventions
brian white writes ("FTP Installation & Package Naming Conventions "):
> In my work with 'dftp' and in working towards an FTP option to dselect, I've
> come across a few problems with how Debian names its packages.
>
> The general idea of "packages-name-version-revision.deb" works really well
> until people start making exceptions to this. I used the suggestion that
> JimR sent me about generating a list of installed packages using
> "dpkg --list", but found the following anomolies:
>
> [ deleted - iwj ]
> These are all version or revision problems and do not include the package-
> name discrepencies I have mentioned in the past.
>
> All of these are minor differences, but cause siginificant problems when
> trying to get a computer program to correlate packages between an actual
> installation and an FTP site.
I'm not convinced that it's a good idea to try to encode the package
name and version unambiguously into the filename, but I do see that it
would be very convenient.
> I propose we standardize the filenames used in the Debian distribution and
> suggest what I mentioned above:
>
> package-name-version-revision.deb
>
> with the following restrictions:
>
> 1) The package name must not contain any "-<digit>" substrings. This is
> important in order to be able to tell where the name ends and the
> version number starts.
>
> 2) The version number must start with a digit (see #1, above) but may contain
> letters and dashes thereafter.
We should probably enforce this requirement anyway, since any package
name starting with a digit sorts _before_ any package name starting
with another character.
> 3) The revision number must be of the form "-<digits>".
The revision number is going to be phased out as a separate control
file field.
The new situation will be:
* Packages which have an upstream maintainer will contain one or more
`-'s in the version. The component before the last `-' is the
upstream version, and the component after is the revision. The
only distinction between this hyphen and others is that this hyphen
has a slightly different effect on the sorting order.
* Packages which do not will not have any `-'s in the version.
Remember that the revision need not consist entirely of digits. It
may contain full stops and letters, and possibly certain other
punctuation.
Kai Henningsen writes:
> While I prefer numeric versions, that's not that crucial for parsing.
> However, I would strongly suggest using names (and of course revisions)
> without dashes. You can't mandate anything for versions, as those aren't
> choosen by Debian.
As Brian White notes, we need to use a `-' in package names
occasionally.
I think the `-<digit>' rule is probably the best one we can come up
with. Does anyone disagree ?
> However, your list raises another problem - what maximal lenght for the
> three components should be supported? The named clearly had its version
> string truncated.
No, it only looked trunctated in the output from dpkg --list and in
dselect's package listing. This is to avoid making too much of a mess
of the formatting.
I should change this, probably.
There should be no maximum length.
brian white writes ("Re: FTP Installation & Package Naming Conventions "):
> Also, while the versions are not choosen by Debian, the format in which
> they are written could be. It really makes little difference whether it
> is called "bison-A2.5-0.deb" or "bison-2.5A-0.deb".
The sorting implications are very different, and this is important
because dpkg and dselect can be reluctant to downgrade packages.
Ian.
Reply to: