myfreeer / chrome-pak-customizer

a simple command-line tool to pack and unpack pak files in chrome or chromium-based browser
MIT License
205 stars 36 forks source link

Does binary size matter #13

Closed myfreeer closed 2 years ago

myfreeer commented 2 years ago

Chromium started using a custom variant or brotli compression to compress resources inside pak file. Unpacking this would be simple, detect the binary prefix and strip 8 bytes makes it compatible with brotli utils, but packing would be difficult even if with brotli-compressed file.

The prefix contains uncompressed size of brotli stream, which, according to official issue, can not be obtained without uncompressing it, but incroducing a brotli uncompressor would make binary size of the program many times larger than current.

Binary size matters from the very beginning of the C version of this tool, but since it's years from last release, things might change.

Click Up on the upper right corner for perfering to keep its current status and small binary size. Click Downon the upper right corner for perfering to introduce the feature even if binary size could be more than 1MB.

myfreeer commented 2 years ago

Assuming this does not matter now.