[U-Boot-Users] Problems compiling u-boot for AMCC katmai board

Wolfgang Denk wd at denx.de
Fri May 11 22:07:34 CEST 2007


In message <2315F4A3362D0045AA06DFA9999664EC02527255 at MAILNA1.global.cadence.com> you wrote:
> 
> I am having a "learning experience" in trying to compile u-boot for the
> AMCC Katmai board.  It always gets through the entire build, right up to
> the final
> link stage.  The linking is failing with the .bss section overlapping
> the .resetvec section, and several episodes of  "relocation truncated to
> fit."

That means the code is too big. Strange.

> I've reproduced my errors with a CROSSTOOL cross-compiler GCC
> 4.0.0/GLIBC 2.3.5, and with a similar cross-compiler GCC 3.4.1/GLIBC
> 2.3.3.

Hm... GCC 3.4.x is certainly a good candidate for nasty surprises, but
GCC 4.0.0 should work sufficiently well. We use GCC-4.0.0 in ELDK
version 4.0, too, and it works just fine.

Even older versions work. For example:

ELDK 3.1.1: GCC 3.3.3 ==>  __bss_start = 0xffffd200

ELDK 4.1:   GCC 4.0.0 ==>  __bss_start = 0xffff8f00

As you can see, GCC 4.0.0 is a bit better in terms of optimizations -
we have 28.25 kB instead of 11.5 kB free room at the end of the image.

Ummm.. maybe you are running a broken version of the binutils?

> To those who have successfully built the Katmai u-boot binaries (and I
> know you're out there!) I ask:  how did you do it?  What
> compiler/toolchain/cross-compiler, etc
> did you use?

Any ELDK version 3.x or 4.x should work just fine. Tested again with  ELDK
3.1.1 and 4.0 and 4.1

> /opt/crosstool/gcc-4.0.0-glibc-2.3.5/powerpc-440-linux-gnu/bin/powerpc-4
> 40-linux-gnu-ld: section .bss [00000000ffff8e00 -> 000000010004750f]
> overlaps section .resetvec [00000000fffffffc -> 00000000ffffffff]

Ummm... Your linker seems to assume we had 64 bit addresses, which is
not the case. Please configure your binutils to use 32 bit addresses
only.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,    CEO: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
I have often regretted my speech, never my silence.




More information about the U-Boot mailing list