EmbDev.net

Forum: ARM programming with GCC/GNU tools compiler for arm + linker problems


Author: Cloud Strife (goblin12)
Posted on:

Rate this post
0 useful
not useful
Hi community,

right now i am using eclipse + winarm
and want to compile some c code for my
AT91SAM9RL board (ARM based)

for compiler
arm-elf-gcc

and linker got some problems
when i use
arm-elf-gcc, g++
i get undefined reference errors

when i use
arm-elf-ld
it works but i get .exe as result

i need .elf , .hex or .bin

can someone help?

: Moved by Moderator
Author: Martin Thomas (mthomas) (Moderator)
Posted on:

Rate this post
0 useful
not useful
Cloud Strife wrote:
> Hi community,
>
> right now i am using eclipse + winarm
> and want to compile some c code for my
> AT91SAM9RL board (ARM based)
>
> for compiler
> arm-elf-gcc

You might want to update to a more up-to-date GNU tool-packate (WinARM 
ist rather old now). See yagarto.de or search for Codesourcery CS G++ 
lite for arm-eabi.

> and linker got some problems
> when i use
> arm-elf-gcc, g++
> i get undefined reference errors

Not enough information, at least show the error messages.

> when i use
> arm-elf-ld
> it works but i get .exe as result

Avoid calling -ld directly for linking.

Author: Cloud Strife (goblin12)
Posted on:

Rate this post
0 useful
not useful
Martin Thomas wrote:
> Cloud Strife wrote:
>> Hi community,
>>
>> right now i am using eclipse + winarm
>> and want to compile some c code for my
>> AT91SAM9RL board (ARM based)
>>
>> for compiler
>> arm-elf-gcc
>
> You might want to update to a more up-to-date GNU tool-packate (WinARM
> ist rather old now). See yagarto.de or search for Codesourcery CS G++
> lite for arm-eabi.
>
>> and linker got some problems
>> when i use
>> arm-elf-gcc, g++
>> i get undefined reference errors
>
> Not enough information, at least show the error messages.
>

error message:
undefined reference to _read_r , ..._lseek_r ,...i_satty_r etc

i am using yagarto gcc as compiler now

>> when i use
>> arm-elf-ld
>> it works but i get .exe as result
>
> Avoid calling -ld directly for linking.

idk what files the AT91SAM9RL can understand but i guess i need .elf or 
.bin

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.