Atmel website | ARM Community | AVR freaks | Technical Support
Banner
 FAQ •  Search •  Register •  Login 

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: ARM-GNU Newlib
PostPosted: Thu May 19, 2011 11:23 am 
Offline

Joined: Fri Aug 13, 2010 11:38 am
Posts: 7
Hi all,

Recently i switched from IAR to GNU environment, so a kind of new world opened up to me. There is one last issue i cannot clear, although i do not seem to be the only one having this very same issue.

When compiling, following errors acure:

c:/programme/yagarto/bin/../lib/gcc/arm-none-eabi/4.6.0/../../../../arm-none-eabi/lib\libg.a(lib_a-writer.o): In function `_write_r':
C:\msys\1.0\home\yagarto\newlib-build\arm-none-eabi\newlib\libc\reent/../../../../../newlib-1.19.0/newlib/libc/reent/writer.c:58: undefined reference to `_write'
c:/programme/yagarto/bin/../lib/gcc/arm-none-eabi/4.6.0/../../../../arm-none-eabi/lib\libg.a(lib_a-closer.o): In function `_close_r':
C:\msys\1.0\home\yagarto\newlib-build\arm-none-eabi\newlib\libc\reent/../../../../../newlib-1.19.0/newlib/libc/reent/closer.c:53: undefined reference to `_close'
c:/programme/yagarto/bin/../lib/gcc/arm-none-eabi/4.6.0/../../../../arm-none-eabi/lib\libg.a(lib_a-lseekr.o): In function `_lseek_r':
C:\msys\1.0\home\yagarto\newlib-build\arm-none-eabi\newlib\libc\reent/../../../../../newlib-1.19.0/newlib/libc/reent/lseekr.c:58: undefined reference to `_lseek'
c:/programme/yagarto/bin/../lib/gcc/arm-none-eabi/4.6.0/../../../../arm-none-eabi/lib\libg.a(lib_a-readr.o): In function `_read_r':
C:\msys\1.0\home\yagarto\newlib-build\arm-none-eabi\newlib\libc\reent/../../../../../newlib-1.19.0/newlib/libc/reent/readr.c:58: undefined reference to `_read'
c:/programme/yagarto/bin/../lib/gcc/arm-none-eabi/4.6.0/../../../../arm-none-eabi/lib\libg.a(lib_a-sbrkr.o): In function `_sbrk_r':
C:\msys\1.0\home\yagarto\newlib-build\arm-none-eabi\newlib\libc\reent/../../../../../newlib-1.19.0/newlib/libc/reent/sbrkr.c:60: undefined reference to `_sbrk'

Seems to me that there are some library problems, but a lot of googling did not get me any further on this.

I attached the makefile, maybe this helps. I am new to writing/editing my own makefile, so there could be an error there.

Can somebody give me a hint on what to do in order to compile?

Thanks in advance!


Top
 Profile  
 
 Post subject: Re: ARM-GNU Newlib
PostPosted: Fri May 20, 2011 7:31 pm 
Offline

Joined: Thu Feb 25, 2010 5:02 pm
Posts: 88
Hello -

I believe that these library functions are stubs and require implementation in your code.

See libc manual (have a look at "System Calls" chapter)
ftp://sources.redhat.com/pub/newlib/libc.pdf

Here is a link to the Lib source code:
ftp://sources.redhat.com/pub/newlib/new ... 9.0.tar.gz

Regards,

_________________
Duane P. Fridley, IEEE CSDP
Viable Bytes, Inc.


Top
 Profile  
 
 Post subject: Re: ARM-GNU Newlib
PostPosted: Sun May 22, 2011 7:09 pm 
Offline

Joined: Tue Feb 05, 2008 11:46 am
Posts: 5
Hi, you can check the software packages for both sam3s and sam3n. They are provided with the syscalls needed by the newlib and with the according linker scripts.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: Google [Bot] and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron