summaryrefslogtreecommitdiff
path: root/examples/rules.mk
diff options
context:
space:
mode:
authorHa Thach <[email protected]>2022-07-01 20:52:46 +0700
committerGitHub <[email protected]>2022-07-01 20:52:46 +0700
commitecb899408bb95c5c0d50ebe2d887cd746104c534 (patch)
treef7eb5ba056d1ae91cdaca4203f48f588f651a63e /examples/rules.mk
parent68c2012ed1df7f87c898881cd06a445867564106 (diff)
parent53db23142a89def1ad2f866863a559a931eeb035 (diff)
Merge pull request #1544 from hathach/ci-parallel-build
Ci parallel build
Diffstat (limited to 'examples/rules.mk')
-rw-r--r--examples/rules.mk27
1 files changed, 18 insertions, 9 deletions
diff --git a/examples/rules.mk b/examples/rules.mk
index 538dffbcf..c3134056a 100644
--- a/examples/rules.mk
+++ b/examples/rules.mk
@@ -5,6 +5,7 @@
# Set all as default goal
.DEFAULT_GOAL := all
+# ---------------- GNU Make Start -----------------------
# ESP32-Sx and RP2040 has its own CMake build system
ifeq (,$(findstring $(FAMILY),esp32s2 esp32s3 rp2040))
@@ -141,7 +142,23 @@ $(BUILD)/obj/%_asm.o: %.S
@echo AS $(notdir $@)
@$(CC) -x assembler-with-cpp $(ASFLAGS) -c -o $@ $<
-endif # GNU Make
+endif
+
+.PHONY: clean
+clean:
+ifeq ($(CMDEXE),1)
+ rd /S /Q $(subst /,\,$(BUILD))
+else
+ $(RM) -rf $(BUILD)
+endif
+# ---------------- GNU Make End -----------------------
+
+# get depenecies
+.PHONY: get-deps
+get-deps:
+ ifdef DEPS_SUBMODULES
+ git -C $(TOP) submodule update --init $(DEPS_SUBMODULES)
+ endif
size: $(BUILD)/$(PROJECT).elf
-@echo ''
@@ -152,14 +169,6 @@ size: $(BUILD)/$(PROJECT).elf
linkermap: $(BUILD)/$(PROJECT).elf
@linkermap -v $<.map
-.PHONY: clean
-clean:
-ifeq ($(CMDEXE),1)
- rd /S /Q $(subst /,\,$(BUILD))
-else
- $(RM) -rf $(BUILD)
-endif
-
# ---------------------------------------
# Flash Targets
# ---------------------------------------