[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20190111131116.927783335@linuxfoundation.org>
Date: Fri, 11 Jan 2019 15:14:05 +0100
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: linux-kernel@...r.kernel.org
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
stable@...r.kernel.org,
Paul Gortmaker <paul.gortmaker@...driver.com>,
Bernd Edlinger <bernd.edlinger@...mail.de>,
Qian Cai <cai@....pw>, Josh Poimboeuf <jpoimboe@...hat.com>,
Masahiro Yamada <yamada.masahiro@...ionext.com>,
Sasha Levin <sashal@...nel.org>
Subject: [PATCH 4.19 067/148] kbuild: fix false positive warning/error about missing libelf
4.19-stable review patch. If anyone has any objections, please let me know.
------------------
[ Upstream commit ef7cfd00b2caf6edeb7f169682b64be2d0a798cf ]
For the same reason as commit 25896d073d8a ("x86/build: Fix compiler
support check for CONFIG_RETPOLINE"), you cannot put this $(error ...)
into the parse stage of the top Makefile.
Perhaps I'd propose a more sophisticated solution later, but this is
the best I can do for now.
Link: https://lkml.org/lkml/2017/12/25/211
Reported-by: Paul Gortmaker <paul.gortmaker@...driver.com>
Reported-by: Bernd Edlinger <bernd.edlinger@...mail.de>
Reported-by: Qian Cai <cai@....pw>
Cc: Josh Poimboeuf <jpoimboe@...hat.com>
Signed-off-by: Masahiro Yamada <yamada.masahiro@...ionext.com>
Tested-by: Qian Cai <cai@....pw>
Signed-off-by: Sasha Levin <sashal@...nel.org>
---
Makefile | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/Makefile b/Makefile
index 3324dd0e11a3..8e6408acf50b 100644
--- a/Makefile
+++ b/Makefile
@@ -954,11 +954,6 @@ ifdef CONFIG_STACK_VALIDATION
ifeq ($(has_libelf),1)
objtool_target := tools/objtool FORCE
else
- ifdef CONFIG_UNWINDER_ORC
- $(error "Cannot generate ORC metadata for CONFIG_UNWINDER_ORC=y, please install libelf-dev, libelf-devel or elfutils-libelf-devel")
- else
- $(warning "Cannot use CONFIG_STACK_VALIDATION=y, please install libelf-dev, libelf-devel or elfutils-libelf-devel")
- endif
SKIP_STACK_VALIDATION := 1
export SKIP_STACK_VALIDATION
endif
@@ -1115,6 +1110,14 @@ uapi-asm-generic:
PHONY += prepare-objtool
prepare-objtool: $(objtool_target)
+ifeq ($(SKIP_STACK_VALIDATION),1)
+ifdef CONFIG_UNWINDER_ORC
+ @echo "error: Cannot generate ORC metadata for CONFIG_UNWINDER_ORC=y, please install libelf-dev, libelf-devel or elfutils-libelf-devel" >&2
+ @false
+else
+ @echo "warning: Cannot use CONFIG_STACK_VALIDATION=y, please install libelf-dev, libelf-devel or elfutils-libelf-devel" >&2
+endif
+endif
# Generate some files
# ---------------------------------------------------------------------------
--
2.19.1
Powered by blists - more mailing lists