From f4686ee7df8de74d37fcf22a5a5ae00a3a3f1020 Mon Sep 17 00:00:00 2001 From: Quey-Liang Kao Date: Tue, 3 May 2016 04:49:30 +0800 Subject: [PATCH] kpatch-build: Add "CONFIG_DEBUG_KERNEL" kernel config checking While the officially supported distributions all have CONFIG_DEBUG_KERNEL enabled, this is not true for some other distributions. This option is necessary when kpatch-build retrieves the SPECIAL_VARS using readelf command. Signed-off-by: Quey-Liang Kao --- kpatch-build/kpatch-build | 2 ++ 1 file changed, 2 insertions(+) diff --git a/kpatch-build/kpatch-build b/kpatch-build/kpatch-build index 0bd3a36..a57dd77 100755 --- a/kpatch-build/kpatch-build +++ b/kpatch-build/kpatch-build @@ -448,6 +448,8 @@ else fi fi +# kernel option checking: CONFIG_DEBUG_KERNEL and CONFIG_LIVEPATCH +grep -q "CONFIG_DEBUG_KERNEL=y" "$OBJDIR/.config" || die "kernel doesn't have 'CONFIG_DEBUG_KERNEL' enabled" if grep "CONFIG_LIVEPATCH=y" "$OBJDIR/.config" > /dev/null; then # The kernel supports livepatch. KBUILD_EXTRA_SYMBOLS=""