Debian Developers - On bz2 compression in debs

This is Interesting: Free IT Magazines  
Home > Archive > Debian Developers > August 2007 > On bz2 compression in debs





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author On bz2 compression in debs
Romain Francoise

2007-08-19, 1:24 pm

Hi,

In the past few days I've been making random tests on the whole
archive, and found two binary packages that my tools couldn't handle
because they use bz2 compression of the data tarball.

That is to say, they don't have the data.tar.gz member but have a
data.tar.bz2 member instead. This format has been supported by dpkg
since 2004, and can be enabled by passing the '-Z bzip2' option to
dpkg-deb (usually via dh_builddeb). The two packages are
doc-linux-html and doc-linux-nonfree-html:

$ ar t doc-linux-html_2007.08-2_all.deb
debian-binary
control.tar.gz
data.tar.bz2
$ dpkg -I doc-linux-html_2007.08-2_all.deb | head -1
new debian package, version 2.0.
$

I'm trying to determine if this is policy compliant. Policy has the
following to say about the .deb format:

| B. Binary packages (from old Packaging Manual)
| ----------------------------------------------
|
| The binary package has two main sections. The first part consists of
| various control information files and scripts used by `dpkg' when
| installing and removing. See Section B.2, `Package control
| information files'.
|
| The second part is an archive containing the files and directories to
| be installed.
|
| In the future binary packages may also contain other components, such
| as checksums and digital signatures. The format for the archive is
| described in full in the `deb(5)' man page.

and deb(5) says:

| The third, last required member is named data.tar.gz. It contains
| the filesystem archive as a gzipped tar archive.

Note 'required'.

So my questions are:

1) If deb(5) is authoritative, am I right in thinking that bz2
compression is a policy violation at the moment?

2) Doesn't the disappearance of 'data.tar.gz' warrant a bump of the
binary version number, from 2.0 to, say, 3.0?

See also:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=34727
http://lists.debian.org/debian-deve...0/msg02053.html
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=438486

Thanks for any insight,

--
,''`.
: :' : Romain Francoise <rfrancoise@debian.org>
`. `' http://people.debian.org/~rfrancoise/
`-


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Felipe Sateler

2007-08-19, 7:25 pm

Romain Francoise wrote:

> 2) Doesn't the disappearance of 'data.tar.gz' warrant a bump of the
> binary version number, from 2.0 to, say, 3.0?


> http://lists.debian.org/debian-deve...0/msg02053.html


The above link says it should be 3.0 for bz2 compressed binary debs:

> Dpkg-deb will also automatically detect the compression type when
> unpacking the .deb. Note that the new .bz2 format will have a package
> format version of "3.0" so that older dpkg's that don't support this will
> give and error to the affect of "you need a newer dpkg" (for some reason a
> major version increase is needed for this to happen).



--

Felipe Sateler


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Romain Francoise

2007-08-22, 1:25 am

Felipe Sateler <fsateler@gmail.com> writes:

[vbcol=seagreen]
> The above link says it should be 3.0 for bz2 compressed binary debs:


I know, that's why I mentioned it. But it's from 1999.

--
,''`.
: :' : Romain Francoise <rfrancoise@debian.org>
`. `' http://people.debian.org/~rfrancoise/
`-


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Goswin von Brederlow

2007-08-24, 1:26 pm

Romain Francoise <rfrancoise@debian.org> writes:

> So my questions are:
>
> 1) If deb(5) is authoritative, am I right in thinking that bz2
> compression is a policy violation at the moment?


Yes and no. deb(5) is authorative but out of sync with the
implementation imho.

> 2) Doesn't the disappearance of 'data.tar.gz' warrant a bump of the
> binary version number, from 2.0 to, say, 3.0?


That sounds indeed like a bug. dpkg-deb bug?

MfG
Goswin


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Ian Jackson

2007-08-24, 7:19 pm

I'm not sure if I really want to get into the bz2-vs-gz argument again
but there is a question here that's easy to answer:

Romain Francoise writes ("On bz2 compression in debs"):
> 2) Doesn't the disappearance of 'data.tar.gz' warrant a bump of the
> binary version number, from 2.0 to, say, 3.0?


No.

The purpose of the version number is to ensure that a .deb which is
apparently compatible but actually incompatible would be rejected.

A naive program which processes a .deb with a data.tar.bz2 instead of
a data.tar.gz will fail if it needs the filesystem archive, just as it
would if the version number were bumped. But not all programs need
the filesystem archive and those which only need metadata ought not to
be broken by bumping the version number.

Ian.


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com