public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] doc: Clarify that ‘--strip-unneeded’ implies ‘--strip-debug’
@ 2020-09-19 12:42 Ludovic Courtès
  2020-09-21 15:10 ` Nick Clifton
  0 siblings, 1 reply; 2+ messages in thread
From: Ludovic Courtès @ 2020-09-19 12:42 UTC (permalink / raw)
  To: binutils

[-- Attachment #1: Type: text/plain, Size: 666 bytes --]

Hello,

My reading of objcopy.c is that ‘--strip-unneeded’ implies
‘--strip-debug’:

--8<---------------cut here---------------start------------->8---
      else if ((flags & BSF_DEBUGGING) != 0)	/* Debugging symbol.  */
	keep = (strip_symbols != STRIP_DEBUG
		&& strip_symbols != STRIP_UNNEEDED
		&& ! convert_debugging);
--8<---------------cut here---------------end--------------->8---

What about the patch below to clarify that in the manual?

Thanks,
Ludo’.

binutils/ChangeLog

2020-09-19  Ludovic Courtès  <ludo@gnu.org>

	* doc/binutils.texi (objcopy, strip): Say that
        '--strip-unneeded' implies '--strip-debug'.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Type: text/x-patch, Size: 1061 bytes --]

diff --git a/binutils/doc/binutils.texi b/binutils/doc/binutils.texi
index 35a5a67041e..f0ef78eda1d 100644
--- a/binutils/doc/binutils.texi
+++ b/binutils/doc/binutils.texi
@@ -1410,7 +1410,9 @@ Do not copy relocation and symbol information from the source file.
 Do not copy debugging symbols or sections from the source file.
 
 @item --strip-unneeded
-Strip all symbols that are not needed for relocation processing.
+Strip all symbols that are not needed for relocation processing in
+addition to debugging symbols and sections stripped by
+@option{--strip-debug}.
 
 @item -K @var{symbolname}
 @itemx --keep-symbol=@var{symbolname}
@@ -3387,7 +3389,9 @@ See the description of this option in the @command{objcopy} section
 for more information.
 
 @item --strip-unneeded
-Remove all symbols that are not needed for relocation processing.
+Remove all symbols that are not needed for relocation processing in
+addition to debugging symbols and sections stripped by
+@option{--strip-debug}.
 
 @item -K @var{symbolname}
 @itemx --keep-symbol=@var{symbolname}

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] doc: Clarify that ‘--strip-unneeded’ implies ‘--strip-debug’
  2020-09-19 12:42 [PATCH] doc: Clarify that ‘--strip-unneeded’ implies ‘--strip-debug’ Ludovic Courtès
@ 2020-09-21 15:10 ` Nick Clifton
  0 siblings, 0 replies; 2+ messages in thread
From: Nick Clifton @ 2020-09-21 15:10 UTC (permalink / raw)
  To: Ludovic Courtès, binutils

Hi Ludovic,

> 2020-09-19  Ludovic Courtès  <ludo@gnu.org>
> 
> 	* doc/binutils.texi (objcopy, strip): Say that
>         '--strip-unneeded' implies '--strip-debug'.

Approved and applied.

Cheers
  Nick


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-09-21 15:10 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-19 12:42 [PATCH] doc: Clarify that ‘--strip-unneeded’ implies ‘--strip-debug’ Ludovic Courtès
2020-09-21 15:10 ` Nick Clifton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).