Gentoo Archives: gentoo-commits

From: Thomas Deutschmann <whissi@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/genkernel:master commit in: /
Date: Mon, 29 Jul 2019 20:10:30
Message-Id: 1564430426.86ce6816b789e707fa8348624b0643beeeb3c7eb.whissi@gentoo
1 commit: 86ce6816b789e707fa8348624b0643beeeb3c7eb
2 Author: Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
3 AuthorDate: Sun Jul 28 21:07:17 2019 +0000
4 Commit: Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
5 CommitDate: Mon Jul 29 20:00:26 2019 +0000
6 URL: https://gitweb.gentoo.org/proj/genkernel.git/commit/?id=86ce6816
7
8 genkernel: Don't allow building kernel only when --kerncache is used but --no-install is set
9
10 This just don't make sense. We wouldn't do anything.
11
12 Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org>
13
14 genkernel | 8 ++++++++
15 1 file changed, 8 insertions(+)
16
17 diff --git a/genkernel b/genkernel
18 index 31a880d..f33379c 100755
19 --- a/genkernel
20 +++ b/genkernel
21 @@ -188,6 +188,14 @@ then
22 gen_kerncache_is_valid
23 fi
24
25 +if isTrue "${KERNCACHE_IS_VALID}" && ! isTrue "${CMD_INSTALL}" && ! isTrue "${BUILD_RAMDISK}"
26 +then
27 + error_msg="Nothing to do: Selected action does not include building initramfs."
28 + error_msg+=" Because kerncache is valid, no kernel will be build."
29 + error_msg+=" However, due to set --no-install option, we will not even install kernel binary from kerncache."
30 + gen_die "${error_msg}"
31 +fi
32 +
33 print_info 1 '' 1 0
34 print_info 1 "Working with Linux kernel ${BOLD}${KV}${NORMAL} for ${BOLD}${ARCH}${NORMAL}"
35 print_info 1 "Using kernel config file '${KERNEL_CONFIG}' ..."