EmbDev.net

Forum: ARM programming with GCC/GNU tools Linking Problem (FPA instructions)


Author: tsp (Guest)
Posted on:

Rate this post
0 useful
not useful
If I add next lines of code to lpc2106_hello_rs232_newlib example
project (beginning of main):

    int ta = 123;
    int tb = 234;
    int tc = ta / tb;
    tc = tc;

I can build the code ok, but if I change the makefile in a way that
instead of using MCU target "arm7tdmi" I use "arm926ej-s" I receive a
lot of errors:

Linking: rs232_stdio.elf
arm-elf-gcc  -mcpu=arm926ej-s   -I. -gdwarf-2 -DROM_RUN  -Os -Wall
-Wstrict-prot
otypes -Wcast-align -Wcast-qual -Wimplicit -Wmissing-prototypes
-Wnested-externs
 -Wpointer-arith -Wswitch -Wredundant-decls -Wreturn-type -Wshadow
-Wstrict-prot
otypes -Wunused -Wa,-adhlns=build/crt0.o  -std=gnu99 -MD -MP -MF
.dep/rs232_stdi
o.elf.d build/crt0.o   rs232_stdio.o --output rs232_stdio.elf
-nostartfiles -Wl,
-Map=rs232_stdio.map,--cref -lc  -lm -lc -lgcc -Tbuild/LPC2106-ROM.ld
d:/winarm/bin/../lib/gcc/arm-elf/4.1.1/../../../../arm-elf/bin/ld.exe:
ERROR: d:
/winarm/bin/../lib/gcc/arm-elf/4.1.1/../../../../arm-elf/lib\libc.a(file 
no.o)
us
es FPA instructions, whereas rs232_stdio.elf does not
d:/winarm/bin/../lib/gcc/arm-elf/4.1.1/../../../../arm-elf/bin/ld.exe:
failed to
 merge target specific data of file
d:/winarm/bin/../lib/gcc/arm-elf/4.1.1/../..
/../../arm-elf/lib\libc.a(fileno.o)
d:/winarm/bin/../lib/gcc/arm-elf/4.1.1/../../../../arm-elf/bin/ld.exe:
ERROR: d:
/winarm/bin/../lib/gcc/arm-elf/4.1.1/../../../../arm-elf/lib\libc.a(find 
fp.o)
us
es FPA instructions, whereas rs232_stdio.elf does not
d:/winarm/bin/../lib/gcc/arm-elf/4.1.1/../../../../arm-elf/bin/ld.exe:
failed to
 merge target specific data of file
d:/winarm/bin/../lib/gcc/arm-elf/4.1.1/../..
/../../arm-elf/lib\libc.a(findfp.o)
d:/winarm/bin/../lib/gcc/arm-elf/4.1.1/../../../../arm-elf/bin/ld.exe:
ERROR: d:
/winarm/bin/../lib/gcc/arm-elf/4.1.1\libgcc.a(_divsi3.o) uses FPA
instructions,
whereas rs232_stdio.elf does not
d:/winarm/bin/../lib/gcc/arm-elf/4.1.1/../../../../arm-elf/bin/ld.exe:
failed to
 merge target specific data of file
d:/winarm/bin/../lib/gcc/arm-elf/4.1.1\libgc
c.a(_divsi3.o)
:
:

Any idea how can I build the code shown above into "arm926ej-s" MCU? MCU
target "arm9" works also but "arm9e" causes same FPA errors.

The environment I'm using is "WinARM Version 20060606"

Author: Clifford Slocombe (clifford)
Posted on:

Rate this post
0 useful
not useful
I am thinking about this, but until I come up with something, an lpc2106
is not an ARM9. What exactly are you targeting out of curiosity?

Author: tsp (Guest)
Posted on:

Rate this post
0 useful
not useful
Clifford Slocombe wrote:
> I am thinking about this, but until I come up with something, an lpc2106
> is not an ARM9. What exactly are you targeting out of curiosity?

Yes, I faced this problem in my own kernel development project, targeted
(at the moment) for arm926ej-s because QEMU supports that :-)

The reason for using lpc2106_hello_rs232_newlib was to give other WinARM
users a possibility to try that piece of code with "arm926ej-s" target,
because this problem exists also with that makefile.

Reply

Entering an e-mail address is optional. If you want to receive reply notifications by e-mail, please log in.

Rules — please read before posting

  • Post long source code as attachment, not in the text
  • Posting advertisements is forbidden.

Formatting options

  • [c]C code[/c]
  • [avrasm]AVR assembler code[/avrasm]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]




Bild automatisch verkleinern, falls nötig
Note: the original post is older than 6 months. Please don't ask any new questions in this thread, but start a new one.