History

kbuild: pass dst= to Makefile.headersinst from top Makefile

We can always pass dst= from the top Makefile. This will simplify the logic in Makefile.headersinst.

Masahiro Yamada committed 9 years ago

Commit a8ff49a1 parent 0f042ee2 files · +4 −8Browse files

Showing the changes to scripts (1 of 2 files). Show all

Unified · Split

scripts/Makefile.headersinst+2−6
@@ -23,15 +23,12 @@ subdirs := $(patsubst $(srcdir)/%/,%,\ · 22 unmodified lines
2323 $(filter-out $(srcdir)/,\
2424 $(sort $(dir $(wildcard $(srcdir)/*/)))))
2525
26−# caller may set destination dir (when installing to asm/)
27−_dst := $(if $(dst),$(dst),$(obj))
28−
2926 # Recursion
3027 __headers: $(subdirs)
3128
3229 .PHONY: $(subdirs)
3330 $(subdirs):
34− $(Q)$(MAKE) $(hdr-inst)=$(obj)/$@ dst=$(_dst)/$@
31+ $(Q)$(MAKE) $(hdr-inst)=$(obj)/$@ dst=$(dst)/$@
3532
3633 # Skip header install/check for include/uapi and arch/$(hdr-arch)/include/uapi.
3734 # We have only sub-directories there.
@@ -48,8 +45,7 @@ ifneq ($(wildcard $(old-kbuild-file)),) · 10 unmodified lines
4845 include $(old-kbuild-file)
4946 endif
5047
51−installdir := $(INSTALL_HDR_PATH)/$(subst uapi/,,$(_dst))
52−
48+installdir := $(INSTALL_HDR_PATH)/$(dst)
5349 gendir := $(objtree)/$(subst include/,include/generated/,$(obj))
5450 header-files := $(notdir $(wildcard $(srcdir)/*.h))
5551 header-files += $(notdir $(wildcard $(srcdir)/*.agh))