This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Supporting multiple runtime environments: How?
- To: "EGCS mailing list" <egcs at cygnus dot com>
- Subject: Supporting multiple runtime environments: How?
- From: "Rask Ingemann Lambertsen" <rask at kampsax dot k-net dot dk>
- Date: 08 Jun 98 04:27:34 +0200
- Organization: Me? Organised? Dream on...
Hi.
I'm looking for a way of allowing compile time selection of runtime
environment (libc.a etc.) on the m68k-amigaos and ppc-amigaos targets.
Currently, one can select between ixemul and libnix (m68k-amigaos only at
this time), but it is not very cleanly implemented and relies on both
environments to use the same include files. A recent addition is librilc
(m68k-amigaos and ppc-amigaos), which uses completely different header files,
and this is likely also the case with glibc, a possible fourth alternative in
the future. Ideally the user should be able to select a runtime environment
with a -runtime=<runtime> switch to gcc.
The problem is getting the preprocessor and linker to find the right
header files, libraries and startup code. The specs file seems to be the
right place to do this, but I'm having some problems. With the help of the %s
operator, the linker finds startup code and libraries in
<prefix>/lib/<runtime> (<prefix> as specified by --prefix and friends to
configure) with constructs like
*link_path:
%{runtime=ixemul:-L ixemul%s}
*startfile:
%{runtime=ixemul:ixemul/crt0.o%s}
but how do I make the preprocessor find header files in
<prefix>/include/<runtime>? Despite many experiments with %s and -isystem,
-iwithprefix and -iwithprefixbefore, I've not been able to come up with the
right combination. Any ideas?
Regards,
/ŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻTŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻ\
| Rask Ingemann Lambertsen | E-mail: mailto:rask@kampsax.k-net.dk |
| Registered Phase5 developer | WWW: http://www.gbar.dtu.dk/~c948374/ |
| A4000, 775 kkeys/s (RC5-64) | "ThrustMe" on XPilot, ARCnet and IRC |
| 3 kinds of people: those who can count & those who can't. |