libostree: Allow compression level to be set for archive-z2 stream

Add a ostree_raw_file_to_archive_z2_stream_with_options() variant of
ostree_raw_file_to_archive_z2_stream(), to allow a compression-level
option to be passed in and passed through to zlib.

This is useful when building archive-z2 files on the fly for
transmission over a non-bandwidth-limited channel, such as a local
network. In this case, CPU time is more valuable than bandwidth, so we
want a low compression level.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

Closes: #721
Approved by: cgwalters
This commit is contained in:
Philip Withnall authored and Atomic Bot committed 2017-03-06 18:19:45 +00:00
1 parent 72336f1c48
commit 574c3ea6f9
4 files changed
+53 -4

No files matched your search

+2 -4
View File
@@ -381,12 +381,10 @@ global:
* NOTE NOTE NOTE
*/
/* Uncomment this when adding the first new symbol for 2
LIBOSTREE_2017.XX {
LIBOSTREE_2017.3 {
global:
someostree_symbol_deleteme;
ostree_raw_file_to_archive_z2_stream_with_options;
} LIBOSTREE_2017.2;
*/
/* Stub section for the stable release *after* this development one; don't
* edit this other than to update the last number. This is just a copy/paste