9de4d8f1c0
* ldgram.y (statement_list_opt): New nonterminal, either empty or statement_list. (section): Use statement_list_opt, not statement_list. * m68kcoff.sc-sh: Gather constructors and destructors and define __CTOR_LIST__ and __DTOR_LIST__ appropriately. * sa29200.sc-sh: Gather constructors and destructors and define ___CTOR_LIST__ and ___DTOR_LIST__ appropriately.
44 lines
794 B
Text
Executable file
44 lines
794 B
Text
Executable file
cat <<EOF
|
|
OUTPUT_FORMAT("${OUTPUT_FORMAT}")
|
|
ENTRY(start)
|
|
|
|
SECTIONS {
|
|
.text ${RELOCATING+${TEXT_START_ADDR}} :
|
|
{
|
|
*(.text);
|
|
*(.text1);
|
|
*(.text2);
|
|
${RELOCATING+_etext = .};
|
|
}
|
|
.lit . :
|
|
{
|
|
*(.lit);
|
|
${RELOCATING+_elit = .};
|
|
}
|
|
.data . :
|
|
{
|
|
*(.data);
|
|
*(.data1);
|
|
*(.data2);
|
|
${RELOCATING+_edata = .};
|
|
${CONSTRUCTING+CONSTRUCTORS}
|
|
${CONSTRUCTING+ ___CTOR_LIST__ = .;}
|
|
${CONSTRUCTING+ LONG((___CTOR_END__ - ___CTOR_LIST__) / 4 - 2)}
|
|
*(.ctors)
|
|
${CONSTRUCTING+ LONG(0)}
|
|
${CONSTRUCTING+ ___CTOR_END__ = .;}
|
|
${CONSTRUCTING+ ___DTOR_LIST__ = .;}
|
|
${CONSTRUCTING+ LONG((___DTOR_END__ - ___DTOR_LIST__) / 4 - 2)}
|
|
*(.dtors)
|
|
${CONSTRUCTING+ LONG(0)}
|
|
${CONSTRUCTING+ ___DTOR_END__ = .;}
|
|
}
|
|
|
|
.bss . :
|
|
{
|
|
*(COMMON)
|
|
*(.bss)
|
|
${RELOCATING+_end = .};
|
|
}
|
|
}
|
|
EOF
|