|author||Yann E. MORIN <firstname.lastname@example.org>||2016-03-11 18:41:09 +0100|
|committer||Thomas Petazzoni <email@example.com>||2016-03-19 16:41:22 +0100|
core: add the possibility to provide help for custom rules
When using a br2-external tree, it is possible (as stated in our manual) to implement whatever arbitrary extra make rules (such as flashing a board, or extracting the rootfs in an NFS export...). Some of those extra rules might be exposed to the user as new entry points that the user can call by itself. However, there is no way for the br2-external to advertise those new rules in the help text. We add the possibility to do so, by adding a new make rule, called help-custom, advertised in our own help info. It is up to the br2-external tree to provide whatever help text is deemed necessary. The format of the help is completely free-form. Note that we need to provide an empty, dummy help-custom rule, since it is always advertised (making it .PHONY does not work). Since this rule is empty, make gently reports that there is "Nothing to be done for `help-local'", which is pretty well fitting when help-local was not provided (either because there's no br2-external tree, or when the br2-external tree does not provide it. Signed-off-by: "Yann E. MORIN" <firstname.lastname@example.org> Cc: Jérôme Pouiller <email@example.com> Cc: Arnout Vandecappelle <firstname.lastname@example.org> Cc: Thomas Petazzoni <email@example.com> Signed-off-by: Thomas Petazzoni <firstname.lastname@example.org>
Diffstat (limited to 'Makefile')
1 files changed, 7 insertions, 0 deletions
@@ -966,6 +966,7 @@ endif
@echo ' source-check - check selected packages for valid download URLs'
@echo ' external-deps - list external packages used'
@echo ' legal-info - generate info about license compliance'
+ @echo ' help-custom - print help about custom actions (if any)'
@echo ' make V=0|1 - 0 => quiet build (default), 1 => verbose build'
@echo ' make O=dir - Locate all output files in "dir", including .config'
@@ -974,6 +975,12 @@ endif
@echo 'it on-line at http://buildroot.org/docs.html'
+# This rule does nothing, it is expected to be overloaded by
+# a br2-external tree or a local.mk . However, it must exist,
+# as we reference it in the main help, above. Making the rule
+# .PHONY does not work.
@echo 'Built-in configs:'
@$(foreach b, $(sort $(notdir $(wildcard $(TOPDIR)/configs/*_defconfig))), \