Mention support for LLVM plugin in NEWS
[deliverable/binutils-gdb.git] / ld / ldlex.h
CommitLineData
252b5132 1/* ldlex.h -
b90efa5b 2 Copyright (C) 1991-2015 Free Software Foundation, Inc.
252b5132 3
f96b4a7b 4 This file is part of the GNU Binutils.
252b5132 5
f96b4a7b 6 This program is free software; you can redistribute it and/or modify
252b5132 7 it under the terms of the GNU General Public License as published by
f96b4a7b
NC
8 the Free Software Foundation; either version 3 of the License, or
9 (at your option) any later version.
252b5132 10
f96b4a7b 11 This program is distributed in the hope that it will be useful,
252b5132
RH
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
f96b4a7b
NC
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
19 MA 02110-1301, USA. */
252b5132
RH
20
21#ifndef LDLEX_H
22#define LDLEX_H
23
24#include <stdio.h>
25
f05eb3b7
AM
26/* Codes used for the long options with no short synonyms. 150 isn't
27 special; it's just an arbitrary non-ASCII char value. */
28enum option_values
29{
30 OPTION_ASSERT = 150,
31 OPTION_CALL_SHARED,
32 OPTION_CREF,
33 OPTION_DEFSYM,
34 OPTION_DEMANGLE,
35 OPTION_DYNAMIC_LINKER,
36 OPTION_SYSROOT,
37 OPTION_EB,
38 OPTION_EL,
39 OPTION_EMBEDDED_RELOCS,
40 OPTION_EXPORT_DYNAMIC,
41 OPTION_NO_EXPORT_DYNAMIC,
42 OPTION_HELP,
43 OPTION_IGNORE,
44 OPTION_MAP,
45 OPTION_NO_DEMANGLE,
46 OPTION_NO_KEEP_MEMORY,
47 OPTION_NO_WARN_MISMATCH,
48 OPTION_NO_WARN_SEARCH_MISMATCH,
49 OPTION_NOINHIBIT_EXEC,
50 OPTION_NON_SHARED,
51 OPTION_NO_WHOLE_ARCHIVE,
52 OPTION_OFORMAT,
53 OPTION_RELAX,
54 OPTION_NO_RELAX,
55 OPTION_RETAIN_SYMBOLS_FILE,
56 OPTION_RPATH,
57 OPTION_RPATH_LINK,
58 OPTION_SHARED,
59 OPTION_SONAME,
60 OPTION_SORT_COMMON,
61 OPTION_SORT_SECTION,
62 OPTION_STATS,
63 OPTION_SYMBOLIC,
64 OPTION_SYMBOLIC_FUNCTIONS,
65 OPTION_TASK_LINK,
66 OPTION_TBSS,
67 OPTION_TDATA,
68 OPTION_TTEXT,
69 OPTION_TTEXT_SEGMENT,
9d5777a3 70 OPTION_TRODATA_SEGMENT,
0d705e9f 71 OPTION_TLDATA_SEGMENT,
f05eb3b7
AM
72 OPTION_TRADITIONAL_FORMAT,
73 OPTION_UR,
74 OPTION_VERBOSE,
75 OPTION_VERSION,
76 OPTION_VERSION_SCRIPT,
77 OPTION_VERSION_EXPORTS_SECTION,
78 OPTION_DYNAMIC_LIST,
79 OPTION_DYNAMIC_LIST_CPP_NEW,
80 OPTION_DYNAMIC_LIST_CPP_TYPEINFO,
81 OPTION_DYNAMIC_LIST_DATA,
82 OPTION_WARN_COMMON,
83 OPTION_WARN_CONSTRUCTORS,
84 OPTION_WARN_FATAL,
85 OPTION_NO_WARN_FATAL,
86 OPTION_WARN_MULTIPLE_GP,
87 OPTION_WARN_ONCE,
88 OPTION_WARN_SECTION_ALIGN,
89 OPTION_SPLIT_BY_RELOC,
90 OPTION_SPLIT_BY_FILE ,
91 OPTION_WHOLE_ARCHIVE,
92 OPTION_ADD_DT_NEEDED_FOR_DYNAMIC,
93 OPTION_NO_ADD_DT_NEEDED_FOR_DYNAMIC,
94 OPTION_ADD_DT_NEEDED_FOR_REGULAR,
95 OPTION_NO_ADD_DT_NEEDED_FOR_REGULAR,
96 OPTION_WRAP,
97 OPTION_FORCE_EXE_SUFFIX,
98 OPTION_GC_SECTIONS,
99 OPTION_NO_GC_SECTIONS,
100 OPTION_PRINT_GC_SECTIONS,
101 OPTION_NO_PRINT_GC_SECTIONS,
102 OPTION_HASH_SIZE,
103 OPTION_CHECK_SECTIONS,
104 OPTION_NO_CHECK_SECTIONS,
105 OPTION_NO_UNDEFINED,
106 OPTION_INIT,
107 OPTION_FINI,
108 OPTION_SECTION_START,
109 OPTION_UNIQUE,
110 OPTION_TARGET_HELP,
111 OPTION_ALLOW_SHLIB_UNDEFINED,
112 OPTION_NO_ALLOW_SHLIB_UNDEFINED,
113 OPTION_ALLOW_MULTIPLE_DEFINITION,
114 OPTION_NO_UNDEFINED_VERSION,
115 OPTION_DEFAULT_SYMVER,
116 OPTION_DEFAULT_IMPORTED_SYMVER,
117 OPTION_DISCARD_NONE,
118 OPTION_SPARE_DYNAMIC_TAGS,
119 OPTION_NO_DEFINE_COMMON,
120 OPTION_NOSTDLIB,
121 OPTION_NO_OMAGIC,
122 OPTION_STRIP_DISCARDED,
123 OPTION_NO_STRIP_DISCARDED,
124 OPTION_ACCEPT_UNKNOWN_INPUT_ARCH,
125 OPTION_NO_ACCEPT_UNKNOWN_INPUT_ARCH,
126 OPTION_PIE,
127 OPTION_UNRESOLVED_SYMBOLS,
128 OPTION_WARN_UNRESOLVED_SYMBOLS,
129 OPTION_ERROR_UNRESOLVED_SYMBOLS,
130 OPTION_WARN_SHARED_TEXTREL,
131 OPTION_WARN_ALTERNATE_EM,
132 OPTION_REDUCE_MEMORY_OVERHEADS,
133#ifdef ENABLE_PLUGINS
134 OPTION_PLUGIN,
135 OPTION_PLUGIN_OPT,
136#endif /* ENABLE_PLUGINS */
137 OPTION_DEFAULT_SCRIPT,
138 OPTION_PRINT_OUTPUT_FORMAT,
cb9322a8 139 OPTION_PRINT_SYSROOT,
0e86e20e 140 OPTION_IGNORE_UNRESOLVED_SYMBOL,
26278bb8
UD
141 OPTION_PUSH_STATE,
142 OPTION_POP_STATE,
f05eb3b7
AM
143};
144
252b5132
RH
145/* The initial parser states. */
146typedef enum input_enum {
147 input_selected, /* We've set the initial state. */
148 input_script,
149 input_mri_script,
150 input_version_script,
55255dae 151 input_dynamic_list,
252b5132
RH
152 input_defsym
153} input_type;
154
155extern input_type parser_input;
156
157extern unsigned int lineno;
158extern const char *lex_string;
159
160/* In ldlex.l. */
1579bae1 161extern int yylex (void);
f4a23d42 162extern void lex_push_file (FILE *, const char *, unsigned int);
dab69f68 163extern void lex_redirect (const char *, const char *, unsigned int);
1579bae1 164extern void ldlex_script (void);
eeed9cc7 165extern void ldlex_inputlist (void);
1579bae1
AM
166extern void ldlex_mri_script (void);
167extern void ldlex_version_script (void);
168extern void ldlex_version_file (void);
169extern void ldlex_defsym (void);
170extern void ldlex_expression (void);
171extern void ldlex_both (void);
172extern void ldlex_command (void);
173extern void ldlex_popstate (void);
dab69f68 174extern const char* ldlex_filename (void);
252b5132
RH
175
176/* In lexsup.c. */
1579bae1
AM
177extern int lex_input (void);
178extern void lex_unput (int);
252b5132 179#ifndef yywrap
1579bae1 180extern int yywrap (void);
252b5132 181#endif
1579bae1 182extern void parse_args (unsigned, char **);
252b5132
RH
183
184#endif
This page took 0.768203 seconds and 4 git commands to generate.