toolchain: iar: Implement MIN_SIZE and MAX_SIZE for IAR linker
Implement the MIN_SIZE and MAX_SIZE options to zephyr_linker_section_configurefor the IAR icf linker file generator Signed-off-by: Björn Bergman <bjorn.bergman@iar.com>
This commit is contained in:
parent
fc7079185c
commit
a9ed11c3f6
1 changed files with 17 additions and 0 deletions
|
@ -440,6 +440,8 @@ function(section_to_string)
|
|||
get_property(endalign GLOBAL PROPERTY ${STRING_SECTION}_ENDALIGN)
|
||||
get_property(vma GLOBAL PROPERTY ${STRING_SECTION}_VMA)
|
||||
get_property(lma GLOBAL PROPERTY ${STRING_SECTION}_LMA)
|
||||
get_property(min_size GLOBAL PROPERTY ${STRING_SECTION}_MIN_SIZE)
|
||||
get_property(max_size GLOBAL PROPERTY ${STRING_SECTION}_MAX_SIZE)
|
||||
get_property(noinput GLOBAL PROPERTY ${STRING_SECTION}_NOINPUT)
|
||||
get_property(noinit GLOBAL PROPERTY ${STRING_SECTION}_NOINIT)
|
||||
|
||||
|
@ -543,6 +545,12 @@ function(section_to_string)
|
|||
if(endalign)
|
||||
set(TEMP "${TEMP}, end alignment=${endalign}")
|
||||
endif()
|
||||
if(DEFINED min_size)
|
||||
set(TEMP "${TEMP}, minimum size=${min_size}")
|
||||
endif()
|
||||
if(DEFINED max_size)
|
||||
set(TEMP "${TEMP}, maximum size=${max_size}")
|
||||
endif()
|
||||
|
||||
set(TEMP "${TEMP}\n{")
|
||||
|
||||
|
@ -597,6 +605,9 @@ function(section_to_string)
|
|||
get_property(flags GLOBAL PROPERTY ${STRING_SECTION}_SETTING_${idx}_FLAGS)
|
||||
get_property(input GLOBAL PROPERTY ${STRING_SECTION}_SETTING_${idx}_INPUT)
|
||||
get_property(symbols GLOBAL PROPERTY ${STRING_SECTION}_SETTING_${idx}_SYMBOLS)
|
||||
get_property(i_min_size GLOBAL PROPERTY ${STRING_SECTION}_SETTING_${idx}_MIN_SIZE)
|
||||
get_property(i_max_size GLOBAL PROPERTY ${STRING_SECTION}_SETTING_${idx}_MAX_SIZE)
|
||||
|
||||
# Get the next offset and use that as this ones size!
|
||||
get_property(offset GLOBAL PROPERTY ${STRING_SECTION}_SETTING_${idx_next}_OFFSET)
|
||||
|
||||
|
@ -682,6 +693,12 @@ function(section_to_string)
|
|||
else()
|
||||
list(APPEND block_attr "alignment=4")
|
||||
endif()
|
||||
if(DEFINED i_min_size AND NOT i_min_size EQUAL 0)
|
||||
list(APPEND block_attr "minimum size = ${i_min_size}")
|
||||
endif()
|
||||
if(DEFINED i_max_size )
|
||||
list(APPEND block_attr "maximum size = ${i_max_size}")
|
||||
endif()
|
||||
|
||||
# LD
|
||||
# There are two ways to include more than one section:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue