About porting newlib to arm...
Jeff Johnston
jjohnstn@redhat.com
Wed Sep 8 17:57:00 GMT 2004
Yen-Ting Chen wrote:
> Dear all,
>
> Could anyone tell me what is the difference between these directories,
> and what I can make use of from these directories?
>
> 1) newlib-<version>/libgloss/arm/
> 2) newlib-<version>/newlib/libc/machine/arm/
> 3) newlib-<version>/newlib/libc/sys/arm
>
> If I want to port newlib to arm, should I modify
> newlib-<version>/newlib/libc/syscalls/*.c or just
> newlib-<version>/newlib/libc/sys/arm/syscalls.c ?
> And do I need to do with newlib-<version>/libgloss/arm ??
>
> Thanks in advance.
Newlib is already ported to arm. I assume that you want to port to a specific
board.
You should be modifying libgloss/arm. Syscall code should be placed in
libgloss. In the past, syscall code was sometimes placed in libc/sys, but this
is historical and we are working to fix this.
Add your own .ld script etc.. to the libgloss/arm directory. To properly avoid
the use of the old default libc/sys/arm code, newlib must be configured with the
--disable-newlib-supplied-syscalls configuration option.
The end-user would then specify -T{your_ld_script} when compiling/linking.
-- Jeff J.
More information about the Newlib
mailing list