aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Deutschmann <whissi@gentoo.org>2021-03-15 21:53:56 +0100
committerThomas Deutschmann <whissi@gentoo.org>2021-03-15 21:53:56 +0100
commit63dc301f06f80253e341da756e9cb10aca336eb8 (patch)
tree6f86c4c5775d76b2d598e2701404baf21af5ada7 /genkernel
parentgkbuilds/thin-provisioning-tools: no need to manually call gkautoreconf (diff)
downloadgenkernel-63dc301f06f80253e341da756e9cb10aca336eb8.tar.gz
genkernel-63dc301f06f80253e341da756e9cb10aca336eb8.tar.bz2
genkernel-63dc301f06f80253e341da756e9cb10aca336eb8.zip
genkernel: show warning when CONFIG_CMDLINE_OVERRIDE=y is set
Link 1: https://forums.gentoo.org/viewtopic-t-1131897.html Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>
Diffstat (limited to 'genkernel')
-rwxr-xr-xgenkernel12
1 files changed, 12 insertions, 0 deletions
diff --git a/genkernel b/genkernel
index 7d5a75ee..046e0e3c 100755
--- a/genkernel
+++ b/genkernel
@@ -532,6 +532,18 @@ then
print_warning 1 'add "rootfstype=ext3" or "rootfstype=ext4" to the list of boot parameters.'
fi
unset CONFGREP_CMD
+
+ cfg_CONFIG_CMDLINE_OVERRIDE=$(kconfig_get_opt "${KERNEL_CONFIG}" CONFIG_CMDLINE_OVERRIDE)
+ if [ "${cfg_CONFIG_CMDLINE_OVERRIDE}" = "y" ]
+ then
+ cfg_CONFIG_CMDLINE=$(kconfig_get_opt "${KERNEL_CONFIG}" CONFIG_CMDLINE)
+ print_warning 1 ''
+ print_warning 1 "${BOLD}Note:${NORMAL}"
+ print_warning 1 'You have set CONFIG_CMDLINE_OVERRIDE=y.'
+ print_warning 1 "You will be unable to alter set kernel parameters (${cfg_CONFIG_CMDLINE}) at runtime!"
+ unset cfg_CONFIG_CMDLINE
+ fi
+ unset cfg_CONFIG_CMDLINE_OVERRIDE
fi
isTrue "${CMD_INSTALL}" && restore_boot_mount_state