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: Difference between --oformat binary, and objcopy -O binary of --oformat elf32-i386


On Wed, Jul 20, 2016 at 2:40 AM, Nick Clifton <nickc@redhat.com> wrote:
>
>> When you talk about deprecating --oformat use, do you also mean
>> deprecating OUTPUT_FORMAT in the linker scripts? The problem is seen
>> with both, as they seem to be aliases with --oformat overriding the
>> other one.
>
> I do mean both methods. although now that I have thought about it, deprecating
> is too strong a term.  What I am contemplating is whether it would be a good
> idea for --oformat (or OUTPUT_FORMAT) to fail if the requested output file format
> was not the similar to the input file format.  Perhaps with exceptions for targets
> where the translation is known to work.  This is just an idea though, I have not
> tried writing any code to implement it yet.

For what it's worth, gold handles --oformat correctly for those values
that it supports (which is to say: --oformat=binary): it generates the
output file in the usual way, and then converts it to binary at the
end.

Ian


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