This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Adding new section to core file


On Mon, Apr 06, 2015 at 07:00:00PM +0530, vaibhav sinha wrote:
> As I understand, core files are also in ELF format. I want to add a
> new section to the core file. I know how to do that for an executable
> using objcopy, as shown below:

But, you didn't "do that for an executable".  You added the extra
section to a relocatable object file.  That is very different from
adding a section to an executable (or core file).  Generally, you
can't successfully change executables using objcopy in ways that
require addresses to change.

-- 
Alan Modra
Australia Development Lab, IBM


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]