all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Publishing with Lzip
@ 2019-03-10 18:24 Pierre Neidhardt
  2019-03-12 13:19 ` Ludovic Courtès
  0 siblings, 1 reply; 5+ messages in thread
From: Pierre Neidhardt @ 2019-03-10 18:24 UTC (permalink / raw)
  To: guix-devel

[-- Attachment #1: Type: text/plain, Size: 1694 bytes --]

Hi,

I've just sent a patch of a first draft for the Lzip bindings:

  http://debbugs.gnu.org/cgi/bugreport.cgi?bug=34807

Switching from Gzip (Zlib) to Lzip would save up to some 50% disk usage
for substitutes which would greatly benefit the servers and help
reducing the bandwidth usage.

A few things are missing in the patch and I would probably need some help:

- The %liblz variable in guix/config.scm.in is not set dynamically by
  autoconf.
  This is because lzlib does not have a pkg-config entry.  I don't know
  much about autoconf, so if someone knows how to do this properly...

- I'm still a bit confused about how the API is supposed to work.  There
  is a lz-(de)compress-finish function which is supposed to be called
  according to the examples but the manual does not really says why.  If
  I call it, the tests fail.

- I'm also not 100% I'm doing the right thing with the encoder/decoder:
  should we write everything first, then read as much as we can?  Or
  chain write-read calls like in bbexample.c?

- I'm not 100% sure either that the terminating chunk will always be
  compressed / decompressed.  (It works in the test though.)  I don't
  really understand how Lzlib handles that part.

- How can I map between C enums and Guile with dynamic FFI?  This would
  be useful to have improve error messages.

- lzlib.scm is not used for publishing in the patch.  Will do that
  later.  What are the strategies for transitioning from .gz to .lz?  I
  suggest the following:

  - On publishing, replace .gz with .lz compression.
  - When extracting, check the type and call the appropriate format decompressor.

Feedback welcome!

--
Pierre Neidhardt
https://ambrevar.xyz/

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-03-13 15:41 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-10 18:24 Publishing with Lzip Pierre Neidhardt
2019-03-12 13:19 ` Ludovic Courtès
2019-03-12 13:39   ` Pierre Neidhardt
2019-03-13 14:43     ` Ludovic Courtès
2019-03-13 15:31       ` Pierre Neidhardt

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.