lfn
serial
ticket/834-toolchain-update
topic/msim-upgrade
topic/simplify-dev-export
Last change
on this file since c2c4127 was c2c4127, checked in by Jiří Zárevúcky <jiri.zarevucky@…>, 7 years ago |
Do not set STARTUP() in the linker script. Add the file to build script instead.
|
-
Property mode
set to
100644
|
File size:
1.2 KB
|
Line | |
---|
1 | ENTRY(_start)
|
---|
2 |
|
---|
3 | PHDRS {
|
---|
4 | text PT_LOAD FILEHDR PHDRS FLAGS(5);
|
---|
5 | data PT_LOAD FLAGS(6);
|
---|
6 | tls PT_TLS;
|
---|
7 | }
|
---|
8 |
|
---|
9 | SECTIONS {
|
---|
10 | #ifdef SHLIB
|
---|
11 | . = SEGMENT_START("text-segment", 0);
|
---|
12 | #else
|
---|
13 | . = SEGMENT_START("text-segment", 0x400000);
|
---|
14 | PROVIDE (__executable_start = .);
|
---|
15 | #endif
|
---|
16 | . = . + SIZEOF_HEADERS;
|
---|
17 |
|
---|
18 | .text : {
|
---|
19 | *(.text .text.*);
|
---|
20 | *(.rodata .rodata.*);
|
---|
21 | } :text
|
---|
22 |
|
---|
23 | . = . + 0x1000;
|
---|
24 |
|
---|
25 | .data : {
|
---|
26 | *(.data);
|
---|
27 | *(.data.rel*);
|
---|
28 | } :data
|
---|
29 |
|
---|
30 | .got.plt : {
|
---|
31 | *(.got.plt);
|
---|
32 | } :data
|
---|
33 |
|
---|
34 | .tdata : {
|
---|
35 | *(.tdata);
|
---|
36 | *(.tdata.*);
|
---|
37 | *(.gnu.linkonce.td.*);
|
---|
38 | } :data :tls
|
---|
39 |
|
---|
40 | .tbss : {
|
---|
41 | *(.tbss);
|
---|
42 | *(.tbss.*);
|
---|
43 | *(.gnu.linkonce.tb.*);
|
---|
44 | } :data :tls
|
---|
45 |
|
---|
46 | .sbss : {
|
---|
47 | *(.scommon);
|
---|
48 | *(.sbss);
|
---|
49 | }
|
---|
50 |
|
---|
51 | .bss : {
|
---|
52 | *(COMMON);
|
---|
53 | *(.bss);
|
---|
54 | } :data
|
---|
55 |
|
---|
56 | __dso_handle = .;
|
---|
57 |
|
---|
58 | .init_array : {
|
---|
59 | PROVIDE_HIDDEN (__init_array_start = .);
|
---|
60 | KEEP (*(SORT_BY_INIT_PRIORITY(.init_array.*) SORT_BY_INIT_PRIORITY(.ctors.*)))
|
---|
61 | KEEP (*(.init_array .ctors))
|
---|
62 | PROVIDE_HIDDEN (__init_array_end = .);
|
---|
63 | }
|
---|
64 |
|
---|
65 | .fini_array : {
|
---|
66 | PROVIDE_HIDDEN (__fini_array_start = .);
|
---|
67 | KEEP (*(SORT_BY_INIT_PRIORITY(.fini_array.*) SORT_BY_INIT_PRIORITY(.dtors.*)))
|
---|
68 | KEEP (*(.fini_array .dtors))
|
---|
69 | PROVIDE_HIDDEN (__fini_array_end = .);
|
---|
70 | }
|
---|
71 |
|
---|
72 | _end = .;
|
---|
73 |
|
---|
74 | /DISCARD/ : {
|
---|
75 | *(*);
|
---|
76 | }
|
---|
77 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.