Date: Tue, 13 Jun 2000 13:15:44 +0300 (IDT) From: Eli Zaretskii X-Sender: eliz AT is To: Richard Dawe cc: djgpp AT delorie DOT com Subject: Re: Using strip --strip-debug on libraries In-Reply-To: <3943FF16.E1454F6B@phekda.freeserve.co.uk> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On Sun, 11 Jun 2000, Richard Dawe wrote: > The other day I ran strip with the '--strip-debug' option on a library. > The library I ran it had several files named 'init.o' within. I found that > after stripping, there was only one file called 'init.o'. Is strip > supposed to work this way? It seems counter-intuitive to me that strip > would rewrite the archive's table o'contents (TOC). That `strip' rewrites the TOC seems reasonable: it rewrites the entire archive, after all. What you need to make sure that it leaves the last copy of init.o in the archive and removes the rest. A more importtant question is: how did that library wind up with more than a single copy of init.o in it? Libraries aren't supposed to behave that way, unless you use `ar' incorrectly (e.g., "ar q" with a non-empty library).