]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - ld/ldfile.h
bus error with fuzzed archive element
[thirdparty/binutils-gdb.git] / ld / ldfile.h
CommitLineData
252b5132 1/* ldfile.h -
fd67aa11 2 Copyright (C) 1991-2024 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 20
b71e2778
AM
21#ifndef LDFILE_H
22#define LDFILE_H
23
f38a2680 24extern bool ldfile_assumed_script;
252b5132
RH
25extern unsigned long ldfile_output_machine;
26extern enum bfd_architecture ldfile_output_architecture;
27extern const char *ldfile_output_machine_name;
28
29/* Structure used to hold the list of directories to search for
30 libraries. */
31
89cdebba 32typedef struct search_dirs {
252b5132
RH
33 /* Next directory on list. */
34 struct search_dirs *next;
35 /* Name of directory. */
36 const char *name;
b34976b6 37 /* TRUE if this is from the command line. */
f38a2680 38 bool cmdline;
252b5132
RH
39} search_dirs_type;
40
41extern search_dirs_type *search_head;
42
b34976b6 43extern void ldfile_add_arch
1579bae1 44 (const char *);
b34976b6 45extern void ldfile_add_library_path
f38a2680 46 (const char *, bool cmdline);
b34976b6 47extern void ldfile_open_command_file
1579bae1 48 (const char *name);
6ec6968b
NC
49extern void ldfile_open_script_file
50 (const char *name);
7d24f02c
KH
51extern void ldfile_open_default_command_file
52 (const char *name);
b34976b6 53extern void ldfile_open_file
1579bae1 54 (struct lang_input_statement_struct *);
f38a2680 55extern bool ldfile_try_open_bfd
1579bae1 56 (const char *, struct lang_input_statement_struct *);
b34976b6 57extern void ldfile_set_output_arch
5e2f1575 58 (const char *, enum bfd_architecture);
f38a2680 59extern bool ldfile_open_file_search
1579bae1
AM
60 (const char *arch, struct lang_input_statement_struct *,
61 const char *lib, const char *suffix);
b71e2778 62
fb221fba
NC
63extern void ldfile_add_remap
64 (const char *, const char *);
65extern bool ldfile_add_remap_file
66 (const char *);
67extern void ldfile_remap_input_free
68 (void);
69extern const char * ldfile_possibly_remap_input
70 (const char *);
71extern void ldfile_print_input_remaps
72 (void);
73
b71e2778 74#endif