source: mainline/uspace/lib/c/arch/mips64/_link.ld.in@ d6cd626

lfn serial ticket/834-toolchain-update topic/msim-upgrade topic/simplify-dev-export
Last change on this file since d6cd626 was 9bcdbc5, checked in by Martin Decky <martin@…>, 13 years ago

make sure the code in .init is always aligned reasonably
(despite .interp section being also present in the text segment)

  • Property mode set to 100644
File size: 987 bytes
Line 
1OUTPUT_FORMAT(elf64-tradlittlemips)
2STARTUP(LIBC_PATH/arch/UARCH/src/entry.o)
3ENTRY(__entry)
4
5PHDRS {
6#ifdef LOADER
7 interp PT_INTERP;
8 text PT_LOAD FILEHDR PHDRS FLAGS(5);
9#else
10 text PT_LOAD FLAGS(5);
11#endif
12 data PT_LOAD FLAGS(6);
13}
14
15SECTIONS {
16#ifdef LOADER
17 . = 0x70004000 + SIZEOF_HEADERS;
18
19 .interp : {
20 *(.interp);
21 } :interp :text
22#else
23 . = 0x4000 + SIZEOF_HEADERS;
24#endif
25
26 /* Make sure the code is aligned reasonably */
27 . = ALIGN(., 16);
28
29 .init : {
30 *(.init);
31 } :text
32
33 .text : {
34 *(.text .text.*);
35 *(.rodata .rodata.*);
36 } :text
37
38 . = . + 0x4000;
39
40 .data : {
41 *(.data);
42 *(.data.rel*);
43 } :data
44
45 .got : {
46 _gp = .;
47 *(.got);
48 } :data
49
50 .tdata : {
51 _tdata_start = .;
52 *(.tdata);
53 _tdata_end = .;
54 } :data
55
56 .tbss : {
57 _tbss_start = .;
58 *(.tbss);
59 _tbss_end = .;
60 } :data
61
62 _tls_alignment = MAX(ALIGNOF(.tdata), ALIGNOF(.tbss));
63
64 .sbss : {
65 *(.scommon);
66 *(.sbss);
67 }
68
69 .bss : {
70 *(.bss);
71 *(COMMON);
72 } :data
73
74 /DISCARD/ : {
75 *(*);
76 }
77}
Note: See TracBrowser for help on using the repository browser.