blob: 377aefb098b1696ff00f5b4f46fd0078363ae6e7 [file] [log] [blame]
developer23f9f0f2023-06-15 13:06:25 +08001diff --git a/include/kernel-build.mk b/include/kernel-build.mk
2index 9dfb19c..e2d97da 100644
3--- a/include/kernel-build.mk
4+++ b/include/kernel-build.mk
5@@ -184,4 +184,10 @@ define BuildKernel
6
7 prereq: image-prereq
8
9+ install-image:
10+ @echo Only install image........
11+ +$(MAKE) -C image compile install TARGET_BUILD=
12+
13+ clean-linux: FORCE
14+ rm -rf $(LINUX_DIR)
15 endef
16diff --git a/rules.mk b/rules.mk
17index 8b2424f..1787d75 100644
18--- a/rules.mk
19+++ b/rules.mk
20@@ -103,7 +103,7 @@ ifdef CONFIG_MIPS64_ABI
21 endif
22 endif
23
24-DEFAULT_SUBDIR_TARGETS:=clean download prepare compile update refresh prereq dist distcheck configure check check-depends
25+DEFAULT_SUBDIR_TARGETS:=clean download prepare compile update refresh prereq dist distcheck configure check check-depends install-image clean-linux
26
27 define DefaultTargets
28 $(foreach t,$(DEFAULT_SUBDIR_TARGETS) $(1),
29diff --git a/target/linux/Makefile b/target/linux/Makefile
30index 3a70b80..e3fe1ca 100644
31--- a/target/linux/Makefile
32+++ b/target/linux/Makefile
33@@ -9,5 +9,5 @@ include $(INCLUDE_DIR)/target.mk
34
35 export TARGET_BUILD=1
36
37-prereq clean download prepare compile install oldconfig menuconfig nconfig xconfig update refresh: FORCE
38+prereq clean download prepare compile install oldconfig menuconfig nconfig xconfig update refresh install-image clean-linux: FORCE
39 @+$(NO_TRACE_MAKE) -C $(BOARD) $@