esp32: Pass V=1 or BUILD_VERBOSE through to idf.py when building.
Allows verbose build to work the same on esp32 port as other ports. To minimise copy/paste, split the BUILD_VERBOSE section of mkenv.mk out to its own verbose.mk and include this in the port Makefile. Signed-off-by: Angus Gratton <angus@redyak.com.au>
This commit is contained in:
parent
5fb846df67
commit
160a4812cd
3 changed files with 23 additions and 16 deletions
|
|
@ -2,6 +2,8 @@
|
|||
#
|
||||
# This is a simple, convenience wrapper around idf.py (which uses cmake).
|
||||
|
||||
include ../../py/verbose.mk
|
||||
|
||||
# Select the board to build for:
|
||||
ifdef BOARD_DIR
|
||||
# Custom board path - remove trailing slash and get the final component of
|
||||
|
|
@ -61,6 +63,10 @@ ifdef MICROPY_PREVIEW_VERSION_2
|
|||
IDFPY_FLAGS += -D MICROPY_PREVIEW_VERSION_2=1
|
||||
endif
|
||||
|
||||
ifeq ($(BUILD_VERBOSE),1)
|
||||
IDFPY_FLAGS += --verbose
|
||||
endif
|
||||
|
||||
HELP_BUILD_ERROR ?= "See \033[1;31mhttps://github.com/micropython/micropython/wiki/Build-Troubleshooting\033[0m"
|
||||
|
||||
define RUN_IDF_PY
|
||||
|
|
|
|||
17
py/mkenv.mk
17
py/mkenv.mk
|
|
@ -12,22 +12,7 @@ endif
|
|||
THIS_MAKEFILE := $(lastword $(MAKEFILE_LIST))
|
||||
TOP := $(patsubst %/py/mkenv.mk,%,$(THIS_MAKEFILE))
|
||||
|
||||
# Turn on increased build verbosity by defining BUILD_VERBOSE in your main
|
||||
# Makefile or in your environment. You can also use V=1 on the make command
|
||||
# line.
|
||||
|
||||
ifeq ("$(origin V)", "command line")
|
||||
BUILD_VERBOSE=$(V)
|
||||
endif
|
||||
ifndef BUILD_VERBOSE
|
||||
$(info Use make V=1 or set BUILD_VERBOSE in your environment to increase build verbosity.)
|
||||
BUILD_VERBOSE = 0
|
||||
endif
|
||||
ifeq ($(BUILD_VERBOSE),0)
|
||||
Q = @
|
||||
else
|
||||
Q =
|
||||
endif
|
||||
include $(TOP)/py/verbose.mk
|
||||
|
||||
# default settings; can be overridden in main Makefile
|
||||
|
||||
|
|
|
|||
16
py/verbose.mk
Normal file
16
py/verbose.mk
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
# Turn on increased build verbosity by defining BUILD_VERBOSE in your main
|
||||
# Makefile or in your environment. You can also use V=1 on the make command
|
||||
# line.
|
||||
|
||||
ifeq ("$(origin V)", "command line")
|
||||
BUILD_VERBOSE=$(V)
|
||||
endif
|
||||
ifndef BUILD_VERBOSE
|
||||
$(info Use make V=1 or set BUILD_VERBOSE in your environment to increase build verbosity.)
|
||||
BUILD_VERBOSE = 0
|
||||
endif
|
||||
ifeq ($(BUILD_VERBOSE),0)
|
||||
Q = @
|
||||
else
|
||||
Q =
|
||||
endif
|
||||
Loading…
Reference in a new issue