Re: [U-Boot] Build problem - ppmc7xx configuration

2014-05-25 Thread Vasili Galka
On Thu, May 22, 2014 at 10:39 PM, Vasili Galka vvv...@gmail.com wrote:
 On Thu, May 22, 2014 at 10:05 PM, Tom Rini tr...@ti.com wrote:

 On Thu, May 22, 2014 at 12:45:11PM +0300, Vasili Galka wrote:
  Hi,
 
  I'm trying to compile the v2014.04 tag using ppmc7xx configuration
  on
  Ubuntu using powerpc-none-eabi toolchain. I'm running the following:
 
  make CROSS_COMPILE=powerpc-none-eabi- O=out/ ppmc7xx_config
  make CROSS_COMPILE=powerpc-none-eabi- O=out/
 
  And receiving the following error:
  [...]
LDS u-boot.lds
LD  u-boot
  powerpc-none-eabi-ld.bfd:
 
  /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_lshrdi3.o):
  compiled normally and linked with modules compiled with -mrelocatable
  powerpc-none-eabi-ld.bfd: failed to merge target specific data of file
 
  /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_lshrdi3.o)
  powerpc-none-eabi-ld.bfd:
 
  /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_ashldi3.o):
  compiled normally and linked with modules compiled with -mrelocatable
  powerpc-none-eabi-ld.bfd: failed to merge target specific data of file
 
  /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_ashldi3.o)
  powerpc-none-eabi-ld.bfd:
 
  /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(crtresxgpr.o):
  compiled normally and linked with modules compiled with -mrelocatable
  powerpc-none-eabi-ld.bfd: failed to merge target specific data of file
 
  /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(crtresxgpr.o)
  make[1]: *** [u-boot] Error 1
  make: *** [sub-make] Error 2
 
  Can anyone please assist me in understanding the problem? Is something
  wrong with my toolchain? (I've built it myself)

 It's unhappy about toolchain provided libraries, so I lean yes, possible
 toolchain issue.  How did you generate your toolchain?  By hand?
 crosstool-ng? other?

 --
 Tom


 By hand. I wonder what exactly is wrong with it...
 arm-none-eabi toolchain generated by exactly same method works fine.

Hi Tom,

Looking into it showed that building U-Boot for powerpc configuration uses
-mrelocatable flag. So I have solved the problem by recompiling gcc with
CFLAGS_FOR_TARGET=-mrelocatable-lib.

However, this rises the following question. What is different between powerpc
build of U-Boot and all other architectures? Why only powerpc adds -mrelocatable
flag while all other architectures don't add it?

Original commit adding the flag:

 SHA-1: 858290178f222d998b6425d85cf06822467918f3

 * ppc: Enable full relocation to RAM

 The following changes allow U-Boot to fully relocate from flash to
 RAM:
  - Remove linker scripts' .fixup sections from the .text section
  - Add -mrelocatable to PLATFORM_RELFLAGS for all boards
  - Define CONFIG_RELOC_FIXUP_WORKS for all boards

 Previously, U-Boot would partially relocate, but statically initialized
 pointers needed to be manually relocated.

 Signed-off-by: Peter Tyser pty...@xes-inc.com

Best,
Vasili
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] Build problem - ppmc7xx configuration

2014-05-22 Thread Vasili Galka
Hi,

I'm trying to compile the v2014.04 tag using ppmc7xx configuration on
Ubuntu using powerpc-none-eabi toolchain. I'm running the following:

make CROSS_COMPILE=powerpc-none-eabi- O=out/ ppmc7xx_config
make CROSS_COMPILE=powerpc-none-eabi- O=out/

And receiving the following error:
[...]
  LDS u-boot.lds
  LD  u-boot
powerpc-none-eabi-ld.bfd:
/usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_lshrdi3.o):
compiled normally and linked with modules compiled with -mrelocatable
powerpc-none-eabi-ld.bfd: failed to merge target specific data of file
/usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_lshrdi3.o)
powerpc-none-eabi-ld.bfd:
/usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_ashldi3.o):
compiled normally and linked with modules compiled with -mrelocatable
powerpc-none-eabi-ld.bfd: failed to merge target specific data of file
/usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_ashldi3.o)
powerpc-none-eabi-ld.bfd:
/usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(crtresxgpr.o):
compiled normally and linked with modules compiled with -mrelocatable
powerpc-none-eabi-ld.bfd: failed to merge target specific data of file
/usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(crtresxgpr.o)
make[1]: *** [u-boot] Error 1
make: *** [sub-make] Error 2

Can anyone please assist me in understanding the problem? Is something
wrong with my toolchain? (I've built it myself)

Best regards,
Vasili
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] Build problem - ppmc7xx configuration

2014-05-22 Thread Wolfgang Denk
Dear Vasili,

In message CA+gZxsOZun38nNFgTGBYFMTJ7fYM_jvdOjYe8XT2B1e-=ni...@mail.gmail.com 
you wrote:
 
 I'm trying to compile the v2014.04 tag using ppmc7xx configuration on
 Ubuntu using powerpc-none-eabi toolchain. I'm running the following:
...
 And receiving the following error:
 [...]
   LDS u-boot.lds
   LD  u-boot
 powerpc-none-eabi-ld.bfd:
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_lshrdi3.o):
 compiled normally and linked with modules compiled with -mrelocatable
  ^

Well, is this not a pretty self-explanatory error message?

 Can anyone please assist me in understanding the problem? Is something
 wrong with my toolchain? (I've built it myself)

It appears your version of libgcc is not compatible.  You can either
use a known to be workign tool chain (ELDK comes to mind :-), or you
can use U-Boot's own version of the libgcc libraries by adding the
CONFIG_USE_PRIVATE_LIBGCC=y command line option.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH, MD: 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: w...@denx.de
I have often regretted my speech, never my silence.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] Build problem - ppmc7xx configuration

2014-05-22 Thread Tom Rini
On Thu, May 22, 2014 at 12:45:11PM +0300, Vasili Galka wrote:
 Hi,
 
 I'm trying to compile the v2014.04 tag using ppmc7xx configuration on
 Ubuntu using powerpc-none-eabi toolchain. I'm running the following:
 
 make CROSS_COMPILE=powerpc-none-eabi- O=out/ ppmc7xx_config
 make CROSS_COMPILE=powerpc-none-eabi- O=out/
 
 And receiving the following error:
 [...]
   LDS u-boot.lds
   LD  u-boot
 powerpc-none-eabi-ld.bfd:
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_lshrdi3.o):
 compiled normally and linked with modules compiled with -mrelocatable
 powerpc-none-eabi-ld.bfd: failed to merge target specific data of file
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_lshrdi3.o)
 powerpc-none-eabi-ld.bfd:
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_ashldi3.o):
 compiled normally and linked with modules compiled with -mrelocatable
 powerpc-none-eabi-ld.bfd: failed to merge target specific data of file
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_ashldi3.o)
 powerpc-none-eabi-ld.bfd:
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(crtresxgpr.o):
 compiled normally and linked with modules compiled with -mrelocatable
 powerpc-none-eabi-ld.bfd: failed to merge target specific data of file
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(crtresxgpr.o)
 make[1]: *** [u-boot] Error 1
 make: *** [sub-make] Error 2
 
 Can anyone please assist me in understanding the problem? Is something
 wrong with my toolchain? (I've built it myself)

It's unhappy about toolchain provided libraries, so I lean yes, possible
toolchain issue.  How did you generate your toolchain?  By hand?
crosstool-ng? other?

-- 
Tom


signature.asc
Description: Digital signature
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] Build problem - ppmc7xx configuration

2014-05-22 Thread Vasili Galka
On Thu, May 22, 2014 at 10:05 PM, Tom Rini tr...@ti.com wrote:

 On Thu, May 22, 2014 at 12:45:11PM +0300, Vasili Galka wrote:
  Hi,
 
  I'm trying to compile the v2014.04 tag using ppmc7xx configuration on
  Ubuntu using powerpc-none-eabi toolchain. I'm running the following:
 
  make CROSS_COMPILE=powerpc-none-eabi- O=out/ ppmc7xx_config
  make CROSS_COMPILE=powerpc-none-eabi- O=out/
 
  And receiving the following error:
  [...]
LDS u-boot.lds
LD  u-boot
  powerpc-none-eabi-ld.bfd:
 
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_lshrdi3.o):
  compiled normally and linked with modules compiled with -mrelocatable
  powerpc-none-eabi-ld.bfd: failed to merge target specific data of file
 
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_lshrdi3.o)
  powerpc-none-eabi-ld.bfd:
 
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_ashldi3.o):
  compiled normally and linked with modules compiled with -mrelocatable
  powerpc-none-eabi-ld.bfd: failed to merge target specific data of file
 
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(_ashldi3.o)
  powerpc-none-eabi-ld.bfd:
 
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(crtresxgpr.o):
  compiled normally and linked with modules compiled with -mrelocatable
  powerpc-none-eabi-ld.bfd: failed to merge target specific data of file
 
 /usr/powerpc-none-eabi/lib/gcc/powerpc-none-eabi/4.8.1/libgcc.a(crtresxgpr.o)
  make[1]: *** [u-boot] Error 1
  make: *** [sub-make] Error 2
 
  Can anyone please assist me in understanding the problem? Is something
  wrong with my toolchain? (I've built it myself)

 It's unhappy about toolchain provided libraries, so I lean yes, possible
 toolchain issue.  How did you generate your toolchain?  By hand?
 crosstool-ng? other?

 --
 Tom


By hand. I wonder what exactly is wrong with it...
arm-none-eabi toolchain generated by exactly same method works fine.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot