public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot-Users] -mrelocatable
@ 2004-04-07 20:17 ` Forslin, Eric
  2004-04-07 20:47   ` Wolfgang Denk
  2004-04-07 21:13   ` Jeff Tucker
  0 siblings, 2 replies; 10+ messages in thread
From: Forslin, Eric @ 2004-04-07 20:17 UTC (permalink / raw)
  To: u-boot

Hello,

I'm currently upgrading a custom PPCBoot 1.1.5 port to U-Boot 1.0.0 for a
custom 405GP-based board.  At the same time, I thought it would be a good
idea to upgrade my development system to SuSE 9.0 and tool chain to ELDK
3.0.

When I build U-Boot I get the following error when zlib.c is being compiled:

ppc_4xx-gcc -g  -Os   -mrelocatable -ffixed-r14 -meabi -D__KERNEL__
-DTEXT_BASE=
0xFFF80000 -I/home/ejf/u-boot/include -fno-builtin -ffreestanding -nostdinc
-isy
stem /home/ejf/eldk/usr/bin/../lib/gcc-lib/ppc-linux/3.2.2/include -pipe
-DCONF
IG_PPC -D__powerpc__ -DCONFIG_4xx -ffixed-r2 -ffixed-r29 -mstring -Wa,-m405
-mcp
u=405 -msoft-float -Wall -Wstrict-prototypes -c -o zlib.o zlib.c
{standard input}: Assembler messages:
{standard input}:4998: Error: Relocation cannot be done when using
-mrelocatable
{standard input}:4999: Error: Relocation cannot be done when using
-mrelocatable
{standard input}:5000: Error: Relocation cannot be done when using
-mrelocatable
{standard input}:5001: Error: Relocation cannot be done when using
-mrelocatable
{standard input}:5002: Error: Relocation cannot be done when using
-mrelocatable
{standard input}:5003: Error: Relocation cannot be done when using
-mrelocatable
{standard input}:5004: Error: Relocation cannot be done when using
-mrelocatable
{standard input}:5005: Error: Relocation cannot be done when using
-mrelocatable
{standard input}:4969: Error: Relocation cannot be done when using
-mrelocatable
make[1]: *** [zlib.o] Error 1
make[1]: Leaving directory `/home/ejf/u-boot/lib_generic'
make: *** [subdirs] Error 1

After doing a couple of quick Google searches, it appears that there might
be some sort of bug in GCC.  Does anyone know what the solution to this
problem is?

I can build without the -mrelocatable flag.  The board boots up but when
it's time to run from RAM it crashes, probably because the resulting code is
not relocatable.

Thanks for you help.

Eric


Eric FORSLIN      P: 919-573-1353  E: eforslin at thalescomputers.com
THALES Computers  F: 919-231-8001  W: www.thalescomputers.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.denx.de/pipermail/u-boot/attachments/20040407/569c9acc/attachment.htm 

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot-Users] -mrelocatable
  2004-04-07 20:17 ` [U-Boot-Users] -mrelocatable Forslin, Eric
@ 2004-04-07 20:47   ` Wolfgang Denk
  2004-04-07 21:13   ` Jeff Tucker
  1 sibling, 0 replies; 10+ messages in thread
From: Wolfgang Denk @ 2004-04-07 20:47 UTC (permalink / raw)
  To: u-boot

In message <2A79E2756786D31182670000D11BFFBCC3405C@matrix2.thalescomputers.com> you wrote:
> 
> I'm currently upgrading a custom PPCBoot 1.1.5 port to U-Boot 1.0.0 for a
> custom 405GP-based board.  At the same time, I thought it would be a good
> idea to upgrade my development system to SuSE 9.0 and tool chain to ELDK
> 3.0.
> 
> When I build U-Boot I get the following error when zlib.c is being compiled:

This is a FAQ. Please see
http://www.denx.de/twiki/bin/view/DULG/RelocationCannotBeDoneWhenUsingMrelocatable

> After doing a couple of quick Google searches, it appears that there might
> be some sort of bug in GCC.  Does anyone know what the solution to this

This is NOT a GCC bug, it is an  incompatibility  witholder  versions
which has been fixed in current versions of U-Boot.

> problem is?

The problem is your version of U-boot: it's too old.

> I can build without the -mrelocatable flag.  The board boots up but when
> it's time to run from RAM it crashes, probably because the resulting code is
> not relocatable.

Indeed.

Best regards,

Wolfgang Denk

-- 
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd at denx.de
f u cn rd ths, u cn gt a gd jb n cmptr prgrmmng.

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot-Users] -mrelocatable
  2004-04-07 20:17 ` [U-Boot-Users] -mrelocatable Forslin, Eric
  2004-04-07 20:47   ` Wolfgang Denk
@ 2004-04-07 21:13   ` Jeff Tucker
  2004-04-07 22:38     ` Wolfgang Denk
  1 sibling, 1 reply; 10+ messages in thread
From: Jeff Tucker @ 2004-04-07 21:13 UTC (permalink / raw)
  To: u-boot

--On Wednesday, April 07, 2004 4:17 PM -0400 "Forslin, Eric" 
<eforslin@thalescomputers.com> wrote:

>
> Hello,
>
> I'm currently upgrading a custom PPCBoot 1.1.5 port to U-Boot 1.0.0 for a
> custom 405GP-based board.  At the same time, I thought it would be a good
> idea to upgrade my development system to SuSE 9.0 and tool chain to ELDK
> 3.0.
>
> When I build U-Boot I get the following error when zlib.c is being
> compiled:
>
> ppc_4xx-gcc -g  -Os   -mrelocatable -ffixed-r14 -meabi -D__KERNEL__
> -DTEXT_BASE=
> 0xFFF80000 -I/home/ejf/u-boot/include -fno-builtin -ffreestanding
> -nostdinc -isy
> stem /home/ejf/eldk/usr/bin/../lib/gcc-lib/ppc-linux/3.2.2/include -pipe
> -DCONF
> IG_PPC -D__powerpc__ -DCONFIG_4xx -ffixed-r2 -ffixed-r29 -mstring
> -Wa,-m405 -mcp
> u=405 -msoft-float -Wall -Wstrict-prototypes -c -o zlib.o zlib.c
> {standard input}: Assembler messages:
> {standard input}:4998: Error: Relocation cannot be done when using
> -mrelocatable

Wolfgang posted a couple days ago that you can't build the latest U-Boot 
with old gcc tools. Perhaps you're not really using the latest compiler 
when you rebuild U-Boot? I see you have the latest toolchain, so make sure 
that your PATH is set up to actually use those new tools and U-Boot will 
build fine.

Jeff

-- 
Jeff Tucker
jeff at jltnet.com

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot-Users] -mrelocatable
  2004-04-07 21:13   ` Jeff Tucker
@ 2004-04-07 22:38     ` Wolfgang Denk
  0 siblings, 0 replies; 10+ messages in thread
From: Wolfgang Denk @ 2004-04-07 22:38 UTC (permalink / raw)
  To: u-boot

In message <169996251.1081357990@[192.168.0.230]> you wrote:
> 
> Wolfgang posted a couple days ago that you can't build the latest U-Boot 
> with old gcc tools. Perhaps you're not really using the latest compiler 

This is WRONG.


It's vice versa: You cannot build OLD U-Boot sources with latest GCC.

Best regards,

Wolfgang Denk

-- 
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd at denx.de
Fascinating is a word I use for the unexpected.
	-- Spock, "The Squire of Gothos", stardate 2124.5

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot-Users] -mrelocatable
@ 2004-05-19 15:38 Woodruff, Richard
  0 siblings, 0 replies; 10+ messages in thread
From: Woodruff, Richard @ 2004-05-19 15:38 UTC (permalink / raw)
  To: u-boot

I'm attaching a patch I got for GCC3.4 from Paul Brook at CodeSourcery
which fixes the relocation problem.  I'm assuming the one discussed
below is the same one we ran into.

Regards,

Richard W.

------------------------------------------------------------------------
--
> I've included a file called er_objs.tar.gz . I contains a somewhat 
> reduced set of objects and the compile line to generate the error.  If

> you us another linker you will get past the error.  As I said before 
> this is for the Q4-2003 release and the Q1-2004 release.
>
> [a0384864 at dta0384864 objs]$ ./command_line_for_link_error 
> ./libgcc.a(_udivsi3.oS)(.text+0xec):/work/GNU/CodeSourcery/gcc/gcc/con
> fi

The following patch should fix this problem. It will be included in
future 
releases.

Paul

--- bfd/elf32-arm.h.orig	2004-04-22 22:11:15.000000000 -0400
+++ bfd/elf32-arm.h	2004-04-22 22:28:37.000000000 -0400
@@ -2229,6 +2229,8 @@ elf32_arm_relocate_section (output_bfd, 
 	        case R_ARM_PC24:
 	        case R_ARM_ABS32:
 		case R_ARM_THM_PC22:
+	        case R_ARM_PLT32:
+
 	          if (info->shared
 	              && (
 			  (!info->symbolic && h->dynindx != -1)
@@ -2262,11 +2264,6 @@ elf32_arm_relocate_section (output_bfd, 
 	            relocation = 0;
 		  break;
 
-	        case R_ARM_PLT32:
-	          if (h->plt.offset != (bfd_vma)-1)
-	            relocation = 0;
-		  break;
-
 	        default:
 		  if (unresolved_reloc)
 		    _bfd_error_handler





> -----Original Message-----
> From: u-boot-users-admin at lists.sourceforge.net [mailto:u-boot-users-
> admin at lists.sourceforge.net] On Behalf Of Wolfgang Denk
> Sent: Wednesday, April 07, 2004 5:38 PM
> To: Jeff Tucker
> Cc: 'u-boot-users at lists.sourceforge.net'
> Subject: Re: [U-Boot-Users] -mrelocatable
> 
> In message <169996251.1081357990@[192.168.0.230]> you wrote:
> >
> > Wolfgang posted a couple days ago that you can't build the latest
U-Boot
> > with old gcc tools. Perhaps you're not really using the latest
compiler
> 
> This is WRONG.
> 
> 
> It's vice versa: You cannot build OLD U-Boot sources with latest GCC.
> 
> Best regards,
> 
> Wolfgang Denk
> 
> --
> Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
> Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd at denx.de
> Fascinating is a word I use for the unexpected.
> 	-- Spock, "The Squire of Gothos", stardate 2124.5
> 
> 
> -------------------------------------------------------
> This SF.Net email is sponsored by: IBM Linux Tutorials
> Free Linux tutorial presented by Daniel Robbins, President and CEO of
> GenToo technologies. Learn everything from fundamentals to system
> administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
> _______________________________________________
> U-Boot-Users mailing list
> U-Boot-Users at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/u-boot-users

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot-Users] -mrelocatable
@ 2004-05-19 15:43 Woodruff, Richard
  2004-05-19 17:41 ` Wolfgang Denk
  0 siblings, 1 reply; 10+ messages in thread
From: Woodruff, Richard @ 2004-05-19 15:43 UTC (permalink / raw)
  To: u-boot

Perhaps I read the fragment wrong.  We needed to apply this patch as the
relocate option generated bad code or code which would not compile using
a version of GCC3.4 (depending on the relocation address it would fail
to compile or compile and generate bad code).

In general I think there are also changes which were made to the u-boot
source structure to allow them to compile properly with newer GCC's.
The provide patch is necessary for ARM boards with some recent versions
of GCC.  If your compiler already works, then disregard the message.

Regards,

Richard W.

> -----Original Message-----
> From: Woodruff, Richard
> Sent: Wednesday, May 19, 2004 10:38 AM
> To: 'Wolfgang Denk'; Jeff Tucker
> Cc: 'u-boot-users at lists.sourceforge.net'
> Subject: RE: [U-Boot-Users] -mrelocatable
> 
> I'm attaching a patch I got for GCC3.4 from Paul Brook at CodeSourcery
> which fixes the relocation problem.  I'm assuming the one discussed
below
> is the same one we ran into.
> 
> Regards,
> 
> Richard W.
> 
>
------------------------------------------------------------------------
--
> > I've included a file called er_objs.tar.gz . I contains a somewhat
> > reduced set of objects and the compile line to generate the error.
If
> > you us another linker you will get past the error.  As I said before
> > this is for the Q4-2003 release and the Q1-2004 release.
> >
> > [a0384864 at dta0384864 objs]$ ./command_line_for_link_error
> >
./libgcc.a(_udivsi3.oS)(.text+0xec):/work/GNU/CodeSourcery/gcc/gcc/con
> > fi
> 
> The following patch should fix this problem. It will be included in
future
> releases.
> 
> Paul
> 
> --- bfd/elf32-arm.h.orig	2004-04-22 22:11:15.000000000 -0400
> +++ bfd/elf32-arm.h	2004-04-22 22:28:37.000000000 -0400
> @@ -2229,6 +2229,8 @@ elf32_arm_relocate_section (output_bfd,
>  	        case R_ARM_PC24:
>  	        case R_ARM_ABS32:
>  		case R_ARM_THM_PC22:
> +	        case R_ARM_PLT32:
> +
>  	          if (info->shared
>  	              && (
>  			  (!info->symbolic && h->dynindx != -1)
> @@ -2262,11 +2264,6 @@ elf32_arm_relocate_section (output_bfd,
>  	            relocation = 0;
>  		  break;
> 
> -	        case R_ARM_PLT32:
> -	          if (h->plt.offset != (bfd_vma)-1)
> -	            relocation = 0;
> -		  break;
> -
>  	        default:
>  		  if (unresolved_reloc)
>  		    _bfd_error_handler
> 
> 
> 
> 
> 
> > -----Original Message-----
> > From: u-boot-users-admin at lists.sourceforge.net [mailto:u-boot-users-
> > admin at lists.sourceforge.net] On Behalf Of Wolfgang Denk
> > Sent: Wednesday, April 07, 2004 5:38 PM
> > To: Jeff Tucker
> > Cc: 'u-boot-users at lists.sourceforge.net'
> > Subject: Re: [U-Boot-Users] -mrelocatable
> >
> > In message <169996251.1081357990@[192.168.0.230]> you wrote:
> > >
> > > Wolfgang posted a couple days ago that you can't build the latest
U-
> Boot
> > > with old gcc tools. Perhaps you're not really using the latest
> compiler
> >
> > This is WRONG.
> >
> >
> > It's vice versa: You cannot build OLD U-Boot sources with latest
GCC.
> >
> > Best regards,
> >
> > Wolfgang Denk
> >
> > --
> > Software Engineering:  Embedded and Realtime Systems,  Embedded
Linux
> > Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email:
wd at denx.de
> > Fascinating is a word I use for the unexpected.
> > 	-- Spock, "The Squire of Gothos", stardate 2124.5
> >
> >
> > -------------------------------------------------------
> > This SF.Net email is sponsored by: IBM Linux Tutorials
> > Free Linux tutorial presented by Daniel Robbins, President and CEO
of
> > GenToo technologies. Learn everything from fundamentals to system
> >
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
> > _______________________________________________
> > U-Boot-Users mailing list
> > U-Boot-Users at lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/u-boot-users

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot-Users] -mrelocatable
  2004-05-19 15:43 Woodruff, Richard
@ 2004-05-19 17:41 ` Wolfgang Denk
  0 siblings, 0 replies; 10+ messages in thread
From: Wolfgang Denk @ 2004-05-19 17:41 UTC (permalink / raw)
  To: u-boot

In message <71555548814716479478431542AA5F8ADF8B52@dlee2k04.ent.ti.com> you wrote:
> Perhaps I read the fragment wrong.  We needed to apply this patch as the

Maybe you should include a little bit of introduction  what  you  are
talking about.

> relocate option generated bad code or code which would not compile using
> a version of GCC3.4 (depending on the relocation address it would fail
> to compile or compile and generate bad code).

What do you mean with "relocation address"?

> In general I think there are also changes which were made to the u-boot
> source structure to allow them to compile properly with newer GCC's.

The changes made was to replace "-mrelocatable" with "-fPIC".


Best regards,

Wolfgang Denk

-- 
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd at denx.de
Human beings were created by water to transport it uphill.

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot-Users] -mrelocatable
@ 2004-05-19 17:46 Woodruff, Richard
  2004-05-19 19:59 ` Wolfgang Denk
  0 siblings, 1 reply; 10+ messages in thread
From: Woodruff, Richard @ 2004-05-19 17:46 UTC (permalink / raw)
  To: u-boot

I meant to be talking about the -Ttext option.  If set to 0 or below
some threshold it generates the wrong code.  Above it gives the
following compile errors.

Regards,

Richard W.

------------------------
arm-linux-ld -Bstatic -T
/home/a0384864/wtbu/loader/u_1_1_0/u-boot-1.1.0/board/omap1510inn/u-boot
.lds -Ttext 0x11080000  $UNDEF_SYM cpu/arm925t/start.o \
                --start-group lib_generic/libgeneric.a
board/omap1510inn/libomap1510inn.a cpu/arm925t/libarm925t.a
lib_arm/libarm.a fs/cramfs/libcramfs.a fs/fat/libfat.a fs/fdos/libfdos.a
fs/jffs2/libjffs2.a fs/reiserfs/libreiserfs.a net/libnet.a
disk/libdisk.a rtc/librtc.a dtt/libdtt.a drivers/libdrivers.a
drivers/sk98lin/libsk98lin.a post/libpost.a post/cpu/libcpu.a
common/libcommon.a --no-warn-mismatch -L
/home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0 -lgcc
--end-group \
                -Map u-boot.map -o u-boot
/home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0/libgcc.a(
_udivsi3.oS)(.text+0xec):/work/GNU/CodeSourcery/gcc/gcc/config/arm/lib1f
uncs.asm:642: relocation truncated to fit: R_ARM_PLT32 __div0
/home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0/libgcc.a(
_divsi3.oS)(.text+0x11c):/work/GNU/CodeSourcery/gcc/gcc/config/arm/lib1f
uncs.asm:762: relocation truncated to fit: R_ARM_PLT32 __div0
/home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0/libgcc.a(
_umodsi3.oS)(.text+0xc0):/work/GNU/CodeSourcery/gcc/gcc/config/arm/lib1f
uncs.asm:683: relocation truncated to fit: R_ARM_PLT32 __div0
/home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0/libgcc.a(
_modsi3.oS)(.text+0xd8):/work/GNU/CodeSourcery/gcc/gcc/config/arm/lib1fu
ncs.asm:822: relocation truncated to fit: R_ARM_PLT32 __div0
make: *** [u-boot] Error 1

> -----Original Message-----
> From: wd at denx.de [mailto:wd at denx.de]
> Sent: Wednesday, May 19, 2004 12:41 PM
> To: Woodruff, Richard
> Cc: Jeff Tucker; u-boot-users at lists.sourceforge.net
> Subject: Re: [U-Boot-Users] -mrelocatable
> 
> In message
<71555548814716479478431542AA5F8ADF8B52@dlee2k04.ent.ti.com>
> you wrote:
> > Perhaps I read the fragment wrong.  We needed to apply this patch as
the
> 
> Maybe you should include a little bit of introduction  what  you  are
> talking about.
> 
> > relocate option generated bad code or code which would not compile
using
> > a version of GCC3.4 (depending on the relocation address it would
fail
> > to compile or compile and generate bad code).
> 
> What do you mean with "relocation address"?
> 
> > In general I think there are also changes which were made to the
u-boot
> > source structure to allow them to compile properly with newer GCC's.
> 
> The changes made was to replace "-mrelocatable" with "-fPIC".
> 
> 
> Best regards,
> 
> Wolfgang Denk
> 
> --
> Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
> Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd at denx.de
> Human beings were created by water to transport it uphill.

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot-Users] -mrelocatable
  2004-05-19 17:46 Woodruff, Richard
@ 2004-05-19 19:59 ` Wolfgang Denk
  0 siblings, 0 replies; 10+ messages in thread
From: Wolfgang Denk @ 2004-05-19 19:59 UTC (permalink / raw)
  To: u-boot

Dear Richard,

a request: Can you please use standard quoting  rules?  It  makes  no
sense  at  all to include the whole previous message at the bottom of
your posting.

In message <71555548814716479478431542AA5F8AEC85D1@dlee2k04.ent.ti.com> you wrote:
> I meant to be talking about the -Ttext option.  If set to 0 or below
> some threshold it generates the wrong code.  Above it gives the
> following compile errors.

I can't parse that. How can you set a text address "below" 0 ???

> /home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0/libgcc.a(
> _udivsi3.oS)(.text+0xec):/work/GNU/CodeSourcery/gcc/gcc/config/arm/lib1f
> uncs.asm:642: relocation truncated to fit: R_ARM_PLT32 __div0
> /home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0/libgcc.a(
> _divsi3.oS)(.text+0x11c):/work/GNU/CodeSourcery/gcc/gcc/config/arm/lib1f
> uncs.asm:762: relocation truncated to fit: R_ARM_PLT32 __div0
> /home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0/libgcc.a(
> _umodsi3.oS)(.text+0xc0):/work/GNU/CodeSourcery/gcc/gcc/config/arm/lib1f
> uncs.asm:683: relocation truncated to fit: R_ARM_PLT32 __div0
> /home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0/libgcc.a(
> _modsi3.oS)(.text+0xd8):/work/GNU/CodeSourcery/gcc/gcc/config/arm/lib1fu
> ncs.asm:822: relocation truncated to fit: R_ARM_PLT32 __div0
> make: *** [u-boot] Error 1

I've been told that using -fpic instead of -fPIC will fix this,  too,
but  I had no time yet to either verify this myself, nor to check for
consequences on other systems (like PPC).


Best regards,

Wolfgang Denk

-- 
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd at denx.de
Testing can show the presense of bugs, but not their absence.
                                                   -- Edsger Dijkstra

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot-Users] -mrelocatable
@ 2004-05-19 20:13 Woodruff, Richard
  0 siblings, 0 replies; 10+ messages in thread
From: Woodruff, Richard @ 2004-05-19 20:13 UTC (permalink / raw)
  To: u-boot

Wolfgang,

> a request: Can you please use standard quoting  rules?  It  makes  no
> sense  at  all to include the whole previous message at the bottom of
> your posting.

Ok.  I'm required to use a Windows tools which I haven't taken the time
to fully configure.  It seems that every now and them I set it up close
to correct, and it will revert back.

> > I meant to be talking about the -Ttext option.  If set to 0 or below
> > some threshold it generates the wrong code.  Above it gives the
> > following compile errors.
> 
> I can't parse that. How can you set a text address "below" 0 ???

I did not state it correctly.  Code compiles but bad code is generated
when the text is configured below a certain address.  When the code goes
above that address, it doesn't compile and gives the below error.

> >
/home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0/libgcc.a(
> >
_udivsi3.oS)(.text+0xec):/work/GNU/CodeSourcery/gcc/gcc/config/arm/lib1f
> > uncs.asm:642: relocation truncated to fit: R_ARM_PLT32 __div0
> >
/home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0/libgcc.a(
> >
_divsi3.oS)(.text+0x11c):/work/GNU/CodeSourcery/gcc/gcc/config/arm/lib1f
> > uncs.asm:762: relocation truncated to fit: R_ARM_PLT32 __div0
> >
/home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0/libgcc.a(
> >
_umodsi3.oS)(.text+0xc0):/work/GNU/CodeSourcery/gcc/gcc/config/arm/lib1f
> > uncs.asm:683: relocation truncated to fit: R_ARM_PLT32 __div0
> >
/home/a0384864/wtbu/tools/3_4_0/bin/../lib/gcc/arm-linux/3.4.0/libgcc.a(
> >
_modsi3.oS)(.text+0xd8):/work/GNU/CodeSourcery/gcc/gcc/config/arm/lib1fu
> > ncs.asm:822: relocation truncated to fit: R_ARM_PLT32 __div0
> > make: *** [u-boot] Error 1
> 
> I've been told that using -fpic instead of -fPIC will fix this,  too,
> but  I had no time yet to either verify this myself, nor to check for
> consequences on other systems (like PPC).

I was not aware of this.  I will give it a try. Thanks.

Regards,

Richard W.

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2004-05-19 20:13 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <2A79E2756786D31182670000D11BFFBCC3405C@matrix2.thalescomputers. com>
2004-04-07 20:17 ` [U-Boot-Users] -mrelocatable Forslin, Eric
2004-04-07 20:47   ` Wolfgang Denk
2004-04-07 21:13   ` Jeff Tucker
2004-04-07 22:38     ` Wolfgang Denk
2004-05-19 15:38 Woodruff, Richard
  -- strict thread matches above, loose matches on Subject: below --
2004-05-19 15:43 Woodruff, Richard
2004-05-19 17:41 ` Wolfgang Denk
2004-05-19 17:46 Woodruff, Richard
2004-05-19 19:59 ` Wolfgang Denk
2004-05-19 20:13 Woodruff, Richard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox