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: extra alignment/padding when using pe-i386


Dave Korn wrote:

>> If there's not an easy way to avoid this with the standard
>> mingw or cygwin, I'll have to step back and assess whether I want to
>> have to build and support a cross environment just for this.
> 
>   If all you need is an assembler and not a compiler, it's really really easy;
> building cross-binutils is trivial compared to building a cross-gcc.

  And by "easy", I mean that in the time since my last post I compiled binutils
with '--target=i386-linux-redhat' (to match your example), and tested that it
gives the results you want:

> admin@ubik /tmp/i386-redhat-linux
> $ ./gas/.libs/as-new.exe ../bar.s -o bar.o
> 
> admin@ubik /tmp/i386-redhat-linux
> $ objdump.exe -s bar.o
> 
> bar.o:     file format elf32-i386
> 
> Contents of section .data:
>  0000 0100                                 ..
> 
> admin@ubik /tmp/i386-redhat-linux
> $

  Anyway.  It depends how you plan on getting the data out of the relocatable
object files, anyway, and whether you were planning on a link step or not, and
how much grief you'd get in deploying the packages, but the actual building is
trivial.

    cheers,
      DaveK






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