aboutsummaryrefslogtreecommitdiff
path: root/ld/ldlang.h
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2020-11-24 23:41:31 +1030
committerAlan Modra <amodra@gmail.com>2020-11-25 19:13:51 +1030
commit21401fc7bf67dbf73f4a3eda4bcfc58fa4211584 (patch)
treee3c07e14b0b760173b5abeb0269a191352cec45e /ld/ldlang.h
parent6595cf3ce81572a8941bd9d16d6518091e6e6937 (diff)
downloadgdb-21401fc7bf67dbf73f4a3eda4bcfc58fa4211584.zip
gdb-21401fc7bf67dbf73f4a3eda4bcfc58fa4211584.tar.gz
gdb-21401fc7bf67dbf73f4a3eda4bcfc58fa4211584.tar.bz2
Duplicate output sections in scripts
Previously, ld merged duplicate output sections if such existed in scripts, except for those with a constraint of SPECIAL. This makes scripts with duplicate output section statements create duplicate output sections in the linker output file. * ldlang.c (lang_output_section_statement_lookup): Change "create" parameter to a tristate, if 2 then always create a new output section statement. Update all callers, with lang_enter_output_section_statement using "2". (map_input_to_output_sections): Don't ignore SPECIAL constraint here. * ldlang.h (lang_output_section_statement_type): Update prototype. (lang_output_section_find): Update.
Diffstat (limited to 'ld/ldlang.h')
-rw-r--r--ld/ldlang.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/ld/ldlang.h b/ld/ldlang.h
index 6675c57..0f1b607 100644
--- a/ld/ldlang.h
+++ b/ld/ldlang.h
@@ -586,7 +586,7 @@ extern asection *section_for_dot
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);
@@ -605,7 +605,7 @@ extern void lang_add_keepsyms_file
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