sasquatch icon indicating copy to clipboard operation
sasquatch copied to clipboard

The patch doesn't apply to squashfs-tools-4.4

Open morfikov opened this issue 5 years ago • 2 comments

Is there any chance to fix the patch so it would be applied to squashfs-tools-4.4 ?

morfikov avatar Apr 12 '20 13:04 morfikov

One of the issues that would need to be solved for this is the conflicting compression algorithm identifiers in squashfs-tools/squashfs_fs.h.

sasquatch 4.3:

#define LZ4_COMPRESSION		5
// CJH: Added #defines for additional decompressors
#define LZMA_WRT_COMPRESSION        6
#define LZMA_ADAPTIVE_COMPRESSION   7
#define LZMA_ALT_COMPRESSION        8

squashfs-tools 4.4:

#define LZ4_COMPRESSION		5
#define ZSTD_COMPRESSION	6

You'd probably either have to try to remove zstd support from squashfs-tools 4.4 by reverting commit 6113361316, or (preferably) introduce additional code that allows end-users to switch between supporting lzma_wrt and zstd at runtime.

hardfalcon avatar Jan 04 '21 15:01 hardfalcon

I tried my hand at updating the patch in https://github.com/devttys0/sasquatch/pull/40. WRT to the #define LZMA_* stuff, I just adjusted the index by 1 -- is there any obvious reason why this wouldn't be satisfactory? e.g. would it break interacting with squashfs-tools-4.3 stuff? (I'm wholly unfamiliar with this patch.)

cole-h avatar Apr 17 '21 17:04 cole-h