Guard against 'current_directory == NULL' on gdb_abspath (PR gdb/23613)
[deliverable/binutils-gdb.git] / ld / scripttempl / i386go32.sc
CommitLineData
252b5132 1# Linker script for i386 go32 (DJGPP)
985743c7 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.
252b5132
RH
8
9test -z "$ENTRY" && ENTRY=start
10EXE=${CONSTRUCTING+${RELOCATING+-exe}}
11
12# These are substituted in as variables in order to get '}' in a shell
13# conditional expansion.
062739d1
NC
14CTOR='.ctor : {
15 *(SORT(.ctors.*))
16 *(.ctor)
17 }'
18DTOR='.dtor : {
19 *(SORT(.dtors.*))
20 *(.dtor)
21 }'
252b5132
RH
22
23cat <<EOF
82704155 24/* Copyright (C) 2014-2019 Free Software Foundation, Inc.
985743c7
NC
25
26 Copying and distribution of this script, with or without modification,
27 are permitted in any medium without royalty provided the copyright
28 notice and this notice are preserved. */
29
252b5132
RH
30OUTPUT_FORMAT("${OUTPUT_FORMAT}${EXE}")
31
596d6d91 32${RELOCATING+ENTRY (${ENTRY})}
252b5132
RH
33
34SECTIONS
35{
36 .text ${RELOCATING+ ${TARGET_PAGE_SIZE}+SIZEOF_HEADERS} : {
37 *(.text)
c20ec07b 38 ${RELOCATING+*(.text.*)}
5a1bd109 39 ${RELOCATING+*(.gnu.linkonce.t*)}
252b5132
RH
40 *(.const*)
41 *(.ro*)
5a1bd109 42 ${RELOCATING+*(.gnu.linkonce.r*)}
93b63cd3 43 ${RELOCATING+etext = . ; PROVIDE(_etext = .) ;}
252b5132
RH
44 ${RELOCATING+. = ALIGN(${SEGMENT_SIZE});}
45 }
46 .data ${RELOCATING+ ${DATA_ALIGNMENT}} : {
47 ${RELOCATING+djgpp_first_ctor = . ;
062739d1 48 *(SORT(.ctors.*))
252b5132
RH
49 *(.ctor)
50 djgpp_last_ctor = . ;}
51 ${RELOCATING+djgpp_first_dtor = . ;
062739d1 52 *(SORT(.dtors.*))
252b5132
RH
53 *(.dtor)
54 djgpp_last_dtor = . ;}
55 *(.data)
c20ec07b 56 ${RELOCATING+*(.data.*)}
9c9ef45f
ILT
57
58 ${RELOCATING+*(.gcc_exc*)}
59 ${RELOCATING+___EH_FRAME_BEGIN__ = . ;}
60 ${RELOCATING+*(.eh_fram*)}
61 ${RELOCATING+___EH_FRAME_END__ = . ;}
62 ${RELOCATING+LONG(0);}
63
5a1bd109 64 ${RELOCATING+*(.gnu.linkonce.d*)}
93b63cd3 65 ${RELOCATING+edata = . ; PROVIDE(_edata = .) ;}
5a1bd109 66 ${RELOCATING+. = ALIGN(${SEGMENT_SIZE});}
252b5132
RH
67 }
68 ${CONSTRUCTING+${RELOCATING-$CTOR}}
69 ${CONSTRUCTING+${RELOCATING-$DTOR}}
70 .bss ${RELOCATING+ SIZEOF(.data) + ADDR(.data)} :
6c19b93b 71 {
8e616ecc 72 *(.bss${RELOCATING+ .bss.* .gnu.linkonce.b.*})
252b5132 73 *(COMMON)
93b63cd3 74 ${RELOCATING+ end = . ; PROVIDE(_end = .) ;}
252b5132
RH
75 ${RELOCATING+ . = ALIGN(${SEGMENT_SIZE});}
76 }
c20ec07b
NC
77 /* Stabs debugging sections. */
78 .stab 0 : { *(.stab) }
79 .stabstr 0 : { *(.stabstr) }
ceb0a680 80EOF
2a995fc1 81
d061dfac 82. $srcdir/scripttempl/DWARF.sc
2a995fc1 83
ceb0a680 84cat <<EOF
252b5132
RH
85}
86EOF
This page took 0.849714 seconds and 4 git commands to generate.