Commit 9d022c54 authored by Masahiro Yamada's avatar Masahiro Yamada

kbuild: replace $(hdr-arch) with $(SRCARCH)

Since commit 5e538790 ("sparc,sparc64: unify Makefile"), hdr-arch
and SRCARCH always match.
Signed-off-by: default avatarMasahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: default avatarDouglas Anderson <dianders@chromium.org>
parent 37131ec4
...@@ -283,9 +283,6 @@ ifeq ($(ARCH),tilegx) ...@@ -283,9 +283,6 @@ ifeq ($(ARCH),tilegx)
SRCARCH := tile SRCARCH := tile
endif endif
# Where to locate arch specific headers
hdr-arch := $(SRCARCH)
KCONFIG_CONFIG ?= .config KCONFIG_CONFIG ?= .config
export KCONFIG_CONFIG export KCONFIG_CONFIG
...@@ -378,8 +375,8 @@ CFLAGS_KCOV := $(call cc-option,-fsanitize-coverage=trace-pc,) ...@@ -378,8 +375,8 @@ CFLAGS_KCOV := $(call cc-option,-fsanitize-coverage=trace-pc,)
# Use USERINCLUDE when you must reference the UAPI directories only. # Use USERINCLUDE when you must reference the UAPI directories only.
USERINCLUDE := \ USERINCLUDE := \
-I$(srctree)/arch/$(hdr-arch)/include/uapi \ -I$(srctree)/arch/$(SRCARCH)/include/uapi \
-I$(objtree)/arch/$(hdr-arch)/include/generated/uapi \ -I$(objtree)/arch/$(SRCARCH)/include/generated/uapi \
-I$(srctree)/include/uapi \ -I$(srctree)/include/uapi \
-I$(objtree)/include/generated/uapi \ -I$(objtree)/include/generated/uapi \
-include $(srctree)/include/linux/kconfig.h -include $(srctree)/include/linux/kconfig.h
...@@ -387,8 +384,8 @@ USERINCLUDE := \ ...@@ -387,8 +384,8 @@ USERINCLUDE := \
# Use LINUXINCLUDE when you must reference the include/ directory. # Use LINUXINCLUDE when you must reference the include/ directory.
# Needed to be compatible with the O= option # Needed to be compatible with the O= option
LINUXINCLUDE := \ LINUXINCLUDE := \
-I$(srctree)/arch/$(hdr-arch)/include \ -I$(srctree)/arch/$(SRCARCH)/include \
-I$(objtree)/arch/$(hdr-arch)/include/generated \ -I$(objtree)/arch/$(SRCARCH)/include/generated \
$(if $(KBUILD_SRC), -I$(srctree)/include) \ $(if $(KBUILD_SRC), -I$(srctree)/include) \
-I$(objtree)/include \ -I$(objtree)/include \
$(USERINCLUDE) $(USERINCLUDE)
...@@ -1134,8 +1131,8 @@ headerdep: ...@@ -1134,8 +1131,8 @@ headerdep:
#Default location for installed headers #Default location for installed headers
export INSTALL_HDR_PATH = $(objtree)/usr export INSTALL_HDR_PATH = $(objtree)/usr
# If we do an all arch process set dst to include/arch-$(hdr-arch) # If we do an all arch process set dst to include/arch-$(SRCARCH)
hdr-dst = $(if $(KBUILD_HEADERS), dst=include/arch-$(hdr-arch), dst=include) hdr-dst = $(if $(KBUILD_HEADERS), dst=include/arch-$(SRCARCH), dst=include)
PHONY += archheaders PHONY += archheaders
archheaders: archheaders:
...@@ -1153,10 +1150,10 @@ headers_install_all: ...@@ -1153,10 +1150,10 @@ headers_install_all:
PHONY += headers_install PHONY += headers_install
headers_install: __headers headers_install: __headers
$(if $(wildcard $(srctree)/arch/$(hdr-arch)/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 dst=include $(Q)$(MAKE) $(hdr-inst)=include/uapi dst=include
$(Q)$(MAKE) $(hdr-inst)=arch/$(hdr-arch)/include/uapi $(hdr-dst) $(Q)$(MAKE) $(hdr-inst)=arch/$(SRCARCH)/include/uapi $(hdr-dst)
PHONY += headers_check_all PHONY += headers_check_all
headers_check_all: headers_install_all headers_check_all: headers_install_all
...@@ -1165,7 +1162,7 @@ headers_check_all: headers_install_all ...@@ -1165,7 +1162,7 @@ headers_check_all: headers_install_all
PHONY += headers_check PHONY += headers_check
headers_check: headers_install headers_check: headers_install
$(Q)$(MAKE) $(hdr-inst)=include/uapi dst=include HDRCHECK=1 $(Q)$(MAKE) $(hdr-inst)=include/uapi dst=include HDRCHECK=1
$(Q)$(MAKE) $(hdr-inst)=arch/$(hdr-arch)/include/uapi $(hdr-dst) HDRCHECK=1 $(Q)$(MAKE) $(hdr-inst)=arch/$(SRCARCH)/include/uapi $(hdr-dst) HDRCHECK=1
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
# Kernel selftest # Kernel selftest
......
...@@ -30,7 +30,7 @@ __headers: $(subdirs) ...@@ -30,7 +30,7 @@ __headers: $(subdirs)
$(subdirs): $(subdirs):
$(Q)$(MAKE) $(hdr-inst)=$(obj)/$@ dst=$(dst)/$@ $(Q)$(MAKE) $(hdr-inst)=$(obj)/$@ dst=$(dst)/$@
# Skip header install/check for include/uapi and arch/$(hdr-arch)/include/uapi. # Skip header install/check for include/uapi and arch/$(SRCARCH)/include/uapi.
# We have only sub-directories there. # We have only sub-directories there.
skip-inst := $(if $(filter %/uapi,$(obj)),1) skip-inst := $(if $(filter %/uapi,$(obj)),1)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment