source: mainline/uspace/lib/c/arch/ia64/_link.ld.in@ 7137f74c

lfn serial ticket/834-toolchain-update topic/msim-upgrade topic/simplify-dev-export
Last change on this file since 7137f74c was 2eadda9, checked in by Jiří Zárevúcky <jiri.zarevucky@…>, 7 years ago

Remove undefined references to main program from shared libc.

  • Property mode set to 100644
File size: 1.4 KB
Line 
1ENTRY(_start)
2
3PHDRS {
4 text PT_LOAD FILEHDR PHDRS FLAGS(5);
5 data PT_LOAD FLAGS(6);
6 tls PT_TLS;
7}
8
9SECTIONS {
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 /* Workaround proper alignment of the .init section */
19 . = ALIGN(., 16);
20
21 .init : {
22 *(.init);
23 } :text
24
25 .text : {
26 *(.text .text.*);
27 *(.rodata .rodata.*);
28 } :text
29
30 . = . + 0x4000;
31
32 .got : {
33 /* Tell the linker where we expect GP to point. */
34 __gp = .;
35 *(.got .got.*);
36 } :data
37
38 .data : {
39 *(.opd);
40 *(.data .data.*);
41 *(.sdata);
42 *(.sdata.*);
43 } :data
44
45 .tdata : {
46 *(.tdata);
47 *(.tdata.*);
48 *(.gnu.linkonce.td.*);
49 } :data :tls
50
51 .tbss : {
52 *(.tbss);
53 *(.tbss.*);
54 *(.gnu.linkonce.tb.*);
55 } :data :tls
56
57 .bss : {
58 *(.sbss);
59 *(.scommon);
60 *(COMMON);
61 *(.bss);
62 } :data
63
64 __dso_handle = .;
65
66 .init_array : {
67#ifndef SHLIB
68 PROVIDE_HIDDEN (__init_array_start = .);
69#endif
70 KEEP (*(SORT_BY_INIT_PRIORITY(.init_array.*) SORT_BY_INIT_PRIORITY(.ctors.*)))
71 KEEP (*(.init_array .ctors))
72#ifndef SHLIB
73 PROVIDE_HIDDEN (__init_array_end = .);
74#endif
75 }
76
77 .fini_array : {
78#ifndef SHLIB
79 PROVIDE_HIDDEN (__fini_array_start = .);
80#endif
81 KEEP (*(SORT_BY_INIT_PRIORITY(.fini_array.*) SORT_BY_INIT_PRIORITY(.dtors.*)))
82 KEEP (*(.fini_array .dtors))
83#ifndef SHLIB
84 PROVIDE_HIDDEN (__fini_array_end = .);
85#endif
86 }
87
88 _end = .;
89
90 /DISCARD/ : {
91 *(*);
92 }
93}
Note: See TracBrowser for help on using the repository browser.