diff options
author | Nick Clifton <nickc@redhat.com> | 2006-09-05 08:22:27 +0000 |
---|---|---|
committer | Nick Clifton <nickc@redhat.com> | 2006-09-05 08:22:27 +0000 |
commit | 91bb255c67ce378e25576a12e6b24929c45c92fc (patch) | |
tree | 9e6bf98bdd502886db12dbfb86ad1f2db13d24a2 /binutils/objcopy.c | |
parent | a0d64f3a09dd00e54a3d0310d36e5e24084cefbd (diff) | |
download | gdb-91bb255c67ce378e25576a12e6b24929c45c92fc.zip gdb-91bb255c67ce378e25576a12e6b24929c45c92fc.tar.gz gdb-91bb255c67ce378e25576a12e6b24929c45c92fc.tar.bz2 |
PR binutils/3166
* objcopy.c (is_strip_section): Do not treat group sections as debugging sections.
* doc/binutils.texi (--only-keep-debug): Document that this switch is only intended for use on fully linked files.
Diffstat (limited to 'binutils/objcopy.c')
-rw-r--r-- | binutils/objcopy.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/binutils/objcopy.c b/binutils/objcopy.c index 0d56845..8db5ef0 100644 --- a/binutils/objcopy.c +++ b/binutils/objcopy.c @@ -815,6 +815,13 @@ is_strip_section (bfd *abfd ATTRIBUTE_UNUSED, asection *sec) return FALSE; } + /* PR binutils/3166 + Group sections look like debugging sections but they are not. + (They have a non-zero size but they are not ALLOCated). */ + if ((bfd_get_section_flags (abfd, sec) & SEC_GROUP) != 0 + && strip_symbols == STRIP_NONDEBUG) + return TRUE; + return FALSE; } |