This is the mail archive of the
newlib@sources.redhat.com
mailing list for the newlib project.
newlib without OS
- From: Paulo Eduardo Ferreira de Castro <paulo dot castro at ic dot unicamp dot br>
- To: newlib at sources dot redhat dot com
- Date: Wed, 17 Apr 2002 00:03:40 -0300 (BRT)
- Subject: newlib without OS
Hello.
I have some conceptual questions. Any help will be appreciated.
Is it possible to use newlib for an embedded processor without
using an operational system? Certainly, several functions
shouldn't work, like "printf" or other I/O in general, because
they might depend on a specific hardware/OS. On the other hand,
I'd like to be able to use functions like "strcpy" (string.h),
"sin" (math.h) and "malloc" (would malloc work?!) without an OS.
Perhaps my question should be: what are the parts of newlib that
depend on an OS? Is it possible to build newlib without those
parts? Is there a special target string to represent the absence
of an OS? For instance, "sparc-linux" refers to Linux, but
perhaps "sparc-elf" could mean "please generate OS-independent
binaries for a sparc processor". Otherwise, what does "sparc-elf"
mean?
Is it correct to say that the only way by which an application or
library (newlib) can use the services of an OS is by the use of
system calls?
In newlib's source code, what are the directories or files that
are OS-specific? Are those files the only place where I would
find system calls?
Thanks a lot.
Paulo E. F. Castro
State University of Campinas, Brazil.