This is the mail archive of the mailing list for the newlib project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Configuring for bare hw ia32 PC's

On Mon, 2008-05-12 at 18:11 +0100, Luke A. Guest wrote:
> On Mon, 2008-05-12 at 13:08 -0400, Jonathan S. Shapiro wrote:
> > > Although, saying that, it would be possible to use this application
> > > level compiler to actually build the OS with as well IIRC.
> > 
> > Yes. The OS build should be done with --nostdlib in any case.
> This is problematic with Ada as the language is huge and the compiler
> adds some stuff into the code which references the runtime. Now, what
> this stuff is, depends on what features you have available.

Then either the Ada compiler is busted or there is some command line
option that you need to add.

Back up a second. You are, in effect, compiling Ada code to run on a
bare board. The "hosted" specification of the standard C library assumes
that you are running on top of an operating system. The "freestanding"
version does not.

It is okay if the Ada compiler emits things that rely on the
freestanding version of libc. Pragmatically, it is also okay if it
relies on a few additional, commonly provided OS procedures such as
memcpy. But if it relies on much more than that you have a fairly
fundamental disconnect in compilation models, and you need to consider
whether the Ada compiler is generating code for the appropriate model.

Given what you say above, I suspect that you need to start by turning
off every Ada feature that you can, and then see what is happening.

Can you give an example of what the Ada compiler is referencing that is
causing a problem? If possible, also state why the Ada compiler is
referencing this -- that is, is it being called from user-provided
source code, or is it being called from within the Ada runtime library?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]