This is the mail archive of the binutils@sources.redhat.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]

GCC 3.0 fails to bootstrap for mips-sgi-irix5.3 with gas 2.11.2


I've tried to bootstrap GCC 3.0 on IRIX 6.2 for the mips-sgi-irix5.3 target
with gas 2.11.2 configured for the same target.  Unfortunately, the
bootstrap fails early in stage 2, when the system linker fails to link
gengenrtl: 

stage1/xgcc -Bstage1/ -B/vol/gcc/share/mips-sgi-irix5.3/bin/  -DIN_GCC    -O2 -save-temps -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wtraditional -pedantic -Wno-long-long  -DHAVE_CONFIG_H -DGENERATOR_FILE  -o gengenrtl \
 gengenrtl.o ` case "obstack.o" in ?*) echo obstack.o ;; esac ` ` case "alloca.o" in ?*) echo alloca.o ;; esac ` ` case "" in ?*) echo  ;; esac ` ` case "" in ?*) echo  ;; esac ` ` case "" in ?*) echo  ;; esac ` ` case "" in ?*) echo  ;; esac ` -lmld -lmalloc
ld: FATAL 11: Object file format error (gengenrtl.o): invalid section offset
collect2: ld returned 4 exit status

This happens both with the /usr/lib/ld originally installed as well as with
the latest /usr/lib/ld patch 3944.

Investigating the incriminated object with objdump, I noticed the
following:

Here's a table of sections, sorted by offset:

Offset     Size        Name

0x40       0x10f0      .text
0x1130     0x720       .data
0x1850     0           .bss
0x1850     0x18        .reginfo
0x1868     0x888       .mdebug		0x1868+0x888 = 0x20e8 + 0x8
0x20f0     0x15b0      .rodata
0x36a0     0x88        .shstrtab	0x36a0+0x88  = 0x3728 + 0x280
0x39a8     0x220       .symtab
0x3bc8     0x101       .strtab		0x3bc8+0x101 = 0x3cc9 + 0x3
0x3ccc     0x770       .rel.text
0x443c     0           .rela.text
0x443c     0xe28       .rel.data
0x5264     0           .rela.data
0x5264     0x330       .rel.rodata
0x5594     0           .rela.rodata

There's a large gap in the object file after .shstrtab, which certainly
cannot be accounted for by alignment requirements.  It may well be that
this accounts for the `invalid section offset' ld error.  Before I start
diving into libbfd sources, hopefully someone familiar with the code might
be able to direct me where to look for a fix.

	Rainer

-----------------------------------------------------------------------------
Rainer Orth, Faculty of Technology, Bielefeld University

Email: ro@TechFak.Uni-Bielefeld.DE


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