build
Revision | 2f5e88108956502275793456c5c974c23094bbb1 (tree) |
---|---|
Time | 2016-09-21 15:47:09 |
Author | Chih-Wei Huang <cwhuang@linu...> |
Commiter | Chih-Wei Huang |
Merge remote-tracking branch 'x86/marshmallow-x86' into cm-13.0-x86
@@ -56,17 +56,18 @@ ifneq ($(MOD_ENABLED),) | ||
56 | 56 | KERNEL_MODULES_DEP := $(firstword $(wildcard $(TARGET_OUT)/lib/modules/*/modules.dep)) |
57 | 57 | KERNEL_MODULES_DEP := $(if $(KERNEL_MODULES_DEP),$(KERNEL_MODULES_DEP),$(TARGET_OUT)/lib/modules) |
58 | 58 | |
59 | -$(TARGET_OUT_INTERMEDIATES)/%.kmodule: $(INSTALLED_KERNEL_TARGET) | |
60 | - $(hide) cp -an $(EXTRA_KERNEL_MODULE_PATH_$*) $(TARGET_OUT_INTERMEDIATES)/$*.kmodule | |
59 | +ALL_EXTRA_MODULES := $(patsubst %,$(TARGET_OUT_INTERMEDIATES)/kmodule/%,$(TARGET_EXTRA_KERNEL_MODULES)) | |
60 | +$(ALL_EXTRA_MODULES): $(TARGET_OUT_INTERMEDIATES)/kmodule/%: $(INSTALLED_KERNEL_TARGET) | |
61 | 61 | @echo Building additional kernel module $* |
62 | + $(hide) mkdir -p $(@D) && $(ACP) -fr $(EXTRA_KERNEL_MODULE_PATH_$*) $(@D) | |
62 | 63 | $(mk_kernel) M=$(abspath $@) modules |
63 | 64 | |
64 | -$(KERNEL_MODULES_DEP): $(INSTALLED_KERNEL_TARGET) $(patsubst %,$(TARGET_OUT_INTERMEDIATES)/%.kmodule,$(TARGET_EXTRA_KERNEL_MODULES)) | |
65 | +$(KERNEL_MODULES_DEP): $(INSTALLED_KERNEL_TARGET) $(ALL_EXTRA_MODULES) | |
65 | 66 | $(hide) rm -rf $(TARGET_OUT)/lib/modules |
66 | 67 | $(mk_kernel) INSTALL_MOD_PATH=$(abspath $(TARGET_OUT)) modules_install |
67 | 68 | + $(hide) for kmod in $(TARGET_EXTRA_KERNEL_MODULES) ; do \ |
68 | 69 | echo Installing additional kernel module $${kmod} ; \ |
69 | - $(subst +,,$(subst $(hide),,$(mk_kernel))) INSTALL_MOD_PATH=$(abspath $(TARGET_OUT)) M=$(abspath $(TARGET_OUT_INTERMEDIATES))/$${kmod}.kmodule modules_install ; \ | |
70 | + $(subst +,,$(subst $(hide),,$(mk_kernel))) INSTALL_MOD_PATH=$(abspath $(TARGET_OUT)) M=$(abspath $(TARGET_OUT_INTERMEDIATES))/kmodule/$${kmod} modules_install ; \ | |
70 | 71 | done |
71 | 72 | $(hide) rm -f $(TARGET_OUT)/lib/modules/*/{build,source} |
72 | 73 | endif |