mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Add help and showconfig targets to Makefile
This commit is contained in:
@@ -17,6 +17,12 @@ else
|
||||
MAKE_FLAGS = --no-print-directory CC='$(CC)' LL='$(LL)' ALL_CFLAGS='$(ALL_CFLAGS)'
|
||||
endif
|
||||
|
||||
##############################
|
||||
# internal variables
|
||||
|
||||
export MSG_BEGIN = @for line in
|
||||
export MSG_END = ; do echo "$$line"; done
|
||||
|
||||
##############################
|
||||
# generic build targets, rules
|
||||
|
||||
@@ -39,3 +45,29 @@ clean :
|
||||
@$(MAKE) clean -C tools/mruby $(MAKE_FLAGS)
|
||||
@$(MAKE) clean -C tools/mirb $(MAKE_FLAGS)
|
||||
@$(MAKE) clean -C test $(MAKE_FLAGS)
|
||||
|
||||
# display help for build configuration and interesting targets
|
||||
.PHONY : showconfig
|
||||
showconfig :
|
||||
$(MSG_BEGIN) \
|
||||
"" \
|
||||
" CC = $(CC)" \
|
||||
" LL = $(LL)" \
|
||||
" MAKE = $(MAKE)" \
|
||||
"" \
|
||||
" CFLAGS = $(CFLAGS)" \
|
||||
" ALL_CFLAGS = $(ALL_CFLAGS)" \
|
||||
$(MSG_END)
|
||||
|
||||
.PHONY : help
|
||||
help :
|
||||
$(MSG_BEGIN) \
|
||||
"" \
|
||||
" Basic mruby Makefile" \
|
||||
"" \
|
||||
"targets:" \
|
||||
" all (default): build all targets, install (locally) in-repo" \
|
||||
" clean: clean all built and in-repo installed artifacts" \
|
||||
" showconfig: show build config summary" \
|
||||
" test: run all mruby tests" \
|
||||
$(MSG_END)
|
||||
|
||||
Reference in New Issue
Block a user