From 61c03ffab76740c0420e3c8a3185d047d461f7a7 Mon Sep 17 00:00:00 2001 From: Thomas Deutschmann Date: Wed, 5 Aug 2020 03:54:10 +0200 Subject: sys-apps/kexec-tools: rev bump to force ewarn Package-Manager: Portage-3.0.1, Repoman-2.3.23 Signed-off-by: Thomas Deutschmann --- sys-apps/kexec-tools/kexec-tools-9999.ebuild | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'sys-apps/kexec-tools/kexec-tools-9999.ebuild') diff --git a/sys-apps/kexec-tools/kexec-tools-9999.ebuild b/sys-apps/kexec-tools/kexec-tools-9999.ebuild index cb3f3b6f1c4..86b8d9fc978 100644 --- a/sys-apps/kexec-tools/kexec-tools-9999.ebuild +++ b/sys-apps/kexec-tools/kexec-tools-9999.ebuild @@ -105,4 +105,20 @@ pkg_postinst() { elog " /etc/kexec.conf" elog "Please adopt it to your needs as there is no autoconfig anymore" fi + + local n_root_args=$(grep -o -- '\/dev/null | wc -l) + local has_rootpart_set=no + if [[ -f "${EROOT}/etc/conf.d/kexec" ]]; then + if grep -q -E -- '^ROOTPART=' "${EROOT}/etc/conf.d/kexec" 2>/dev/null; then + has_rootpart_set=yes + fi + fi + + if [[ ${n_root_args} > 1 && "${has_rootpart_set}" == "no" ]]; then + ewarn "WARNING: Multiple root arguments (root=) on kernel command-line detected!" + ewarn "This was probably caused by a previous version of ${PN}." + ewarn "Please reboot system once *without* kexec to avoid boot problems" + ewarn "in case running system and initramfs do not agree on detected" + ewarn "root device name!" + fi } -- cgit v1.2.3