Z compression not yet supported (Was: mk-origtargz)

Andreas Tille tille at debian.org
Wed May 14 09:03:26 UTC 2014


Hi Joachim,

On Wed, May 14, 2014 at 09:25:32AM +0200, Joachim Breitner wrote:
> > > If it's the latter, then I'm fine with adding it.  I doubt libdpkg-perl
> > > will accept a patch for it though since that's not a valid compressor
> > > for Debian packages.
> 
> we could still ask. If not, we should simply copy the Dpkg::Compression
> to Devscripts::Compression; the module is not very large and we already
> add a new method in Devscripts::Compression.

When trying to prepare a patch for scripts/Dpkg/Compression.pm I think we
get a problem since it seems an implementation of /usr/bin/compress is
lacking in Debian.  While you can uncompress .Z files via gunzip I have
no idea how to fill in the '?' in the following snippet:

    Z => {
	file_ext => 'Z',
	comp_prog => [ '???' ],
	decomp_prog => [ 'gunzip' ],
        default_level => ?,
    },

In other words: I somehow doubt that dpkg developers will be motivated
to inject something that is not used by dpkg and does not even follow
their intended scheme.

> > I have no idea about the role of Dpkg/Compression.pm - but .Z is
> > definitely a compression which is used in the UNIX world.  Do you think
> > it makes more sense to use something like
> > 
> >    if ( $comp =~ /Z/ ) {
> >       # handle Z compression manually
> >    } else {
> >       # current code
> >    }
> > 
> > to work around the fact that Debian packages are not using this?
> 
> I’d rather not have such work-arounds cluttered through the code.
> Copying the code from Dpkg::Compression would be cleaner.

For sure.  Considering what I wrote above may be we should really use a
code copy - even if this will leave us with inventing workarounds for
'comp_prog' and 'default_level'.  I have no idea how a clean solution
might look like.  I just would consider it quite handy to deal with *.Z
files by plain uscan without beeing forced to write a manual
get-orig-tar target.

Kind regards

      Andreas. 

-- 
http://fam-tille.de



More information about the devscripts-devel mailing list