/* ldlang.h - linker command language support
- Copyright (C) 1991-2019 Free Software Foundation, Inc.
+ Copyright (C) 1991-2021 Free Software Foundation, Inc.
This file is part of the GNU Binutils.
#define DEFAULT_MEMORY_REGION "*default*"
+#define SECTION_NAME_MAP_LENGTH (16)
+
typedef enum
{
lang_input_file_is_l_enum,
unsigned int after_end : 1;
/* If this section uses the alignment of its input sections. */
unsigned int align_lma_with_input : 1;
+ /* If script has duplicate output section statements of the same name
+ create duplicate output sections. */
+ unsigned int dup_output : 1;
} lang_output_section_statement_type;
typedef struct
/* Set if reloading an archive or --as-needed lib. */
unsigned int reload : 1;
-#ifdef ENABLE_PLUGINS
+#if BFD_SUPPORTS_PLUGINS
/* Set if the file was claimed by a plugin. */
unsigned int claimed : 1;
/* Set if added by the lto plugin add_input_file callback. */
unsigned int lto_output : 1;
-#endif /* ENABLE_PLUGINS */
+#endif /* BFD_SUPPORTS_PLUGINS */
/* Head of list of pushed flags. */
struct lang_input_statement_flags *pushed;
Usually the same as filename, but for a file spec'd with
-l this is the -l switch itself rather than the filename. */
const char *local_sym_name;
+ /* Extra search path. Used to find a file relative to the
+ directory of the current linker script. */
+ const char *extra_search_path;
bfd *the_bfd;
extern lang_statement_list_type file_chain;
extern lang_statement_list_type input_file_chain;
+extern struct bfd_elf_dynamic_list **current_dynamic_list_p;
+
extern int lang_statement_iteration;
extern struct asneeded_minfo **asneeded_list_tail;
#define LANG_FOR_EACH_INPUT_STATEMENT(statement) \
lang_input_statement_type *statement; \
- for (statement = &file_chain.head->input_statement; \
+ for (statement = (lang_input_statement_type *) file_chain.head; \
statement != NULL; \
statement = statement->next)
#define lang_output_section_find(NAME) \
- lang_output_section_statement_lookup (NAME, 0, FALSE)
+ lang_output_section_statement_lookup (NAME, 0, 0)
extern void lang_process
(void);
extern lang_output_section_statement_type *lang_output_section_get
(const asection *);
extern lang_output_section_statement_type *lang_output_section_statement_lookup
- (const char *, int, bfd_boolean);
+ (const char *, int, int);
extern lang_output_section_statement_type *next_matching_output_section_statement
(lang_output_section_statement_type *, int);
extern void ldlang_add_undef
(struct bfd_elf_version_deps *, const char *);
extern void lang_register_vers_node
(const char *, struct bfd_elf_version_tree *, struct bfd_elf_version_deps *);
-extern void lang_append_dynamic_list (struct bfd_elf_version_expr *);
+extern void lang_append_dynamic_list (struct bfd_elf_dynamic_list **,
+ struct bfd_elf_version_expr *);
extern void lang_append_dynamic_list_cpp_typeinfo (void);
extern void lang_append_dynamic_list_cpp_new (void);
extern void lang_add_unique
struct elf_sym_strtab;
struct elf_strtab_hash;
-extern void ldlang_ctf_apply_strsym
- (struct elf_sym_strtab *, bfd_size_type, struct elf_strtab_hash *);
+extern void ldlang_ctf_acquire_strings
+ (struct elf_strtab_hash *);
+extern void ldlang_ctf_new_dynsym
+ (int symidx, struct elf_internal_sym *);
extern void ldlang_write_ctf_late
(void);
extern bfd_boolean
extern void
lang_add_gc_name (const char *);
+extern bfd_boolean
+print_one_symbol (struct bfd_link_hash_entry *hash_entry, void *ptr);
+
#endif