script_test_12i.t 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. /* script_test_12i.t -- linker script test 12 for gold, with interleaved sections
  2. Copyright (C) 2008-2022 Free Software Foundation, Inc.
  3. Written by Cary Coutant <ccoutant@gmail.com>.
  4. This file is part of gold.
  5. This program is free software; you can redistribute it and/or modify
  6. it under the terms of the GNU General Public License as published by
  7. the Free Software Foundation; either version 3 of the License, or
  8. (at your option) any later version.
  9. This program is distributed in the hope that it will be useful,
  10. but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. GNU General Public License for more details.
  13. You should have received a copy of the GNU General Public License
  14. along with this program; if not, write to the Free Software
  15. Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
  16. MA 02110-1301, USA. */
  17. interleaved = 1;
  18. SECTIONS
  19. {
  20. . = 0x400000 + SIZEOF_HEADERS;
  21. .interp : { *(.interp) }
  22. .note : { *(.note .note.*) }
  23. .rel.dyn : { *(.rel.dyn) }
  24. .rela.dyn : { *(.rela.dyn) }
  25. .rel.plt : { *(.rel.plt) }
  26. .rela.plt : { *(.rela.plt) }
  27. .init : { *(.init) }
  28. .text : { *(.text) }
  29. .fini : { *(.fini) }
  30. .rodata : { *(.rodata .rodata.*) }
  31. .eh_frame_hdr : { *(.eh_frame_hdr) }
  32. .eh_frame : { *(.eh_frame) }
  33. . = DATA_SEGMENT_ALIGN(0x10000, 0x10000);
  34. .init_array : {
  35. __init_array_start = .;
  36. *(.init_array);
  37. __init_array_end = .;
  38. }
  39. .fini_array : { *(.fini_array) }
  40. .jcr : { *(.jcr) }
  41. .dynamic : { *(.dynamic) }
  42. .got : { *(.got) }
  43. .got.plt : { *(.got.plt) }
  44. .data : { *(.data) }
  45. .test : {
  46. test_array_start = .;
  47. *(.x1) *(.x2) *(.x3)
  48. test_array_end = .;
  49. *(.x4);
  50. }
  51. .bss : { *(.bss) }
  52. }