diff options
Diffstat (limited to 'mk/config.mk')
-rw-r--r-- | mk/config.mk | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/mk/config.mk b/mk/config.mk index 361f7452..46fd1e4f 100644 --- a/mk/config.mk +++ b/mk/config.mk @@ -40,6 +40,18 @@ PYTHON3 ?= python3 # Define DEBUG=1 to compile without optimization (forces -O0) # DEBUG=1 +ifeq ($(DEBUG),1) +# For backwards compatibility +$(call force,CFG_CC_OPT_LEVEL,0) +$(call force,CFG_DEBUG_INFO,y) +endif + +# CFG_CC_OPT_LEVEL sets compiler optimization level passed with -O directive. +# Optimize for size by default, usually gives good performance too. +CFG_CC_OPT_LEVEL ?= s + +# Enabling CFG_DEBUG_INFO makes debug information embedded in core. +CFG_DEBUG_INFO ?= y # If y, enable debug features of the TEE core (assertions and lock checks # are enabled, panic and assert messages are more verbose, data and prefetch |