ubsan: bpf: left shift cannot be represented in type 'DI' (aka 'long')
[deliverable/binutils-gdb.git] / ld / scripttempl / tic80coff.sc
CommitLineData
252b5132
RH
1# Linker script for TI TMS320C80 (tic80) COFF.
2#
82704155 3# Copyright (C) 2014-2019 Free Software Foundation, Inc.
6c19b93b 4#
985743c7
NC
5# Copying and distribution of this file, with or without modification,
6# are permitted in any medium without royalty provided the copyright
7# notice and this notice are preserved.
8#
252b5132
RH
9# Besides the shell variables set by the emulparams script, and the LD_FLAG
10# variable, the genscripts.sh script will set the following variables for each
11# time this script is run to generate one of the linker scripts for ldscripts:
12#
13# RELOCATING: Set to a non-empty string when the linker is going to be doing
14# a final relocation.
15#
16# CONSTRUCTING: Set to a non-empty string when the linker is going to be
17# building global constructor and destructor tables.
18#
19# DATA_ALIGNMENT: Set to an ALIGN expression when the output should be page
20# aligned, or to "." when generating the -N script.
21#
22# CREATE_SHLIB: Set to a non-empty string when generating a script for
23# the -shared linker arg.
24
25test -z "$TEXT_START_ADDR" && TEXT_START_ADDR="0x80000 + SIZEOF_HEADERS"
26test -z "$ENTRY" && ENTRY=__start
27
28cat <<EOF
82704155 29/* Copyright (C) 2014-2019 Free Software Foundation, Inc.
985743c7
NC
30
31 Copying and distribution of this script, with or without modification,
32 are permitted in any medium without royalty provided the copyright
33 notice and this notice are preserved. */
34
252b5132
RH
35OUTPUT_FORMAT("${OUTPUT_FORMAT}")
36${LIB_SEARCH_DIRS}
37
596d6d91 38${RELOCATING+ENTRY (${ENTRY})}
252b5132
RH
39
40SECTIONS
41{
42 .text ${RELOCATING+ $TEXT_START_ADDR} : {
2d3181c7
AM
43 ${RELOCATING+KEEP (*(SORT_NONE(.init)))
44 KEEP (*(SORT_NONE(.fini)))}
252b5132
RH
45 *(.text)
46 }
47 .const ALIGN(4) : {
48 *(.const)
49 }
50 .ctors ALIGN(4) : {
51 ${CONSTRUCTING+ . = ALIGN(4);}
52 ${CONSTRUCTING+ ___CTOR_LIST__ = .;}
53 ${CONSTRUCTING+ LONG(-1)}
54 *(.ctors)
55 ${CONSTRUCTING+ ___CTOR_END__ = .;}
56 ${CONSTRUCTING+ LONG(0)}
57 }
58 .dtors ALIGN(4) : {
59 ${CONSTRUCTING+ ___DTOR_LIST__ = .;}
60 ${CONSTRUCTING+ LONG(-1)}
61 ${CONSTRUCTING+ *(.dtors)}
62 ${CONSTRUCTING+ ___DTOR_END__ = .;}
63 ${CONSTRUCTING+ LONG(0)}
64 }
65 ${RELOCATING+ etext = .;}
66 .data : {
67 *(.data)
68 ${RELOCATING+ __edata = .};
69 }
6c19b93b 70 .bss : {
252b5132
RH
71 ${RELOCATING+ __bss_start = .};
72 *(.bss)
73 *(COMMON)
74 ${RELOCATING+ _end = ALIGN(0x8)};
75 ${RELOCATING+ __end = ALIGN(0x8)};
76 }
6c19b93b 77 .stab 0 ${RELOCATING+(NOLOAD)} :
252b5132
RH
78 {
79 [ .stab ]
80 }
81 .stabstr 0 ${RELOCATING+(NOLOAD)} :
82 {
83 [ .stabstr ]
84 }
85}
86EOF
This page took 0.866771 seconds and 4 git commands to generate.