This is the mail archive of the binutils@sourceware.cygnus.com 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]

Linking of ARM-elf object files


"Lim, Sung-taek" wrote:
> 
> So I modified binutils-991229 (which supports thumb-elf) and my example
> program worked successfully with gdb instruction set simulator. I just changed
> the digit 4 at line 897 of binutils-991229/bfd/elf32-arm.h to 8.
> Any comment is welcome.

 I wrote:

>> For arm-elf the '991130' and newer binutils seem to be broken. The
>> linked executables will not load into older or current GDBs (like Insight).

 When you write that the program works ok under GDB, this is against my experiences.
Trying again, now the binutils-20000116, for arm-elf showed that the linker still
doesn't produce executables which could run under GDB and the simulator... My host
is Linux-libc5 (S.u.S.E. 5.2) and the binutils were built with egcs-1.1.2... And I
tried the executables with Insight-19991207...

 My test executables will become about two times bigger than those produced with a
working linker (990426) and the 'readelf -a' shows about them something like :

----------------------- clip ---------------------------------
ELF Header:
  Magic:   7f 45 4c 46 01 01 01 61 00 00 00 00 00 00 00 00
  Class:                             ELF32
  Data:                              2's complement, little endian
  Version:                           1 (current)
  OS/ABI:                            <unknown: 61>
  ABI Version:                       0
  Type:                              EXEC (Executable file)
  Machine:                           ARM
  Version:                           0x1
  Entry point address:               0x800c
  Start of program headers:          52 (bytes into file)
  Start of section headers:          66452 (bytes into file)
  Flags:                             0x0
  Size of this header:               52 (bytes)
  Size of program headers:           32 (bytes)
  Number of program headers:         1
  Size of section headers:           40 (bytes)
  Number of section headers:         11
  Section header string table index: 8
----------------------- clip ---------------------------------

in the beginning, while the working executables have :

----------------------- clip ---------------------------------
ELF Header:
  Magic:   7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00
  Class:                             ELF32
  Data:                              2's complement, little endian
  Version:                           1 (current)
  OS/ABI:                            UNIX - System V
  ABI Version:                       0
  Type:                              EXEC (Executable file)
  Machine:                           ARM
  Version:                           0x1
  Entry point address:               0x800c
  Start of program headers:          52 (bytes into file)
  Start of section headers:          33544 (bytes into file)
  Flags:                             0x0
  Size of this header:               52 (bytes)
  Size of program headers:           32 (bytes)
  Number of program headers:         2
  Size of section headers:           40 (bytes)
  Number of section headers:         11
  Section header string table index: 8
----------------------- clip ---------------------------------

 So the 'OS/ABI' is a '<unknown: 61>' in the new unworking 'arm-elf'
executables etc.

 Could someone please give some explanation into this?  There are some
clues in the Linux/ARM webpages saying that the current binutils have
broken the compatability with the arm-linux-gnu target... But I haven't
seen anywhere any notes about the plain-vanilla arm-elf being 'under
construction' and the linker in them being now totally unusable, as my
experiences since trying the 991130 sanapshots have shown...

 Or is the problem somehow tied to the Linux-libc5 ?  I haven't tried
other hosts yet (Linux-libc6 and Win32 are possible).

Regards, Kai


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