meta data for this page
Differences
This shows you the differences between two versions of the page.
programming:makefile:snippets:uppercase [2024/05/22 11:59] – created niziak | programming:makefile:snippets:uppercase [2024/08/23 11:56] (current) – niziak | ||
---|---|---|---|
Line 17: | Line 17: | ||
BOARD_ASMFLAGS += -DBOARD_$(call UPPERCASE, | BOARD_ASMFLAGS += -DBOARD_$(call UPPERCASE, | ||
</ | </ | ||
+ | |||
+ | ====== HELP macros ====== | ||
+ | |||
+ | <code make> | ||
+ | define FLASH_HELP | ||
+ | @printf ' | ||
+ | @printf ' | ||
+ | @printf ' | ||
+ | @printf ' | ||
+ | endef | ||
+ | |||
+ | HELP_MACROS += FLASH_HELP | ||
+ | |||
+ | # Needed for the foreach loops to loop over the list of hooks, so that | ||
+ | # each hook call is properly separated by a newline. | ||
+ | define sep | ||
+ | |||
+ | |||
+ | endef | ||
+ | |||
+ | help: | ||
+ | @echo "Most important targets:" | ||
+ | @echo " | ||
+ | ifneq ($(HELP_MACROS), | ||
+ | @echo "" | ||
+ | @echo " | ||
+ | $(foreach p, | ||
+ | @echo "" | ||
+ | $(call $(p))$(sep) \ | ||
+ | ) | ||
+ | endif | ||
+ | </ | ||
+ | |||