summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Stump <mrs@apple.com>2001-11-29 00:51:58 +0000
committerMike Stump <mrs@apple.com>2001-11-29 00:51:58 +0000
commit71c3db1aa3dcbf8d660f5298aa9fd830dba4a678 (patch)
tree955922a83b79ee854a71b9a014b1e17fba9021c7
parentc66631307f9f87b2a1557163b6d238cc018aade3 (diff)
downloadbinutils-redhat-71c3db1aa3dcbf8d660f5298aa9fd830dba4a678.tar.gz
* objcopy.c (setup_section): Preserve SEC_RELOC when
--set-section-flags is used.
-rw-r--r--binutils/ChangeLog5
-rw-r--r--binutils/objcopy.c2
2 files changed, 6 insertions, 1 deletions
diff --git a/binutils/ChangeLog b/binutils/ChangeLog
index 1eb553ec98..2066770735 100644
--- a/binutils/ChangeLog
+++ b/binutils/ChangeLog
@@ -1,3 +1,8 @@
+2001-11-28 Mike Stump <mrs@wrs.com>
+
+ * objcopy.c (setup_section): Preserve SEC_RELOC when
+ --set-section-flags is used.
+
2001-11-19 Nick Clifton <nickc@cambridge.redhat.com>
* readelf.c (do_debug_str): New variable.
diff --git a/binutils/objcopy.c b/binutils/objcopy.c
index 03ec035ce3..b42fbe90d5 100644
--- a/binutils/objcopy.c
+++ b/binutils/objcopy.c
@@ -1595,7 +1595,7 @@ setup_section (ibfd, isection, obfdarg)
}
if (p != NULL && p->set_flags)
- flags = p->flags | (flags & SEC_HAS_CONTENTS);
+ flags = p->flags | (flags & (SEC_HAS_CONTENTS | SEC_RELOC));
if (!bfd_set_section_flags (obfd, osection, flags))
{
err = _("flags");