1*1424dfb3Schristos/* script_test_15b.t -- linker script test 15b for gold
2*1424dfb3Schristos
3*1424dfb3Schristos   Copyright (C) 2016-2020 Free Software Foundation, Inc.
4*1424dfb3Schristos   Written by Cary Coutant <ccoutant@google.com>.
5*1424dfb3Schristos
6*1424dfb3Schristos   This file is part of gold.
7*1424dfb3Schristos
8*1424dfb3Schristos   This program is free software; you can redistribute it and/or modify
9*1424dfb3Schristos   it under the terms of the GNU General Public License as published by
10*1424dfb3Schristos   the Free Software Foundation; either version 3 of the License, or
11*1424dfb3Schristos   (at your option) any later version.
12*1424dfb3Schristos
13*1424dfb3Schristos   This program is distributed in the hope that it will be useful,
14*1424dfb3Schristos   but WITHOUT ANY WARRANTY; without even the implied warranty of
15*1424dfb3Schristos   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16*1424dfb3Schristos   GNU General Public License for more details.
17*1424dfb3Schristos
18*1424dfb3Schristos   You should have received a copy of the GNU General Public License
19*1424dfb3Schristos   along with this program; if not, write to the Free Software
20*1424dfb3Schristos   Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
21*1424dfb3Schristos   MA 02110-1301, USA.  */
22*1424dfb3Schristos
23*1424dfb3Schristos/* Test that a .bss section explicitly placed in the middle of a
24*1424dfb3Schristos   segment has allocated file space.  */
25*1424dfb3Schristos
26*1424dfb3Schristos/* We won't try to run this program, just ensure that it links
27*1424dfb3Schristos   as expected.  */
28*1424dfb3Schristos
29*1424dfb3SchristosPHDRS
30*1424dfb3Schristos{
31*1424dfb3Schristos  text    PT_LOAD FLAGS(5);
32*1424dfb3Schristos  data    PT_LOAD FLAGS(6);
33*1424dfb3Schristos}
34*1424dfb3Schristos
35*1424dfb3SchristosSECTIONS
36*1424dfb3Schristos{
37*1424dfb3Schristos  /* With luck this will be enough to get the program working.  */
38*1424dfb3Schristos  .interp : { *(.interp) } :text
39*1424dfb3Schristos  .text : { *(.text .text.*) }
40*1424dfb3Schristos  .rodata : { *(.rodata .rodata.*) }
41*1424dfb3Schristos  /* Required by the ARM target. */
42*1424dfb3Schristos  .ARM.extab : { *(.ARM.extab*) }
43*1424dfb3Schristos  .ARM.exidx : { *(.ARM.exidx*) }
44*1424dfb3Schristos  . = ALIGN(0x10000);
45*1424dfb3Schristos  .dynamic : { *(.dynamic) }
46*1424dfb3Schristos  .bss : { *(.bss) } :data
47*1424dfb3Schristos  .data : { *(.data) }
48*1424dfb3Schristos  .got : { *(.got .toc) }
49*1424dfb3Schristos}
50