{sw/common] enable debug symbols "-g"

This commit is contained in:
stnolting 2024-10-26 21:18:35 +02:00
parent dbc4cfa1d2
commit f00cc8ae53

View file

@ -1,6 +1,8 @@
# ================================================================================ #
# NEORV32 Application Software Makefile #
# -------------------------------------------------------------------------------- #
# Do not edit this file! Use the re-defines in the project-local makefile instead. #
# -------------------------------------------------------------------------------- #
# The NEORV32 RISC-V Processor - https://github.com/stnolting/neorv32 #
# Copyright (c) NEORV32 contributors. #
# Copyright (c) 2020 - 2024 Stephan Nolting. All rights reserved. #
@ -9,8 +11,8 @@
# ================================================================================ #
# -----------------------------------------------------------------------------
# Default configuration (do not edit this file; override the configuration
# when including this Makefile in the project-specific Makefile)
# Default configuration (DO NOT EDIT THIS FILE! REDEFINE / OVERRIDE THE DEFAULT
# CONFIGURATION WHEN INCLUDING THIS MAKEFILE IN THE PROJECT-SPECIFIC MAKEFILE)
# -----------------------------------------------------------------------------
# User's application sources (*.c, *.cpp, *.s, *.S); add additional files here
APP_SRC ?= $(wildcard ./*.c) $(wildcard ./*.s) $(wildcard ./*.cpp) $(wildcard ./*.S)
@ -106,7 +108,7 @@ IMAGE_GEN = $(NEORV32_EXG_PATH)/image_gen
# Compiler & linker flags
CC_OPTS = -march=$(MARCH) -mabi=$(MABI) $(EFFORT) -Wall -ffunction-sections -fdata-sections -nostartfiles -mno-fdiv
CC_OPTS += -mstrict-align -mbranch-cost=10 -Wl,--gc-sections -ffp-contract=off
CC_OPTS += -mstrict-align -mbranch-cost=10 -Wl,--gc-sections -ffp-contract=off -g
CC_OPTS += $(USER_FLAGS)
LD_LIBS = -lm -lc -lgcc
LD_LIBS += $(USER_LIBS)
@ -391,6 +393,7 @@ help:
@echo " MARCH - Machine architecture: \"$(MARCH)\""
@echo " MABI - Machine binary interface: \"$(MABI)\""
@echo " APP_INC - C include folder(s) [append only]: \"$(APP_INC)\""
@echo " APP_SRC - C source folder(s) [append only]: \"$(APP_SRC)\""
@echo " ASM_INC - ASM include folder(s) [append only]: \"$(ASM_INC)\""
@echo " RISCV_PREFIX - Toolchain prefix: \"$(RISCV_PREFIX)\""
@echo " NEORV32_HOME - NEORV32 home folder: \"$(NEORV32_HOME)\""