preload.ld 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. SECTIONS
  2. {
  3. . = 0x80400000;
  4. . = ALIGN(4096);
  5. .text :
  6. {
  7. KEEP(*(.text.entrypoint)) /* The entry point */
  8. *(.vectors)
  9. *(.text) /* remaining code */
  10. *(.text.*) /* remaining code */
  11. *(.rodata) /* read-only data (constants) */
  12. *(.rodata*)
  13. *(.glue_7)
  14. *(.glue_7t)
  15. *(.gnu.linkonce.t*)
  16. *(COMMON)
  17. _etext = .;
  18. }
  19. . = ALIGN(16);
  20. .eh_frame_hdr :
  21. {
  22. *(.eh_frame_hdr)
  23. *(.eh_frame_entry)
  24. }
  25. .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
  26. . = ALIGN(16);
  27. .data :
  28. {
  29. *(.data)
  30. *(.data.*)
  31. *(.data1)
  32. *(.data1.*)
  33. . = ALIGN(16);
  34. _gp = ABSOLUTE(.); /* Base of small data */
  35. *(.sdata)
  36. *(.sdata.*)
  37. }
  38. . = ALIGN(16);
  39. .ctors :
  40. {
  41. PROVIDE(__ctors_start__ = .);
  42. KEEP(*(SORT(.ctors.*)))
  43. KEEP(*(.ctors))
  44. PROVIDE(__ctors_end__ = .);
  45. }
  46. .dtors :
  47. {
  48. PROVIDE(__dtors_start__ = .);
  49. KEEP(*(SORT(.dtors.*)))
  50. KEEP(*(.dtors))
  51. PROVIDE(__dtors_end__ = .);
  52. }
  53. . = ALIGN(16);
  54. .nobss : { *(.nobss) }
  55. . = ALIGN(16);
  56. __bss_start__ = .;
  57. __bss_start = .;
  58. .bss : { *(.bss)}
  59. . = ALIGN(16);
  60. __bss_end = .;
  61. __bss_end__ = .;
  62. . = ALIGN(16);
  63. /* Stabs debugging sections. */
  64. .stab 0 : { *(.stab) }
  65. .stabstr 0 : { *(.stabstr) }
  66. .stab.excl 0 : { *(.stab.excl) }
  67. .stab.exclstr 0 : { *(.stab.exclstr) }
  68. .stab.index 0 : { *(.stab.index) }
  69. .stab.indexstr 0 : { *(.stab.indexstr) }
  70. .comment 0 : { *(.comment) }
  71. /* DWARF debug sections.
  72. * Symbols in the DWARF debugging sections are relative to the beginning
  73. * of the section so we begin them at 0. */
  74. /* DWARF 1 */
  75. .debug 0 : { *(.debug) }
  76. .line 0 : { *(.line) }
  77. /* GNU DWARF 1 extensions */
  78. .debug_srcinfo 0 : { *(.debug_srcinfo) }
  79. .debug_sfnames 0 : { *(.debug_sfnames) }
  80. /* DWARF 1.1 and DWARF 2 */
  81. .debug_aranges 0 : { *(.debug_aranges) }
  82. .debug_pubnames 0 : { *(.debug_pubnames) }
  83. /* DWARF 2 */
  84. .debug_info 0 : { *(.debug_info .gnu.linkonce.wi.*) }
  85. .debug_abbrev 0 : { *(.debug_abbrev) }
  86. .debug_line 0 : { *(.debug_line) }
  87. .debug_frame 0 : { *(.debug_frame) }
  88. .debug_str 0 : { *(.debug_str) }
  89. .debug_loc 0 : { *(.debug_loc) }
  90. .debug_macinfo 0 : { *(.debug_macinfo) }
  91. /* SGI/MIPS DWARF 2 extensions */
  92. .debug_weaknames 0 : { *(.debug_weaknames) }
  93. .debug_funcnames 0 : { *(.debug_funcnames) }
  94. .debug_typenames 0 : { *(.debug_typenames) }
  95. .debug_varnames 0 : { *(.debug_varnames) }
  96. _end = .;
  97. }
  98. __bss_size = (__bss_end - __bss_start)>>3;