summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorMasahiro Yamada <masahiroy@kernel.org>2021-07-29 03:12:54 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-08-12 14:32:11 +0300
commit9884f6096c4a83248eda4f42f2f0f5297592d15d (patch)
tree9135fdc76a6b19b6985ca52a35861fe89bafb847 /Makefile
parentcb1f2a9b52d67686f75f896c16eab01dcbd72aaa (diff)
downloadlinux-9884f6096c4a83248eda4f42f2f0f5297592d15d.tar.xz
kbuild: cancel sub_make_done for the install target to fix DKMS
[ Upstream commit 14ccc638b02f9ec500c17d9e39efe979145a4b61 ] Since commit bcf637f54f6d ("kbuild: parse C= and M= before changing the working directory"), external module builds invoked by DKMS fail because M= option is not parsed. I wanted to add 'unset sub_make_done' in install.sh but similar scripts, arch/*/boot/install.sh, are duplicated, so I set sub_make_done empty in the top Makefile. Fixes: bcf637f54f6d ("kbuild: parse C= and M= before changing the working directory") Reported-by: John S Gruber <johnsgruber@gmail.com> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Tested-by: John S Gruber <johnsgruber@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile9
1 files changed, 9 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 9d810e13a83f..218f44d7fc80 100644
--- a/Makefile
+++ b/Makefile
@@ -1366,6 +1366,15 @@ scripts_unifdef: scripts_basic
$(Q)$(MAKE) $(build)=scripts scripts/unifdef
# ---------------------------------------------------------------------------
+# Install
+
+# Many distributions have the custom install script, /sbin/installkernel.
+# If DKMS is installed, 'make install' will eventually recuses back
+# to the this Makefile to build and install external modules.
+# Cancel sub_make_done so that options such as M=, V=, etc. are parsed.
+
+install: sub_make_done :=
+
# Kernel selftest
PHONY += kselftest