Browse Source

- kernel: install kernel-headers to build_tmp

master
vanhofen 4 years ago
parent
commit
e4ac395b3e
  1. 2
      make/environment-linux.mk
  2. 5
      make/linux-kernel.mk

2
make/environment-linux.mk

@ -192,6 +192,7 @@ KERNEL_PATCH = $($(call UPPERCASE,$(BOXMODEL))_PATCH)
KERNEL_OBJ = linux-$(KERNEL_VER)-obj
KERNEL_MODULES = linux-$(KERNEL_VER)-modules
KERNEL_HEADERS = linux-$(KERNEL_VER)-headers
KERNEL_CONFIG ?= $(CONFIGS)/kernel-$(BOXMODEL).config
KERNEL_NAME = NI $(shell echo $(BOXFAMILY) | sed 's/.*/\u&/') Kernel
@ -215,6 +216,7 @@ KERNEL_MAKEVARS = \
ARCH=$(TARGET_ARCH) \
CROSS_COMPILE=$(TARGET_CROSS) \
INSTALL_MOD_PATH=$(BUILD_DIR)/$(KERNEL_MODULES) \
INSTALL_HDR_PATH=$(BUILD_DIR)/$(KERNEL_HEADERS) \
LOCALVERSION= \
O=$(BUILD_DIR)/$(KERNEL_OBJ)

5
make/linux-kernel.mk

@ -207,8 +207,10 @@ kernel.do_prepare:
#
$(REMOVE)/$(KERNEL_OBJ)
$(REMOVE)/$(KERNEL_MODULES)
$(REMOVE)/$(KERNEL_HEADERS)
$(MKDIR)/$(KERNEL_OBJ)
$(MKDIR)/$(KERNEL_MODULES)
$(MKDIR)/$(KERNEL_HEADERS)
$(INSTALL_DATA) $(KERNEL_CONFIG) $(BUILD_DIR)/$(KERNEL_OBJ)/.config
ifeq ($(BOXMODEL),$(filter $(BOXMODEL),hd51 bre2ze4k h7 hd60 hd61))
$(INSTALL_DATA) $(PATCHES)/initramfs-subdirboot.cpio.gz $(BUILD_DIR)/$(KERNEL_OBJ)
@ -233,7 +235,8 @@ kernel.do_compile: kernel.do_prepare
$(CHDIR)/$(KERNEL_DIR); \
$(MAKE) $(KERNEL_MAKEVARS) silentoldconfig; \
$(MAKE) $(KERNEL_MAKEVARS) $(KERNEL_MAKEOPTS); \
$(MAKE) $(KERNEL_MAKEVARS) modules_install
$(MAKE) $(KERNEL_MAKEVARS) modules_install; \
$(MAKE) $(KERNEL_MAKEVARS) headers_install
ifneq ($(KERNEL_DTB),$(EMPTY))
cat $(KERNEL_ZIMAGE) $(KERNEL_DTB) > $(KERNEL_ZIMAGE_DTB)
endif

Loading…
Cancel
Save