techpack: Fix uapi headers_install
Since commit <d5470d14431e9d39e> ("kbuild: re-implement Makefile.headersinst without recursion"), the headers_install excludes Kbuild from providing information regarding uapi headers. In fact, it recursively pulls all the headers from a given path, in this case techpack/*. This isn't correct as techpack/ may have non-uapi headers as well, which shouldn't be considered. Hence, strictly look for include/uapi/$dir directory for the uapi headers. Change-Id: Ic7b3f927bc962729da1b87ed90e5f50a1e4cd5c5 Signed-off-by: Raghavendra Rao Ananta <rananta@codeaurora.org>
This commit is contained in:
parent
86cb2da52a
commit
b05d9892a4
11
Makefile
11
Makefile
@ -1196,19 +1196,26 @@ PHONY += archheaders archscripts
|
|||||||
|
|
||||||
hdr-inst := -f $(srctree)/scripts/Makefile.headersinst obj
|
hdr-inst := -f $(srctree)/scripts/Makefile.headersinst obj
|
||||||
|
|
||||||
|
techpack-dirs := $(shell find $(srctree)/techpack -maxdepth 1 -mindepth 1 -type d -not -name ".*")
|
||||||
|
techpack-dirs := $(subst $(srctree)/,,$(techpack-dirs))
|
||||||
|
|
||||||
PHONY += headers
|
PHONY += headers
|
||||||
headers: $(version_h) scripts_unifdef uapi-asm-generic archheaders archscripts
|
headers: $(version_h) scripts_unifdef uapi-asm-generic archheaders archscripts
|
||||||
$(if $(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/Kbuild),, \
|
$(if $(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/Kbuild),, \
|
||||||
$(error Headers not exportable for the $(SRCARCH) architecture))
|
$(error Headers not exportable for the $(SRCARCH) architecture))
|
||||||
$(Q)$(MAKE) $(hdr-inst)=include/uapi
|
$(Q)$(MAKE) $(hdr-inst)=include/uapi
|
||||||
$(Q)$(MAKE) $(hdr-inst)=arch/$(SRCARCH)/include/uapi
|
$(Q)$(MAKE) $(hdr-inst)=arch/$(SRCARCH)/include/uapi
|
||||||
$(Q)$(MAKE) $(hdr-inst)=techpack
|
$(Q)for d in $(techpack-dirs); do \
|
||||||
|
$(MAKE) $(hdr-inst)=$$d/include/uapi; \
|
||||||
|
done
|
||||||
|
|
||||||
PHONY += headers_check
|
PHONY += headers_check
|
||||||
headers_check: headers
|
headers_check: headers
|
||||||
$(Q)$(MAKE) $(hdr-inst)=include/uapi HDRCHECK=1
|
$(Q)$(MAKE) $(hdr-inst)=include/uapi HDRCHECK=1
|
||||||
$(Q)$(MAKE) $(hdr-inst)=arch/$(SRCARCH)/include/uapi HDRCHECK=1
|
$(Q)$(MAKE) $(hdr-inst)=arch/$(SRCARCH)/include/uapi HDRCHECK=1
|
||||||
$(Q)$(MAKE) $(hdr-inst)=techpack HDRCHECK=1
|
$(Q)for d in $(techpack-dirs); do \
|
||||||
|
$(MAKE) $(hdr-inst)=$$d/include/uapi HDRCHECK=1; \
|
||||||
|
done
|
||||||
|
|
||||||
ifdef CONFIG_HEADERS_INSTALL
|
ifdef CONFIG_HEADERS_INSTALL
|
||||||
prepare: headers
|
prepare: headers
|
||||||
|
@ -3,6 +3,3 @@ TECHPACK?=y
|
|||||||
|
|
||||||
techpack-dirs := $(shell find $(srctree)/techpack -maxdepth 1 -mindepth 1 -xtype d -not -name ".*")
|
techpack-dirs := $(shell find $(srctree)/techpack -maxdepth 1 -mindepth 1 -xtype d -not -name ".*")
|
||||||
obj-${TECHPACK} += stub/ $(addsuffix /,$(subst $(srctree)/techpack/,,$(techpack-dirs)))
|
obj-${TECHPACK} += stub/ $(addsuffix /,$(subst $(srctree)/techpack/,,$(techpack-dirs)))
|
||||||
|
|
||||||
techpack-header-dirs := $(shell find $(srctree)/techpack -maxdepth 1 -mindepth 1 -type d -not -name ".*")
|
|
||||||
header-${TECHPACK} += $(addsuffix /include/uapi/,$(subst $(srctree)/techpack/,,$(techpack-header-dirs)))
|
|
||||||
|
Loading…
Reference in New Issue
Block a user