bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: BUG elf32-i386 R_386_PC32 done wrong


From: Airr
Subject: Re: BUG elf32-i386 R_386_PC32 done wrong
Date: Sat, 24 Jun 2006 15:16:10 -0400
User-agent: Thunderbird 1.5.0.4 (X11/20060516)

Ian Lance Taylor wrote:

Greetings, Ian, et all.


You want to convert from .obj
files, presumably in the Windows PE/COFF object file format, to object
files in the ELF file format?  If you want to do that conversion, then
subtracting 4 from the contents of the section for PC relative relocs
is the least of the issues you are going to have to deal with.

Yes, that's the crux of it.

As of late yesterday evening, we've been able to get this to work by linking the .obj (PE/COFF) files with ld emitting a PE executable, and then using objcopy to convert to the final ELF executable.

Binutils 2.16.1 compiled with "--enable-targets=i386-pe" on a Linux box.


What we had been doing prior was attempting to bypass the objcopy step
and have ld perform the conversion from PE/COFF to ELF directly (with
the appropriate switches, of course).  It's at this point that the reloc
issue popped up.

So, is it safe to assume that attempting the conversion using ld alone will not produce a working ELF file in our case? That instead we should use objcopy to produce the final file?

Thanks for your time and patience,

Armando Rivera






reply via email to

[Prev in Thread] Current Thread [Next in Thread]