Add KEEP() around vectors in linker scripts.

Vectors are needed by the CPU, but they don't need to be accessed by Rockbox.
Without the KEEP(), they can be removed when liking with --gc-sections, 
creating a broken binary without any warnings. This tells the linker to not
remove them. It should enable use of --gc-sections for all targets. When not
using --gc-sections, this does not change the binary.


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31351 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Boris Gjenero 2011-12-18 06:43:08 +00:00
parent dc07503ad4
commit ca9111ef64
22 changed files with 31 additions and 31 deletions

View file

@ -17,7 +17,7 @@ SECTIONS
{
_loadaddress = .;
_dramend = . + DRAMSIZE;
*(.vectors)
KEEP(*(.vectors))
. = ALIGN(0x200);
} > DRAM

View file

@ -81,8 +81,8 @@ SECTIONS
loadaddress = .;
_loadaddress = .;
_datastart = .;
*(.resetvectors);
*(.vectors);
KEEP(*(.resetvectors));
KEEP(*(.vectors));
. = ALIGN(0x200);
*(.data)
. = ALIGN(0x4);

View file

@ -29,7 +29,7 @@ SECTIONS
.vectors 0 : AT (DRAMORIG + DRAMSIZE - 1M)
{
_start_vectors_section = .;
*(.vectors)
KEEP(*(.vectors))
*(.glue_7)
*(.glue_7t)
. = ALIGN(4);

View file

@ -89,7 +89,7 @@ SECTIONS
.vectors 0x0 :
{
_vectorsstart = .;
*(.vectors)
KEEP(*(.vectors))
_vectorsend = .;
} AT> DRAM

View file

@ -84,7 +84,7 @@ SECTIONS
.vectors 0x0 :
{
_vectorsstart = .;
*(.vectors);
KEEP(*(.vectors));
_vectorsend = .;
} AT> DRAM

View file

@ -84,7 +84,7 @@ SECTIONS
.vectors 0x0 :
{
_vectorsstart = .;
*(.vectors);
KEEP(*(.vectors));
_vectorsend = .;
} AT> DRAM

View file

@ -84,7 +84,7 @@ SECTIONS
.vectors 0x0 :
{
_vectorsstart = .;
*(.vectors);
KEEP(*(.vectors));
_vectorsend = .;
} AT> DRAM

View file

@ -84,7 +84,7 @@ SECTIONS
.vectors 0x0 :
{
_vectorsstart = .;
*(.vectors);
KEEP(*(.vectors));
_vectorsend = .;
} AT> DRAM

View file

@ -84,7 +84,7 @@ SECTIONS
.vectors 0x0 :
{
_vectorsstart = .;
*(.vectors);
KEEP(*(.vectors));
_vectorsend = .;
} AT> DRAM

View file

@ -73,7 +73,7 @@ SECTIONS
.vectors 0x0 :
{
_vectorsstart = .;
*(.vectors);
KEEP(*(.vectors));
_vectorsend = .;
*(.dmabuf)
} >IRAM0 AT> DRAM

View file

@ -35,7 +35,7 @@ SECTIONS
.vectors DRAMORIG :
{
_vectorstart = .;
*(.vectors*);
KEEP(*(.vectors*));
*(.init.text)
. = ALIGN(0x4);
} > DRAM

View file

@ -23,7 +23,7 @@ SECTIONS
.vectors DRAMORIG :
{
_vectorstart = .;
*(.vectors*);
KEEP(*(.vectors*));
*(.init.text)
. = ALIGN(0x4);
} > DRAM

View file

@ -84,7 +84,7 @@ SECTIONS
.vectors 0x0 :
{
_vectorsstart = .;
*(.vectors);
KEEP(*(.vectors));
_vectorsend = .;
} AT> DRAM

View file

@ -81,7 +81,7 @@ SECTIONS
.vectors 0x0 :
{
_vectorsstart = .;
*(.vectors);
KEEP(*(.vectors));
_vectorsend = .;
} AT> DRAM

View file

@ -84,7 +84,7 @@ SECTIONS
.vectors 0x0 :
{
_vectorsstart = .;
*(.vectors);
KEEP(*(.vectors));
_vectorsend = .;
} AT> DRAM

View file

@ -69,7 +69,7 @@ SECTIONS
.vectors ITCMORIG :
{
_vectorsstart = .;
*(.vectors);
KEEP(*(.vectors));
_vectorsend = .;
} > ITCM AT> DRAM

View file

@ -77,7 +77,7 @@ SECTIONS
{
. = ALIGN(0x4);
_vectorsstart = .;
*(.vectors);
KEEP(*(.vectors));
_vectorsend = .;
} > ITCM AT> DRAM

View file

@ -55,14 +55,14 @@ SECTIONS
.iram IRAMORIG: AT (_edata)
{
_iramstart = .;
*(.vectors.1);
KEEP(*(.vectors.1));
. = 0x100;
*(.vectors.2);
KEEP(*(.vectors.2));
. = 0x180;
*(.vectors.3);
KEEP(*(.vectors.3));
. = 0x200;
*(.vectors.4);
*(.vectors);
KEEP(*(.vectors.4));
KEEP(*(.vectors));
*(.icode);
*(.irodata);

View file

@ -49,14 +49,14 @@ SECTIONS
.iram IRAMORIG:
{
_iramstart = .;
*(.vectors.1);
KEEP(*(.vectors.1));
. = 0x100;
*(.vectors.2);
KEEP(*(.vectors.2));
. = 0x180;
*(.vectors.3);
KEEP(*(.vectors.3));
. = 0x200;
*(.vectors.4);
*(.vectors);
KEEP(*(.vectors.4));
KEEP(*(.vectors));
*(.icode);
*(.irodata);

View file

@ -4,7 +4,7 @@ SECTIONS
{
.text 0x09010000 :
{
*(.vectors)
KEEP(*(.vectors))
. = ALIGN(0x200);
*(.init.text)
}

View file

@ -4,7 +4,7 @@ SECTIONS
{
.text 0x09010000 :
{
*(.vectors)
KEEP(*(.vectors))
. = ALIGN(0x200);
*(.init.text)
}

View file

@ -13,7 +13,7 @@ SECTIONS
{
.vectors :
{
*(.vectors)
KEEP(*(.vectors))
. = ALIGN(0x200);
} > FLASH