Skip to content.
The Debian System -- Concepts and Techniques The Debian System -- Concepts and Techniques
Martin F. Krafft Open Source Press / No Starch Press ISBN 3-937514-07-4 / 1-593270-69-0
Personal tools

Bad versioning scheme for pre-release versions (page 218)

Document Actions

Reported on: 2006-02-01

In chapter 5. The Debian package management system on page 218:

The versioning scheme for pre-release upstream  versions proposed in section 5.7.5 is not desirable: encoding the pre-release version in the Debian revision prevents a new orig.tar.gz file from being uploaded when the final release is uploaded.

The following rewrite should make the situation clear. It replaces the second half of the middle paragraphon page 218, starting at "Within the Debian archive, it is customary...":

One scheme could be to release 1.0-rc1 as 1.0-0+1.0rc1+1, followed by 1.0-0+1.0rc1+2, and then 1.0-1 when the final gets released. However, this approach has an inherent problem: for each upstream version, an orig.tar.gz file exists in the Debian archive; Debian revisions are released as diff.gz files against the orig.tar.gz file (see chapter 9.2.12). In the proposed scheme, the orig.tar.gz file will contain the 1.0-rc1 upstream release, and when the final 1.0 release is to be packaged, the diff.gz file for the 1.0-1 Debian release will have to encompass all upstream changes between 1.0-rc1 and 1.0 as well, which is undesirable.

Thus, a better approach is to encode the pre-release version as part of the upstream vesion. This can be done in one of two ways: using the previous upstream version as base (let's assume 0.90), or an obviously fake upstream version that sorts before the final release: 0.90+1.0rc1-1 or 0.999+1.0rc1-1. Now, upon release of 1.0, a new orig.tar.gz file can be uploaded to replace the previous one. With that in mind, it should be easy to infer the upstream version number from the Debian version, even in complex cases.


Gerfried Fuchs

Ladislav Bodnar, Distrowatch: I have always enjoyed computer books [...] The Debian System - Concepts And Techniques will go down as one of the greatest of them all - the one that I will certainly keep on the table for a long time before I put it up on the shelf, but even then, it will never be far from reach. An absolute must for all users of Debian and Debian derivatives, and a proud addition to any Linux user's book collection. Highly recommended.


Powered by Plone

This site conforms to the following standards: