$ size /usr/lib/i386-linux-gnu/libzstd.so.1.3.3
text data bss dec hex filename
508674 492 20 509186 7c502 /usr/lib/i386-linux-gnu/libzstd.so.1.3.3
Yikes; half a meg of code!Say I just want something in my C program for saving certain files using less space, and only care about decompressing only those files. Is there some small implementation of a subset of Zstandard: say no more than four or five source files, and 64K of machine code?
If I add 500K to the program, I'm going to have to save 500K by compressing the accompanying files, just to begin breaking even.
For comparison, libz may not have the decompression speed or the ratio, but it's more than four times smaller:
$ size /lib/i386-linux-gnu/libz.so.1.2.11
text data bss dec hex filename
115537 588 4 116129 1c5a1 /lib/i386-linux-gnu/libz.so.1.2.11
This is more like it! $ size /lib/i386-linux-gnu/libbz2.so.1.0.4
text data bss dec hex filename
60511 3520 4 64035 fa23 /lib/i386-linux-gnu/libbz2.so.1.0.4
Text 60511. Is there some configuration of Zstandard which can cram into comparable code space?