Gentoo Archives: gentoo-commits

From: Sebastian Pipping <sping@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/genkernel:master commit in: /
Date: Sun, 08 Apr 2012 18:34:09
Message-Id: 1333909637.66e5a247041af5406dfbc90acda436c3db0fa463.sping@gentoo
1 commit: 66e5a247041af5406dfbc90acda436c3db0fa463
2 Author: Sebastian Pipping <sebastian <AT> pipping <DOT> org>
3 AuthorDate: Sun Apr 8 18:24:14 2012 +0000
4 Commit: Sebastian Pipping <sping <AT> gentoo <DOT> org>
5 CommitDate: Sun Apr 8 18:27:17 2012 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/genkernel.git;a=commit;h=66e5a247
7
8 Add "fastest" to supported initrd compressions
9
10 ---
11 ChangeLog | 4 ++++
12 gen_initramfs.sh | 4 ++--
13 genkernel.conf | 3 ++-
14 3 files changed, 8 insertions(+), 3 deletions(-)
15
16 diff --git a/ChangeLog b/ChangeLog
17 index 2533e58..2db901a 100644
18 --- a/ChangeLog
19 +++ b/ChangeLog
20 @@ -5,6 +5,10 @@
21 # Distributed under the GPL v2
22 # $Id$
23
24 + 08 Apr 2012; Sebastian Pipping <sping@g.o> gen_initramfs.sh,
25 + genkernel.conf:
26 + Add "fastest" to supported initrd compressions
27 +
28 08 Apr 2012; Sebastian Pipping <sping@g.o> gen_initramfs.sh:
29 Support comression "lzop" (not just "lzo") as wrongly advertised by comments
30 in genkernel.conf before
31
32 diff --git a/gen_initramfs.sh b/gen_initramfs.sh
33 index 082d525..4838234 100755
34 --- a/gen_initramfs.sh
35 +++ b/gen_initramfs.sh
36 @@ -714,7 +714,7 @@ create_initramfs() {
37 case ${COMPRESS_INITRD_TYPE} in
38 xz|lzma|bzip2|gzip|lzop) compression=${COMPRESS_INITRD_TYPE} ;;
39 lzo) compression=lzop ;;
40 - best)
41 + best|fastest)
42 for tuple in \
43 'CONFIG_RD_XZ cmd_xz xz' \
44 'CONFIG_RD_LZMA cmd_lzma lzma' \
45 @@ -726,7 +726,7 @@ create_initramfs() {
46 cmd_variable_name=$2
47 if grep -sq "^${kernel_option}=y" ${KERNEL_DIR}/.config && test -n "${!cmd_variable_name}" ; then
48 compression=$3
49 - break
50 + [[ ${COMPRESS_INITRD_TYPE} == best ]] && break
51 fi
52 done
53 ;;
54
55 diff --git a/genkernel.conf b/genkernel.conf
56 index 0d14271..c5e7aee 100644
57 --- a/genkernel.conf
58 +++ b/genkernel.conf
59 @@ -314,8 +314,9 @@ GPG_BINCACHE="%%CACHE%%/gnupg-${GPG_VER}-%%ARCH%%.bz2"
60
61 # Compress generated initramfs
62 #COMPRESS_INITRD="yes"
63 -# Types of compression: best, xz, lzma, bzip2, gzip, lzop
64 +# Types of compression: best, xz, lzma, bzip2, gzip, lzop, fastest
65 # "best" selects the best available compression method
66 +# "fastest" selects the fastest available compression method
67 #COMPRESS_INITRD_TYPE="best"