summaryrefslogtreecommitdiffstats
path: root/scripts/Makefile.lib
diff options
context:
space:
mode:
authorMasahiro Yamada <yamada.masahiro@socionext.com>2018-03-19 18:01:23 +0900
committerMasahiro Yamada <yamada.masahiro@socionext.com>2018-03-26 02:01:24 +0900
commit8cd0e46d3f0ce730a5c7d1e9e75765b24b72013a (patch)
tree7ef79fcdd86a220f0fa407fba21ca4ceec4aa800 /scripts/Makefile.lib
parenta670b0b4aed129dc11b465c1c330bfe9202023e5 (diff)
downloadlinux-stable-8cd0e46d3f0ce730a5c7d1e9e75765b24b72013a.tar.gz
linux-stable-8cd0e46d3f0ce730a5c7d1e9e75765b24b72013a.tar.bz2
linux-stable-8cd0e46d3f0ce730a5c7d1e9e75765b24b72013a.zip
kbuild: remove unnecessary $(subst $(obj)/, , ...) in modname-multi
In the context ... $(obj)/%.s: $(src)/%.c FORCE $(call if_changed_dep,cc_s_c) $(obj)/%.i: $(src)/%.c FORCE $(call if_changed_dep,cpp_i_c) $(obj)/%.o: $(src)/%.c $(recordmcount_source) $(objtool_dep) FORCE $(call cmd,force_checksrc) $(call if_changed_rule,cc_o_c) $(obj)/%.lst: $(src)/%.c FORCE $(call if_changed_dep,cc_lst_c) '$*' returns the stem of the target (the part of '%'), so $(obj)/ has already been ripped off. $(subst $(obj)/,,$*.o) is the same as $*.o Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Reviewed-by: Cao jin <caoj.fnst@cn.fujitsu.com>
Diffstat (limited to 'scripts/Makefile.lib')
-rw-r--r--scripts/Makefile.lib2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
index ef592e993e92..ca5b587c9c42 100644
--- a/scripts/Makefile.lib
+++ b/scripts/Makefile.lib
@@ -175,7 +175,7 @@ dtc_cpp_flags = -Wp,-MD,$(depfile).pre.tmp -nostdinc \
# Finds the multi-part object the current object will be linked into
modname-multi = $(sort $(foreach m,$(multi-used),\
- $(if $(filter $(subst $(obj)/,,$*.o), $($(m:.o=-objs)) $($(m:.o=-y))),$(m:.o=))))
+ $(if $(filter $*.o, $($(m:.o=-objs)) $($(m:.o=-y))),$(m:.o=))))
# Useful for describing the dependency of composite objects
# Usage: