diff options
author | Ian Lance Taylor <ian@airs.com> | 2009-12-31 03:48:46 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@airs.com> | 2009-12-31 03:48:46 +0000 |
commit | d7bb5745008bb111becc3dc87e7ce243f59b7170 (patch) | |
tree | 90278a6e9c9daca6652c0e8c90ddfc77ef9accee /gold/layout.h | |
parent | fc59c57250878209dbcacd68712643d88b1c7adc (diff) | |
download | gdb-d7bb5745008bb111becc3dc87e7ce243f59b7170.zip gdb-d7bb5745008bb111becc3dc87e7ce243f59b7170.tar.gz gdb-d7bb5745008bb111becc3dc87e7ce243f59b7170.tar.bz2 |
PR 10979
* script.cc (read_input_script): If we see a new SECTIONS clause,
and we have added an input section, give an error.
* layout.h (class Layout): Add have_added_input_section function.
Add have_added_input_section_ field.
* layout.cc (Layout::Layout): Initialize
have_added_input_section_.
(Layout::layout): Set have_added_input_section_.
(Layout::layout_eh_frame): Likewise.
Diffstat (limited to 'gold/layout.h')
-rw-r--r-- | gold/layout.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/gold/layout.h b/gold/layout.h index 06060ef..604f19b 100644 --- a/gold/layout.h +++ b/gold/layout.h @@ -433,6 +433,11 @@ class Layout is_linkonce(const char* name) { return strncmp(name, ".gnu.linkonce", sizeof(".gnu.linkonce") - 1) == 0; } + // Whether we have added an input section. + bool + have_added_input_section() const + { return this->have_added_input_section_; } + // Return true if a section is a debugging section. static inline bool is_debug_info_section(const char* name) @@ -990,6 +995,8 @@ class Layout Group_signatures group_signatures_; // The size of the output file. off_t output_file_size_; + // Whether we have added an input section to an output section. + bool have_added_input_section_; // Whether we have attached the sections to the segments. bool sections_are_attached_; // Whether we have seen an object file marked to require an |