wok-6.x diff busybox/stuff/busybox-1.31-zmodules.u @ rev 23065
miro: update for ffmpeg
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Mon Mar 09 18:50:16 2020 +0100 (2020-03-09) |
parents | |
children |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/busybox/stuff/busybox-1.31-zmodules.u Mon Mar 09 18:50:16 2020 +0100 1.3 @@ -0,0 +1,27 @@ 1.4 +Add LZMA_DEFAULT_MAGIC support 1.5 +--- busybox-1.31/archival/libarchive/open_transformer.c 1.6 ++++ busybox-1.31/archival/libarchive/open_transformer.c 1.7 +@@ -168,6 +168,23 @@ 1.8 + * unpack_XXX_stream wants this header skipped. */ 1.9 + xstate->signature_skipped = 2; 1.10 + xread(fd, xstate->magic.b16, 2); 1.11 ++#if 1 1.12 ++// SliTaz may use .gz suffix for lzma'd kernel modules 1.13 ++#if BB_BIG_ENDIAN 1.14 ++#define LZMA_DEFAULT_MAGIC 0x5d00 1.15 ++#else 1.16 ++#define LZMA_DEFAULT_MAGIC 0x5d 1.17 ++#endif 1.18 ++ if (ENABLE_FEATURE_SEAMLESS_LZMA 1.19 ++ && xstate->magic.b16[0] == LZMA_DEFAULT_MAGIC 1.20 ++ ) { 1.21 ++ xlseek(fd, -xstate->signature_skipped, SEEK_CUR); 1.22 ++ xstate->signature_skipped = 0; 1.23 ++ xstate->xformer = unpack_lzma_stream; 1.24 ++ USE_FOR_NOMMU(xstate->xformer_prog = "unlzma";) 1.25 ++ goto found_magic; 1.26 ++ } 1.27 ++#endif 1.28 + if (ENABLE_FEATURE_SEAMLESS_GZ 1.29 + && xstate->magic.b16[0] == GZIP_MAGIC 1.30 + ) {