pepe2k / u-boot_mod

U-Boot 1.1.4 modification for routers

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add Gzip support

ramponis opened this issue · comments

Is it possibile to add gzip compression to u-boot?
I have some gzip compressed image and i want to test on a TL-WDR3600

Thank you

No. LZMA is superior to GZIP. What's so interesting about this image?

Yes i know LZMA is superior... but i want to test some images compressed with GZIP.
I don't have the sources to recompile the image with LZMA compression

That's likely a GPL violation. Ask the person you've got the image from where the source-code is available.

As far as I know you can also just extract the image with binwalk -e and repack it with OpenWrt's mkimage to LZMA. Please ask in the OpenWrt forum for help for that.

You can also add GZIP support yourself to U-Boot_Mod, but don't expect someone to help you, because GZIP compression was removed by purpose. Not only is GZIP compression inferior, but you would also need the decompressor which increases the size of the U-Boot.
Look e.g. at these lines

static char *ih_comp_type(uint8_t comp)

You see the GZIP cases were commented or removed everywhere, but you could introduce a new build flag for switching between compression methods.