Now do I add things to Libgloss?

M. R. Brown
Tue Aug 21 23:10:00 GMT 2001

* J. Johnston <> on Tue, Aug 21, 2001:

> Andrew Stubbs wrote:
> > 
> > Where can I find full documentation about putting stuff into libgloss?
> > There is a rather old and brief document in libgloss, but it isn't very
> > useful for my purposes.
> > 
> There is none.

Actually, there's a document entiled, "Embed[ding?] with GNU Tools" (or
something like that) that describes the basic syscalls that newlib needs to
be, uh, "useful" :).  Even though it doesn't explicitly mention how to add
new target (or architecture) support, you should be able to figure out
what's needed in libgloss API-wise.

I've hacked around previous versions of newlib to add a 'dreamcast'
architecture that uses the sh machine directory within newlib, but has a
separate dreamcast sys directory with syscall glue to talk to the loader I
use.  J. Johnston's reply for libgloss is excellent, but if you want to see
the application to newlib, I've attached my patches.

These patches show my initial inexperience with munging .in and .am files,
so check out the top level and newlib/ to see
how I added the 'sh-sega-dreamcast' target.  Just avoid all the other
cruft, and always remember if you modify an .in or .am file, be sure to
modify the autoconf/automake version as well - it'll keep your patches and
headaches a lot smaller :).

M. R.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: newlib-1.8.2-dc+dcload.diff.gz
Type: application/x-gzip
Size: 37855 bytes
Desc: not available
URL: <>

More information about the Newlib mailing list