comp.lang.ada
 help / color / mirror / Atom feed
* Including Ada objects in non-Ada  environments
@ 1995-02-24 10:37 Daneil Wengelin
  1995-02-28 21:46 ` Tucker Taft
  0 siblings, 1 reply; 2+ messages in thread
From: Daneil Wengelin @ 1995-02-24 10:37 UTC (permalink / raw)


Dear All, can someone enlighten me on the following issue.

I want to be able to generate object code with my Ada compiler
to be included in another language. The standard way is to re-
quire that the executable is liked using the APSE linker to
get the Ada Run-Time included in the executable.

However, I want to include the Ada object code in an executable
that requires its own run-time, in this case the Windows4GL
applications generator from CA-Ingres.

It seems quite hard, since the Ada compiler inserts calls to the
code in the RTS, such as __raise_constraint_error etc, and I would
almost bet on that if we tried to include both the W4GL RTS and
the Ada RTS in the same executable, we'd be begging for trouble.

Why could not the compiler provide a facility to make objects
self-contained somehow? Could one imagine a mini-RTS that would
just provide the symbols the code generator inserts, without
the other stuff, given some restrictions on the source, e.g. the
keywords "task", "accept", etc are invalid??

For any practiocal hints: we're running Apex 1.4.4. on Solaris 2.3.


Ta, Daniel


------------------------------------------------------------------------
-- Daniel Wengelin                 -- Team Ada, the best 0$ mem-      --
-- CelsiusTech                     -- bership fee you'll ever spend   --
-- dawe@celsiustech.se             --                                 --
-- wengelin@ozspace.brisnet.org.au --                                 --
------------------------------------------------------------------------
with Standard_Disclaimer;



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Including Ada objects in non-Ada  environments
  1995-02-24 10:37 Including Ada objects in non-Ada environments Daneil Wengelin
@ 1995-02-28 21:46 ` Tucker Taft
  0 siblings, 0 replies; 2+ messages in thread
From: Tucker Taft @ 1995-02-28 21:46 UTC (permalink / raw)


Daneil Wengelin (wengelin@ozspace.brisnet.org.au) wrote:

: I want to be able to generate object code with my Ada compiler
: to be included in another language. The standard way is to re-
: quire that the executable is liked using the APSE linker to
: get the Ada Run-Time included in the executable.

: ...
: Why could not the compiler provide a facility to make objects
: self-contained somehow? Could one imagine a mini-RTS that would
: just provide the symbols the code generator inserts, without
: the other stuff, given some restrictions on the source, e.g. the
: keywords "task", "accept", etc are invalid??

Ada 95 compilers are encouraged to provide support for
the "main" routine being written in something other than
Ada.  This could presumably help with your problem.  Note
that similar problems will occur in any language with a 
non-trivial RTS (e.g. C++, Lisp, Smalltalk, even Fortran in some
implementations).  

In any case, this is a very reasonable thing to request of
your implementor, and they might already have a solution.
Probably you should check with them.

Alternatively, give GNAT a try.  It uses the standard C runtime
routines as much as possible, presumably minimizing the problem.

: For any practical hints: we're running Apex 1.4.4. on Solaris 2.3.

: -- Daniel Wengelin                 -- Team Ada, the best 0$ mem-      --
: -- CelsiusTech                     -- bership fee you'll ever spend   --
: -- dawe@celsiustech.se             --                                 --
: -- wengelin@ozspace.brisnet.org.au --                                 --

-Tucker Taft  stt@inmet.com
Intermetrics, Inc.



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1995-02-28 21:46 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1995-02-24 10:37 Including Ada objects in non-Ada environments Daneil Wengelin
1995-02-28 21:46 ` Tucker Taft

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox