[arch-dev-public] [PATCH] Support xz compressed packages

Aaron Griffin aaronmgriffin at gmail.com
Mon Feb 15 16:33:07 EST 2010


On Mon, Feb 15, 2010 at 3:10 PM, Pierre Schmitz <pierre at archlinux.de> wrote:
> Am Montag, 15. Februar 2010 19:26:59 schrieb Aaron Griffin:
>> I 100% agree with Thomas. Saying we "won't ever need it" is assuming
>> that xz is the ultimate compression algorithm and nothing will ever be
>> better. A year from now "zz compression" might come out and be
>> awesome. Now we'd have to repeat this entire process for the zz
>> algorithm.
>>
>> Being flexible isn't about supporting old stuff - it's about supporting
>> new.
>
> I don't get it. I am not talking about making it impossible to add support for
> this for ever. It just about implementing only that what we need right now.
>
> Well, I can just place *.pkg.tar.* everywhere, but the point I didn't want it
> that much is that it is not safe for the case where this pattern might match
> more than one file. So this patch was the most easiest and less intrusive
> approach I could think of. I know that we should rewrite the whole stuff in
> future. But this way we can start using xz right now and we wont loose any
> flexibility in future.
>
> So, why don't we add this and use it for a while instead? We can alter the
> scripts anytime later if needed.
>
> Another question: Do we really want to have all kinds of random compressions
> for packages in our repo or should we agree on one towards which we migrate
> step by step? This wont be a problem if we had a dedicated file name extension
> but this way everybody will just be confused.

My big concern here is that this is a much bigger question than it
seems. "Here's a patch that makes us switch to xz compression" isn't
the same as "Do you guys think we should switch to xz compression
completely?". It seems to be jumping the gun a little bit, but I could
be mistaken

So... let's start from there:
Is everyone ok with ONLY allowing xz compressed packages into the repo
going forward? gz packages will no longer work with this change.

I, for one, don't have an issue with "all kinds of random
compressions" because there's really only like 4 or 5 we'd use. And
it's transparent to everyone who is not looking at a list of files.

As for actual changes to support that, setting PKGEXT=".pkg.tar.*"
would require only minor changes to these lines:
$ grep -rn PKGEXT *
cron-jobs/sourceballs:54:            srcpkg="${pkg//$PKGEXT/$SRCEXT}"
db-move:61:        _pkgfile="$i-$pkgver-$pkgrel-$_arch$PKGEXT"
db-move:103:			_pkgfile="$i-$pkgver-$pkgrel-$_arch$PKGEXT"
db-move:110:            _pkgfile="$i-$pkgver-$pkgrel-$_arch$PKGEXT"
db-update:118:				if [ "$_pkgfile" =
"$_pkgname-$pkgver-$pkgrel-any$PKGEXT" ]; then
db-update:189:						if [ "$_pkgfile" =
"$_pkgname-$pkgver-$pkgrel-$current_arch$PKGEXT" ]; then
misc-scripts/ftpdir-cleanup:54:    [ -z "${filename}" ] &&
filename="${pkg}${PKGEXT}"

Note that I think the sourceballs line might actually work...


More information about the arch-dev-public mailing list