aboutsummaryrefslogtreecommitdiff
path: root/binutils/binutils.texi
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1995-02-17 19:21:24 +0000
committerIan Lance Taylor <ian@airs.com>1995-02-17 19:21:24 +0000
commit5ab41086ca8752af8f088ec86fb667e581ce3882 (patch)
treebec568e3c3c0a91564f95b9e30d502058d5e6310 /binutils/binutils.texi
parentebb6075d2a66fe44ef4499c4c21c509172d3f448 (diff)
downloadgdb-5ab41086ca8752af8f088ec86fb667e581ce3882.zip
gdb-5ab41086ca8752af8f088ec86fb667e581ce3882.tar.gz
gdb-5ab41086ca8752af8f088ec86fb667e581ce3882.tar.bz2
* objcopy.c (struct section_list): Add fields remove, set_flags,
and flags. Change adjust from boolean to enum. (remove_sections): Remove static variable. (sections_removed): New static variable. (copy_options): Add --set-section-flags. (copy_usage): Mention --set-section-flags. (parse_flags): New static function. (find_section_list): New static function. (is_strip_symbol): Change return type from int to boolean. (is_strip_section): New static function. (filter_symbols): Call is_strip_section. (copy_object): When adding sections, check for specified flags or VMA. Call filter_symbols if any sections are being removed. (setup_section): Use find_section_list function rather than looking through remove_sections and adjust_sections. Handle --set-section-flags. (copy_section): Use find_section_list rather than looking through remove_sections. (strip_main): Use find_section_list instead of adding items to sections_removed. (copy_main): Use find_section_list instead of adding items to sections_removed and adjust_sections. Handle --set-section-flags. * binutils.texi, objcopy.1: Document --set-section-flags.
Diffstat (limited to 'binutils/binutils.texi')
-rw-r--r--binutils/binutils.texi8
1 files changed, 8 insertions, 0 deletions
diff --git a/binutils/binutils.texi b/binutils/binutils.texi
index 5c977bd..bbf2463 100644
--- a/binutils/binutils.texi
+++ b/binutils/binutils.texi
@@ -753,6 +753,7 @@ objcopy [ -F @var{bfdname} | --target=@var{bfdname} ]
[ --adjust-vma=@var{incr} ]
[ --adjust-section-vma=@var{section}@{=,+,-@}@var{val} ]
[ --adjust-warnings ] [ --no-adjust-warnings ]
+ [ --set-section-flags=@var{section}=@var{flags} ]
[ --add-section=@var{sectionname}=@var{filename} ]
[ -v | --verbose ] [ -V | --version ] [ --help ]
@var{infile} [@var{outfile}]
@@ -897,6 +898,13 @@ exist, issue a warning. This is the default.
Do not issue a warning if @samp{--adjust-section-vma} is used, even if
the named section does not exist.
+@item --set-section-flags @var{section}=@var{flags}
+Set the flags for the named section. The @var{flags} argument is a
+comma separated string of flag names. The recognized names are
+@samp{alloc}, @samp{load}, @samp{readonly}, @samp{code}, @samp{data},
+and @samp{rom}. Not all flags are meaningful for all object file
+formats.
+
@item --add-section @var{sectionname}=@var{filename}
Add a new section named @var{sectionname} while copying the file. The
contents of the new section are taken from the file @var{filename}. The