[syslinux] Linker script assertion with binutils 2.21

Colin Watson cjwatson at ubuntu.com
Mon Jan 17 06:53:16 PST 2011


dos/syslinux.elf fails to build on current Ubuntu Natty (binutils 2.21)
as follows:

  ld -m elf_i386 -T dosexe.ld -o syslinux.elf header.o crt0.o ldlinux.o syslinux.o fat.o syslxmod.o syslxopt.o setadv.o getopt_long.o bootsect_bin.o mbr_bin.o cache.o fatchain.o open.o searchdir.o libcom.a
  /usr/bin/ld.bfd.real: syslinux_ldlinux_size must equal the size of .payload
  /usr/bin/ld.bfd.real: syslinux_ldlinux_size must equal the size of .payload

'objdump -t ldlinux.o' looks reasonable:

  SYMBOL TABLE:
  00000000 l    d  .text  00000000 .text
  00000000 l    d  .data  00000000 .data
  00000000 l    d  .bss   00000000 .bss
  00000000 l    d  .payload       00000000 .payload
  00000000 l    d  .rodata        00000000 .rodata
  00000000 g       .payload       00007c00 syslinux_ldlinux
  00007c00 g       *ABS*  00000000 syslinux_ldlinux_size
  00000000 g       .rodata        00000004 syslinux_ldlinux_len

Our toolchain packager pointed me at
http://sources.redhat.com/git/?p=binutils.git;a=commitdiff;h=557189b0dd1f3dec6b00b91b9b0c5459ece72a52,
which indeed seems like a likely cause of this kind of failure.
However, I'm having a hard time pinning down what the problem might be.
Does anyone more familiar with linker scripts than me know?

Thanks,

-- 
Colin Watson                                       [cjwatson at ubuntu.com]




More information about the Syslinux mailing list