Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

3 anos atrás
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254
  1. /* Script for -shared -z combreloc -z separate-code */
  2. /* Copyright (C) 2014-2020 Free Software Foundation, Inc.
  3. Copying and distribution of this script, with or without modification,
  4. are permitted in any medium without royalty provided the copyright
  5. notice and this notice are preserved. */
  6. OUTPUT_FORMAT("elf32-littlearm", "elf32-bigarm",
  7. "elf32-littlearm")
  8. OUTPUT_ARCH(arm)
  9. ENTRY(_start)
  10. SEARCH_DIR("=/tmp/jenkins-GCC-10-pipeline-48_20201124_1606180639/install-native/arm-none-eabi/lib"); SEARCH_DIR("=/usr/local/lib"); SEARCH_DIR("=/lib"); SEARCH_DIR("=/usr/lib");
  11. SECTIONS
  12. {
  13. . = SEGMENT_START("text-segment", 0) + SIZEOF_HEADERS;
  14. .note.gnu.build-id : { *(.note.gnu.build-id) }
  15. .hash : { *(.hash) }
  16. .gnu.hash : { *(.gnu.hash) }
  17. .dynsym : { *(.dynsym) }
  18. .dynstr : { *(.dynstr) }
  19. .gnu.version : { *(.gnu.version) }
  20. .gnu.version_d : { *(.gnu.version_d) }
  21. .gnu.version_r : { *(.gnu.version_r) }
  22. .rel.dyn :
  23. {
  24. *(.rel.init)
  25. *(.rel.text .rel.text.* .rel.gnu.linkonce.t.*)
  26. *(.rel.fini)
  27. *(.rel.rodata .rel.rodata.* .rel.gnu.linkonce.r.*)
  28. *(.rel.data.rel.ro .rel.data.rel.ro.* .rel.gnu.linkonce.d.rel.ro.*)
  29. *(.rel.data .rel.data.* .rel.gnu.linkonce.d.*)
  30. *(.rel.tdata .rel.tdata.* .rel.gnu.linkonce.td.*)
  31. *(.rel.tbss .rel.tbss.* .rel.gnu.linkonce.tb.*)
  32. *(.rel.ctors)
  33. *(.rel.dtors)
  34. *(.rel.got)
  35. *(.rel.bss .rel.bss.* .rel.gnu.linkonce.b.*)
  36. *(.rel.iplt)
  37. }
  38. .rela.dyn :
  39. {
  40. *(.rela.init)
  41. *(.rela.text .rela.text.* .rela.gnu.linkonce.t.*)
  42. *(.rela.fini)
  43. *(.rela.rodata .rela.rodata.* .rela.gnu.linkonce.r.*)
  44. *(.rela.data .rela.data.* .rela.gnu.linkonce.d.*)
  45. *(.rela.tdata .rela.tdata.* .rela.gnu.linkonce.td.*)
  46. *(.rela.tbss .rela.tbss.* .rela.gnu.linkonce.tb.*)
  47. *(.rela.ctors)
  48. *(.rela.dtors)
  49. *(.rela.got)
  50. *(.rela.bss .rela.bss.* .rela.gnu.linkonce.b.*)
  51. *(.rela.iplt)
  52. }
  53. .rel.plt :
  54. {
  55. *(.rel.plt)
  56. }
  57. .rela.plt :
  58. {
  59. *(.rela.plt)
  60. }
  61. . = ALIGN(CONSTANT (MAXPAGESIZE));
  62. .init :
  63. {
  64. KEEP (*(SORT_NONE(.init)))
  65. }
  66. .plt : { *(.plt) }
  67. .iplt : { *(.iplt) }
  68. .text :
  69. {
  70. *(.text.unlikely .text.*_unlikely .text.unlikely.*)
  71. *(.text.exit .text.exit.*)
  72. *(.text.startup .text.startup.*)
  73. *(.text.hot .text.hot.*)
  74. *(SORT(.text.sorted.*))
  75. *(.text .stub .text.* .gnu.linkonce.t.*)
  76. /* .gnu.warning sections are handled specially by elf.em. */
  77. *(.gnu.warning)
  78. *(.glue_7t) *(.glue_7) *(.vfp11_veneer) *(.v4_bx)
  79. }
  80. .fini :
  81. {
  82. KEEP (*(SORT_NONE(.fini)))
  83. }
  84. PROVIDE (__etext = .);
  85. PROVIDE (_etext = .);
  86. PROVIDE (etext = .);
  87. . = ALIGN(CONSTANT (MAXPAGESIZE));
  88. /* Adjust the address for the rodata segment. We want to adjust up to
  89. the same address within the page on the next page up. */
  90. . = SEGMENT_START("rodata-segment", ALIGN(CONSTANT (MAXPAGESIZE)) + (. & (CONSTANT (MAXPAGESIZE) - 1)));
  91. .rodata : { *(.rodata .rodata.* .gnu.linkonce.r.*) }
  92. .rodata1 : { *(.rodata1) }
  93. .ARM.extab : { *(.ARM.extab* .gnu.linkonce.armextab.*) }
  94. .ARM.exidx :
  95. {
  96. PROVIDE_HIDDEN (__exidx_start = .);
  97. *(.ARM.exidx* .gnu.linkonce.armexidx.*)
  98. PROVIDE_HIDDEN (__exidx_end = .);
  99. }
  100. .eh_frame_hdr : { *(.eh_frame_hdr) *(.eh_frame_entry .eh_frame_entry.*) }
  101. .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) *(.eh_frame.*) }
  102. .gcc_except_table : ONLY_IF_RO { *(.gcc_except_table .gcc_except_table.*) }
  103. .gnu_extab : ONLY_IF_RO { *(.gnu_extab*) }
  104. /* These sections are generated by the Sun/Oracle C++ compiler. */
  105. .exception_ranges : ONLY_IF_RO { *(.exception_ranges*) }
  106. /* Adjust the address for the data segment. We want to adjust up to
  107. the same address within the page on the next page up. */
  108. . = ALIGN(CONSTANT (MAXPAGESIZE)) + (. & (CONSTANT (MAXPAGESIZE) - 1));
  109. /* Exception handling */
  110. .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) *(.eh_frame.*) }
  111. .gnu_extab : ONLY_IF_RW { *(.gnu_extab) }
  112. .gcc_except_table : ONLY_IF_RW { *(.gcc_except_table .gcc_except_table.*) }
  113. .exception_ranges : ONLY_IF_RW { *(.exception_ranges*) }
  114. /* Thread Local Storage sections */
  115. .tdata :
  116. {
  117. *(.tdata .tdata.* .gnu.linkonce.td.*)
  118. }
  119. .tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
  120. .preinit_array :
  121. {
  122. KEEP (*(.preinit_array))
  123. }
  124. .init_array :
  125. {
  126. KEEP (*(SORT_BY_INIT_PRIORITY(.init_array.*) SORT_BY_INIT_PRIORITY(.ctors.*)))
  127. KEEP (*(.init_array EXCLUDE_FILE (*crtbegin.o *crtbegin?.o *crtend.o *crtend?.o ) .ctors))
  128. }
  129. .fini_array :
  130. {
  131. KEEP (*(SORT_BY_INIT_PRIORITY(.fini_array.*) SORT_BY_INIT_PRIORITY(.dtors.*)))
  132. KEEP (*(.fini_array EXCLUDE_FILE (*crtbegin.o *crtbegin?.o *crtend.o *crtend?.o ) .dtors))
  133. }
  134. .ctors :
  135. {
  136. /* gcc uses crtbegin.o to find the start of
  137. the constructors, so we make sure it is
  138. first. Because this is a wildcard, it
  139. doesn't matter if the user does not
  140. actually link against crtbegin.o; the
  141. linker won't look for a file to match a
  142. wildcard. The wildcard also means that it
  143. doesn't matter which directory crtbegin.o
  144. is in. */
  145. KEEP (*crtbegin.o(.ctors))
  146. KEEP (*crtbegin?.o(.ctors))
  147. /* We don't want to include the .ctor section from
  148. the crtend.o file until after the sorted ctors.
  149. The .ctor section from the crtend file contains the
  150. end of ctors marker and it must be last */
  151. KEEP (*(EXCLUDE_FILE (*crtend.o *crtend?.o ) .ctors))
  152. KEEP (*(SORT(.ctors.*)))
  153. KEEP (*(.ctors))
  154. }
  155. .dtors :
  156. {
  157. KEEP (*crtbegin.o(.dtors))
  158. KEEP (*crtbegin?.o(.dtors))
  159. KEEP (*(EXCLUDE_FILE (*crtend.o *crtend?.o ) .dtors))
  160. KEEP (*(SORT(.dtors.*)))
  161. KEEP (*(.dtors))
  162. }
  163. .jcr : { KEEP (*(.jcr)) }
  164. .data.rel.ro : { *(.data.rel.ro.local* .gnu.linkonce.d.rel.ro.local.*) *(.data.rel.ro .data.rel.ro.* .gnu.linkonce.d.rel.ro.*) }
  165. .dynamic : { *(.dynamic) }
  166. .got : { *(.got.plt) *(.igot.plt) *(.got) *(.igot) }
  167. .data :
  168. {
  169. PROVIDE (__data_start = .);
  170. *(.data .data.* .gnu.linkonce.d.*)
  171. SORT(CONSTRUCTORS)
  172. }
  173. .data1 : { *(.data1) }
  174. PROVIDE (_edata = .); PROVIDE (edata = .);
  175. . = .;
  176. PROVIDE (__bss_start = .);
  177. PROVIDE (__bss_start__ = .);
  178. .bss :
  179. {
  180. *(.dynbss)
  181. *(.bss .bss.* .gnu.linkonce.b.*)
  182. *(COMMON)
  183. /* Align here to ensure that the .bss section occupies space up to
  184. _end. Align after .bss to ensure correct alignment even if the
  185. .bss section disappears because there are no input sections.
  186. FIXME: Why do we need it? When there is no .bss section, we do not
  187. pad the .data section. */
  188. . = ALIGN(. != 0 ? 32 / 8 : 1);
  189. }
  190. PROVIDE (_bss_end__ = .); PROVIDE (__bss_end__ = .);
  191. . = ALIGN(32 / 8);
  192. . = SEGMENT_START("ldata-segment", .);
  193. . = ALIGN(32 / 8);
  194. PROVIDE (__end__ = .);
  195. PROVIDE (_end = .); PROVIDE (end = .);
  196. .stack 0x80000 :
  197. {
  198. _stack = .;
  199. *(.stack)
  200. }
  201. /* Stabs debugging sections. */
  202. .stab 0 : { *(.stab) }
  203. .stabstr 0 : { *(.stabstr) }
  204. .stab.excl 0 : { *(.stab.excl) }
  205. .stab.exclstr 0 : { *(.stab.exclstr) }
  206. .stab.index 0 : { *(.stab.index) }
  207. .stab.indexstr 0 : { *(.stab.indexstr) }
  208. .comment 0 : { *(.comment) }
  209. .gnu.build.attributes : { *(.gnu.build.attributes .gnu.build.attributes.*) }
  210. /* DWARF debug sections.
  211. Symbols in the DWARF debugging sections are relative to the beginning
  212. of the section so we begin them at 0. */
  213. /* DWARF 1 */
  214. .debug 0 : { *(.debug) }
  215. .line 0 : { *(.line) }
  216. /* GNU DWARF 1 extensions */
  217. .debug_srcinfo 0 : { *(.debug_srcinfo) }
  218. .debug_sfnames 0 : { *(.debug_sfnames) }
  219. /* DWARF 1.1 and DWARF 2 */
  220. .debug_aranges 0 : { *(.debug_aranges) }
  221. .debug_pubnames 0 : { *(.debug_pubnames) }
  222. /* DWARF 2 */
  223. .debug_info 0 : { *(.debug_info .gnu.linkonce.wi.*) }
  224. .debug_abbrev 0 : { *(.debug_abbrev) }
  225. .debug_line 0 : { *(.debug_line .debug_line.* .debug_line_end) }
  226. .debug_frame 0 : { *(.debug_frame) }
  227. .debug_str 0 : { *(.debug_str) }
  228. .debug_loc 0 : { *(.debug_loc) }
  229. .debug_macinfo 0 : { *(.debug_macinfo) }
  230. /* SGI/MIPS DWARF 2 extensions */
  231. .debug_weaknames 0 : { *(.debug_weaknames) }
  232. .debug_funcnames 0 : { *(.debug_funcnames) }
  233. .debug_typenames 0 : { *(.debug_typenames) }
  234. .debug_varnames 0 : { *(.debug_varnames) }
  235. /* DWARF 3 */
  236. .debug_pubtypes 0 : { *(.debug_pubtypes) }
  237. .debug_ranges 0 : { *(.debug_ranges) }
  238. /* DWARF Extension. */
  239. .debug_macro 0 : { *(.debug_macro) }
  240. .debug_addr 0 : { *(.debug_addr) }
  241. .ARM.attributes 0 : { KEEP (*(.ARM.attributes)) KEEP (*(.gnu.attributes)) }
  242. .note.gnu.arm.ident 0 : { KEEP (*(.note.gnu.arm.ident)) }
  243. /* This section contains data that is not initialised during load
  244. *or* application reset. */
  245. .noinit (NOLOAD) :
  246. {
  247. . = ALIGN(2);
  248. PROVIDE (__noinit_start = .);
  249. *(.noinit)
  250. . = ALIGN(2);
  251. PROVIDE (__noinit_end = .);
  252. }
  253. /DISCARD/ : { *(.note.GNU-stack) *(.gnu_debuglink) *(.gnu.lto_*) }
  254. }