Skip to content
Snippets Groups Projects
Unverified Commit 6e148bcf authored by cladmi's avatar cladmi
Browse files

atmega_common: allow defining rom and ram length for link.

Allow configuring __TEXT_REGION_LENGTH__ and __DATA_REGION_LENGTH__ linkerscript
variables using ROM_LEN and RAM_LEN makefile variables.
parent 6942c376
Branches
No related tags found
No related merge requests found
...@@ -26,3 +26,8 @@ ifeq ($(LTO),1) ...@@ -26,3 +26,8 @@ ifeq ($(LTO),1)
# See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59396 # See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59396
export LINKFLAGS += -Wno-error export LINKFLAGS += -Wno-error
endif endif
# Use ROM_LEN and RAM_LEN during link
# It is made optional until all boards are updated
LINKFLAGS += $(if $(ROM_LEN),$(LINKFLAGPREFIX)--defsym=__TEXT_REGION_LENGTH__=$(ROM_LEN))
LINKFLAGS += $(if $(RAM_LEN),$(LINKFLAGPREFIX)--defsym=__DATA_REGION_LENGTH__=$(RAM_LEN))
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment