From 0ff85067155a0268c7b5416562a9f70c79f08a8f Mon Sep 17 00:00:00 2001 From: "J. Avila" Date: Thu, 20 May 2021 20:50:24 +0000 Subject: [PATCH] ANDROID: modpost: Check for KBUILD_MIXED_TREE for Modules.symvers When building with KBUILD_MIXED_TREE, Modules.symvers will not be built since vmlinux.symvers won't be in the normal build outputs. Fix this by checking for the mixed-build-prefix in the Modules.symvers target. Fixes: d0736af81151c ("kbuild: generate Module.symvers only when vmlinux exists") Signed-off-by: J. Avila Change-Id: Ic8dcc220cb7b93498629719aaccdb7b6fc38a6a1 --- scripts/Makefile.modpost | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/Makefile.modpost b/scripts/Makefile.modpost index 276330b1c106..e282ddf67689 100644 --- a/scripts/Makefile.modpost +++ b/scripts/Makefile.modpost @@ -73,10 +73,10 @@ module_srcpath := $(srctree) quiet_cmd_cat = GEN $@ cmd_cat = cat $(real-prereqs) > $@ -ifneq ($(wildcard vmlinux.symvers),) +ifneq ($(wildcard $(mixed-build-prefix)vmlinux.symvers),) __modpost: Module.symvers -Module.symvers: vmlinux.symvers modules-only.symvers FORCE +Module.symvers: $(mixed-build-prefix)vmlinux.symvers modules-only.symvers FORCE $(call if_changed,cat) targets += Module.symvers