Hi,
Below is the link command file. I want to put all r and rx code sections, like interrupt, text, const, init table at the beginning of CODE_DATA_MEMORY, then put all rw data sections behind code section. Now the problem is linking will fail. What is the problem? Why it fail?
If move .cinit out of code_section, just use,
then the .cinit will be located behind of data_section, this is not what I want.
error #10247-D: creating output section ".cinit" without a SECTIONS specification
MEMORY
{
CODE_DATA_MEMORY : org = CODE_DATA_MEM_ADDR, len = CODE_DATA_MEM_LEN
}
SECTIONS
{
code_section :
{
*(.intvecs)
*(.text)
*(.const)
*(.cinit)
} > CODE_DATA_MEM_ADDR
data_section :
{
bss_start = .;
*(.bss)
bss_end = .;
*(.data)
*(.cio)
*(.sysmem)
__stack_start = .;
*(.stack)
__stack_end = .;
__STACK_SIZE = __stack_end - __stack_start + 1;
} > CODE_DATA_MEMORY
}