msxbuild/lib/make/𓃬𓍄𓋹𓀭/mb_flow_help.mk

159 lines
10 KiB
Makefile
Raw Permalink Normal View History

2024-07-12 16:30:53 +00:00
MB_FLOW_HELP_TEMP := $(shell mktemp)
$(call mb-make-call,mb-doc-variable-rock,MB_FLOW_HELP_TEMP,Temp file to output help with.)
MB_FLOW_HELP_UNITEEN_XML ?= on
$(call mb-make-call,mb-doc-variable-rock,MB_FLOW_HELP_UNITEEN_XML,Test dutch unit-one flag XML attributes.)
# Never use echo to display real text: Argument List Too Long
define _mb-flow-print-help
$(MB_   )@echo -e "$(2)"
$(MB_   )$(file >$(MB_FLOW_HELP_TEMP),$($(1)))
2024-07-17 13:08:25 +00:00
$(MB_   )@cat $(MB_FLOW_HELP_TEMP)
$(MB_   )@$(call mb-make-call,mb-os-file-delete,$(MB_FLOW_HELP_TEMP))
endef
define _mb-flow-help-uniteen-xml
$(MB_   )$(call mb-make-call,mb-make-space-newline)$\
$(MB_      )$(call mb-make-call,mb-make-space-tab)$(call mb-make-call,mb-make-xml-open,uniteen,flag,orange,للَّٰهِilLצسُو,ₚᵣₐᵧTo)$(call mb-make-call,mb-make-space-newline)$\
$(MB_      )$(call mb-make-call,mb-make-space-tab)$(call mb-make-call,mb-make-xml-close,uniteen)$(call mb-make-call,mb-make-space-newline)$\
$(MB_      )$(call mb-make-call,mb-make-space-tab)$(call mb-make-call,mb-make-xml-open,uniteen,flag,red,𑀳𑁂𑀮𑀺𑀉𑁄𑀤𑁄𑀭𑁂𑀡𑀪𑀸𑀕,ₚᵣₐᵧTo)$(call mb-make-call,mb-make-space-newline)$\
$(MB_      )$(call mb-make-call,mb-make-space-tab)$(call mb-make-call,mb-make-xml-close,uniteen)$(call mb-make-call,mb-make-space-newline)$\
$(MB_      )$(call mb-make-call,mb-make-space-tab)$(call mb-make-call,mb-make-xml-open,uniteen,flag,white,ᒡᒢᑊᒻᒻᓫᔿ,ₚᵣₐᵧTo)$(call mb-make-call,mb-make-space-newline)$\
$(MB_      )$(call mb-make-call,mb-make-space-tab)$(call mb-make-call,mb-make-xml-close,uniteen)$(call mb-make-call,mb-make-space-newline)$\
$(MB_      )$(call mb-make-call,mb-make-space-tab)$(call mb-make-call,mb-make-xml-open,uniteen,flag,blue,仙上主天,ₚᵣₐᵧTo)$(call mb-make-call,mb-make-space-newline)$\
$(MB_      )$(call mb-make-call,mb-make-space-tab)$(call mb-make-call,mb-make-xml-close,uniteen)$(call mb-make-call,mb-make-space-newline)
endef
define __mb-flow-doc-help
2024-07-12 16:30:53 +00:00
.RECIPEPREFIX := $(MB_@RECIPE)
@help:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_TARGET_HELP,Welcome to the $$(if $$(MB_PROJ_META_NAME),$$(MB_PROJ_META_NAME),MSXBUILD) help system.\\n\\nFor detailed fire help use one of the following targets;)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help)
2024-07-12 16:30:53 +00:00
@help-variable:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_VARIABLE,Documention of the make fire variables;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-variable,Lists build variables.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-variable)
2024-07-12 16:30:53 +00:00
@help-variable-deep:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_VARIABLE_DEEP,Documention of the deep make variables;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-variable-deep,Lists deep variables.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-variable-deep)
2024-07-12 16:30:53 +00:00
@help-variable-rock:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_VARIABLE_ROCK,Documention of the rock make variables;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-variable-rock,Lists rock variables.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-variable-rock)
2024-07-12 16:30:53 +00:00
@help-variable-flow:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_VARIABLE_FLOW,Documention of the flow make variables;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-variable-flow,Lists flow variables.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-variable-flow)
2024-07-12 16:30:53 +00:00
@help-variable-i18n:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_VARIABLE_I18N,Documention of the i18n make variables;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-variable-i18n,Lists i18n variables.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-variable-i18n)
2024-07-12 16:30:53 +00:00
@help-function:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_FUNCTION,Documention of the make fire functions;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-function,Lists build functions.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-function)
2024-07-12 16:30:53 +00:00
@help-function-deep:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_FUNCTION_DEEP,Documention of the deep make functions;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-function-deep,Lists deep functions.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-function-deep)
2024-07-12 16:30:53 +00:00
@help-function-flow:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_FUNCTION_FLOW,Documention of the flow make functions;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-function-flow,Lists flow functions.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-function-flow)
2024-07-12 16:30:53 +00:00
@help-target:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_TARGET,Build one of the following make fire targets;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-target,Lists build targets.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-target)
2024-07-12 16:30:53 +00:00
@help-target-deep:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_TARGET_DEEP,Build one of the following deep make targets;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-target-deep,Lists deep targets.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-target-deep)
2024-07-12 16:30:53 +00:00
@help-target-run:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_TARGET_RUN,Build one of the following run make targets;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-target-run,Lists runnable targets.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-target-run)
2024-07-12 16:30:53 +00:00
2024-07-14 20:39:03 +00:00
@help-target-module:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_TARGET_MODULE,Build one of the following module make targets;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-target-module,Lists module targets.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-target-module)
2024-07-14 20:39:03 +00:00
@help-target-orphan:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_TARGET_ORPHAN,Build one of the following orphan make targets;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-target-orphan,Lists orphan targets.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-target-orphan)
2024-07-14 20:39:03 +00:00
@help-target-assert:
$(MB_@RECIPE)$$(call mb-make-call,_mb-flow-print-help,MB_DOC_FIRE_TARGET_ASSERT,Build one of the following assert make targets;)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-target-assert,Lists assert targets.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-target-assert)
2024-07-14 20:39:03 +00:00
2024-07-15 00:34:29 +00:00
@help-machine:
$(MB_@RECIPE)@echo -e "Use one of the following machines to build targets;"
$(MB_@RECIPE)@echo -e "\n "$(foreach _rom,$(MB_MSXROM_FIRE_MACHINES)," * $(_rom)\n")
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-machine,Lists supported machines.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-machine)
2024-07-15 00:34:29 +00:00
@help-all: \
$(MB_   )@help-variable @help-variable-deep @help-variable-rock @help-variable-flow @help-variable-i18n \
$(MB_   )@help-function @help-function-deep @help-function-flow \
$(MB_   )@help-target @help-target-deep @help-target-run @help-target-module @help-target-orphan @help-target-assert \
$(MB_   )@help-machine
$(MB_@RECIPE)$$(call mb-make-call,mb-os-echo-good,OK)
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-all,Lists all documented information.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-all)
2024-07-12 16:30:53 +00:00
@help-firemake:
$(MB_@RECIPE)$$(eval MB_DOC_FORMAT :$(MB_MAKE_EQUALS) xml)
$(MB_@RECIPE)$$(file >$(MB_FLOW_HELP_TEMP),$$(call mb-make-call,mb-make-xml-prolog))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(call mb-make-call,mb-make-xml-open,$$(MB_DOC_XML_ROOT)))
$(MB_@RECIPE)$$(if $$(filter on,$$(MB_FLOW_HELP_UNITEEN_XML)),$$(file >>$(MB_FLOW_HELP_TEMP),$$(call mb-make-call,_mb-flow-help-uniteen-xml)))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_VARIABLE))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_VARIABLE_DEEP))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_VARIABLE_ROCK))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_VARIABLE_FLOW))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_VARIABLE_I18N))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_FUNCTION))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_FUNCTION_DEEP))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_FUNCTION_FLOW))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_TARGET))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_TARGET_DEEP))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_TARGET_RUN))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_TARGET_MODULE))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_TARGET_ORPHAN))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_TARGET_ASSERT))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(MB_DOC_FIRE_TARGET_HELP))
$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(call mb-make-call,mb-make-xml-close,$$(MB_DOC_XML_ROOT)))
2024-07-17 13:08:25 +00:00
$(MB_@RECIPE)@cat $$(MB_FLOW_HELP_TEMP)
$(MB_@RECIPE)@$$(call mb-make-call,mb-os-file-delete,$$(MB_FLOW_HELP_TEMP))
$(MB_   )$$(call mb-make-call,mb-doc-target-help,@help-firemake,Output all documention in XML for IDE integration.)
$(MB_   )$$(call mb-make-call,mb-make-target-phony,@help-firemake)
2024-07-12 16:30:53 +00:00
# TODO: create doc for "warpue" xml tag + list Word vAriable Readout Private valUE (for UI)
#$(MB_@RECIPE)$$(file >>$(MB_FLOW_HELP_TEMP),$$(foreach _rom,$$(MB_MSXROM_FIRE_MACHINES),\t$$(call mb-make-call,mb-make-xml-open,$$(MB_DOC_XML_TAG_MACHINE),name,$$(_rom))$$(call mb-make-call,mb-make-xml-close,$$(MB_DOC_XML_TAG_MACHINE))\n))
2024-07-12 16:30:53 +00:00
.RECIPEPREFIX := $(MB_@RECIPEPREFIX)
endef
define mb-flow-doc-help
$(MB_   )$(eval $(call mb-make-call,__$(0),$(1)))
2024-07-12 16:30:53 +00:00
endef
$(call mb-make-call,mb-doc-function-flow,mb-flow-doc-help,Inject flow of fire help system.)
2024-07-12 16:30:53 +00:00