summaryrefslogtreecommitdiffstats
path: root/common/Kconfig
diff options
context:
space:
mode:
authorJean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>2011-12-31 16:11:12 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2012-01-02 11:47:49 +0100
commit26927bafde8b1757a42ed3425cc8804207f85318 (patch)
treef033c1ff7ea3f4ddc66e1780fc096fded1598507 /common/Kconfig
parentb74f8dd81df40abc67200c33073a404c496b4626 (diff)
downloadbarebox-26927bafde8b1757a42ed3425cc8804207f85318.tar.gz
barebox-26927bafde8b1757a42ed3425cc8804207f85318.tar.xz
defaultenv: use a compressed version when embedded in barebox
enable it only if a compression is enabled support gzip, bzip2 and lzo you will be able to choose which compression to use -rw-r--r-- 1 root root 8436 Dec 15 01:35 barebox_default_env -rw-r--r-- 1 root root 2782 Dec 15 01:35 barebox_default_env.bz2 -rw-r--r-- 1 root root 2691 Dec 15 01:38 barebox_default_env.gz -rw-r--r-- 1 root root 3262 Dec 15 01:38 barebox_default_env.lzo with using gzip and the default env we can save 5.6KiB (5,745 bytes) with using bzip2 and the default env we can save 5.5KiB (5,654 bytes) with using lzo and the default env we can save 5.1KiB (5,174 bytes) Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'common/Kconfig')
-rw-r--r--common/Kconfig28
1 files changed, 28 insertions, 0 deletions
diff --git a/common/Kconfig b/common/Kconfig
index f8df3dd358..ca4f09922c 100644
--- a/common/Kconfig
+++ b/common/Kconfig
@@ -427,6 +427,34 @@ config DEFAULT_ENVIRONMENT
Enabling this option will give you a default environment when
the environment found in the environment sector is invalid
+config DEFAULT_ENVIRONMENT_COMPRESSED
+ bool
+ depends on DEFAULT_ENVIRONMENT
+ default y if ZLIB
+ default y if BZLIB
+ default y if LZO_DECOMPRESS
+
+if DEFAULT_ENVIRONMENT_COMPRESSED
+
+choice
+ prompt "compression"
+
+config DEFAULT_ENVIRONMENT_COMPRESSED_GZIP
+ bool "gzip"
+ depends on ZLIB
+
+config DEFAULT_ENVIRONMENT_COMPRESSED_BZIP2
+ bool "bzip2"
+ depends on BZLIB
+
+config DEFAULT_ENVIRONMENT_COMPRESSED_LZO
+ bool "lzo"
+ depends on LZO_DECOMPRESS
+
+endchoice
+
+endif
+
config DEFAULT_ENVIRONMENT_GENERIC
bool
depends on DEFAULT_ENVIRONMENT