project: Add new compression options
Add support for compressing the uniLoader image with lz4, and while we're at it add two new Kconfig variables for setting compression tools used in the build.
This commit is contained in:
1 parent
759bc09d8f
commit
ac9b574b27
2 files changed
+21
No files matched your search
@@ -19,6 +19,19 @@ menu "Building options"
|
||||
int "Verbosity of logs"
|
||||
default 7
|
||||
|
||||
config COMPRESS_GZIP
|
||||
bool "Compress the uniLoader image with gzip"
|
||||
default y
|
||||
help
|
||||
Select this if you want to use gzip to compress the final uniLoader image.
|
||||
|
||||
config COMPRESS_LZ4
|
||||
bool "Compress the uniLoader image with lz4"
|
||||
default n
|
||||
help
|
||||
Select this if you want to use lz4 to compress the final uniLoader image.
|
||||
This is required on some new MediaTek devices.
|
||||
|
||||
config EMBED_LINUX
|
||||
bool "Embed linux kernel and device tree"
|
||||
default y
|
||||
|
||||
@@ -399,10 +399,18 @@ quiet_cmd_uniloader_objcopy = OBJCOPY $@
|
||||
quiet_cmd_gzip_uniloader = GZIP $@.gz
|
||||
cmd_gzip_uniloader = gzip -c uniLoader > uniLoader.gz
|
||||
|
||||
quiet_cmd_lz4_uniloader = LZ4 $@.lz4
|
||||
cmd_lz4_uniloader = lz4 uniLoader -l -f -q
|
||||
|
||||
uniLoader: $(uniloader-all) arch/$(ARCH)/linker.lds FORCE
|
||||
$(call if_changed,uniloader_link)
|
||||
$(call if_changed,uniloader_objcopy)
|
||||
ifdef CONFIG_COMPRESS_GZIP
|
||||
$(call if_changed,gzip_uniloader)
|
||||
endif
|
||||
ifdef CONFIG_COMPRESS_LZ4
|
||||
$(call if_changed,lz4_uniloader)
|
||||
endif
|
||||
|
||||
# The actual objects are generated when descending,
|
||||
# make sure no implicit rule kicks in
|
||||
|
||||
Reference in new issue
Block a user