comp.lang.ada
 help / color / mirror / Atom feed
* ASIS for MinGW GNAT
@ 2005-02-12  4:08 Fionn mac Cuimhaill
  2005-02-12  8:26 ` Martin Krischik
  2005-02-12  8:58 ` Stephen Leake
  0 siblings, 2 replies; 6+ messages in thread
From: Fionn mac Cuimhaill @ 2005-02-12  4:08 UTC (permalink / raw)


Has anybody  successfully installed  Martin Krischik's ASIS for use by
the latest MinGW GNAT (3.4.2)?

I presume that this is a non-trivial project. Otherwise, it could
reasonable expected to be already be a part of MinGW.


Also, could somebody explain why ASIS is so sensitive to compiler
versions?



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

* Re: ASIS for MinGW GNAT
  2005-02-12  4:08 ASIS for MinGW GNAT Fionn mac Cuimhaill
@ 2005-02-12  8:26 ` Martin Krischik
  2005-02-12 14:28   ` Martin Dowie
  2005-02-12 18:05   ` Fionn mac Cuimhaill
  2005-02-12  8:58 ` Stephen Leake
  1 sibling, 2 replies; 6+ messages in thread
From: Martin Krischik @ 2005-02-12  8:26 UTC (permalink / raw)


Fionn mac Cuimhaill wrote:

> I presume that this is a non-trivial project. Otherwise, it could
> reasonable expected to be already be a part of MinGW.

I am unsure if the MinGW maintainers are interested in ASIS. However, if you
are successful I make you a maintainer and you can make binary releases at
sourceforge

> Also, could somebody explain why ASIS is so sensitive to compiler
> versions?

Yes, the compiler writes tree files (Compiler option -gnatT, File XXX.adt)
which contain the semantic tree which ASIS reads for the analysis.

The library for reading and writing tree files is shared betreen compiler
and ASIS and changes frequently. 

And since the tree file library ony exists as source you need to copy the
relevant files from the gcc directroy tree to the ASIS tree. (In *x one can
also use a symbolic link).

Martin
-- 
mailto://krischik@users.sourceforge.net
Ada programming at: http://ada.krischik.com




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

* Re: ASIS for MinGW GNAT
  2005-02-12  4:08 ASIS for MinGW GNAT Fionn mac Cuimhaill
  2005-02-12  8:26 ` Martin Krischik
@ 2005-02-12  8:58 ` Stephen Leake
  1 sibling, 0 replies; 6+ messages in thread
From: Stephen Leake @ 2005-02-12  8:58 UTC (permalink / raw)
  To: comp.lang.ada

Fionn mac Cuimhaill <invisible@hiding.from.spam> writes:

> Has anybody  successfully installed  Martin Krischik's ASIS for use by
> the latest MinGW GNAT (3.4.2)?

This is on my list of things to do, but I'm pretty overloaded at work
right now, so it won't be soon.

> I presume that this is a non-trivial project. Otherwise, it could
> reasonable expected to be already be a part of MinGW.

Yes. After I try it, I'll see what it would take to get it into the
MinGW distribution.

> Also, could somebody explain why ASIS is so sensitive to compiler
> versions?

Strictly speaking, "ASIS" is a standard that doesn't change (well, it
changes when the Ada standard changes). What is sensitive to compiler
versions is the application library commonly called "ASIS-for-GNAT",
which implements ASIS for the GNAT compiler.

In short, ASIS works by querying the compiler's internal data
structures. In the case of GNAT (and probably most compilers), those
data structures change (I hope only slightly !) for each release of
the compiler.

The input to ASIS-for-GNAT is the "tree" file dumped by the compiler.
That tree file is a serialization of the compiler's internal data
structures. Since the data structures change, the format of the tree
file changes, and ASIS-for-GNAT must change.

-- 
-- Stephe




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

* Re: ASIS for MinGW GNAT
  2005-02-12  8:26 ` Martin Krischik
@ 2005-02-12 14:28   ` Martin Dowie
  2005-02-12 18:05   ` Fionn mac Cuimhaill
  1 sibling, 0 replies; 6+ messages in thread
From: Martin Dowie @ 2005-02-12 14:28 UTC (permalink / raw)


>>Also, could somebody explain why ASIS is so sensitive to compiler
>>versions?
> 
> Yes, the compiler writes tree files (Compiler option -gnatT, File XXX.adt)
> which contain the semantic tree which ASIS reads for the analysis.

Not quite...

-gnatt
     Tree output file to be generated.

-gnatT nnn
     Set time slice to specified number of microseconds

Cheers

-- Martin



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

* Re: ASIS for MinGW GNAT
  2005-02-12  8:26 ` Martin Krischik
  2005-02-12 14:28   ` Martin Dowie
@ 2005-02-12 18:05   ` Fionn mac Cuimhaill
  2005-02-12 20:10     ` Martin Krischik
  1 sibling, 1 reply; 6+ messages in thread
From: Fionn mac Cuimhaill @ 2005-02-12 18:05 UTC (permalink / raw)


On Sat, 12 Feb 2005 09:26:44 +0100, Martin Krischik
<martin@krischik.com> wrote:

>Fionn mac Cuimhaill wrote:
>
>> I presume that this is a non-trivial project. Otherwise, it could
>> reasonable expected to be already be a part of MinGW.
>
>I am unsure if the MinGW maintainers are interested in ASIS. However, if you
>are successful I make you a maintainer and you can make binary releases at
>sourceforge
>
> ... snip ...
It turned out to be simpler than I expected. I built ASIS on my
Windows XP development computer.

I downloaded the MinGW Ada source, (which is v 3.4.2,) and your newest
ASIS. After extracting both, I found that ASIS already had the
relevant parts of the GNAT Ada compiler extracted into various
subdirectories, one for each of several versions of the compiler.
3.4.2 was missing. I created the appropriate subdirectory, and, using
one of the other directories as a model, I copied all of the
appropriate GNAT source files into the ASIS 3.4.2 subdirectory .

I copied the asis_install.bat to asi_install.cmd and used that to
install ASIS. I needed to do only two minor changes to the existing
configuration to build ASIS:

1. asis_install needed the compiler sources to be moved upstairs one
directory level.

2. The version.c file was not being compiled. I added one line to
asis_install.cmd, immediately after this line:

gnatmake -c -I../gnat -I../asis -g -O2 install_asis.adb

The new line is:
gcc -c ../gnat/version.c

There was one compilation warning about a variable possibly being used
before it was initialized.

I now have a working gnatstub, which was what I wanted.





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

* Re: ASIS for MinGW GNAT
  2005-02-12 18:05   ` Fionn mac Cuimhaill
@ 2005-02-12 20:10     ` Martin Krischik
  0 siblings, 0 replies; 6+ messages in thread
From: Martin Krischik @ 2005-02-12 20:10 UTC (permalink / raw)


Cuimhaill wrote:

> On Sat, 12 Feb 2005 09:26:44 +0100, Martin Krischik
> <martin@krischik.com> wrote:

> I downloaded the MinGW Ada source, (which is v 3.4.2,) and your newest
> ASIS. After extracting both, I found that ASIS already had the
> relevant parts of the GNAT Ada compiler extracted into various
> subdirectories, one for each of several versions of the compiler.
> 3.4.2 was missing.

Actually 3.4.2 is there - but it's empty since I skipped that release on
Linux. If you send me the sources I check them in. 

> 1. asis_install needed the compiler sources to be moved upstairs one
> directory level.

That is allways the case. And it is in the new doc: " If you want to use the
sources provided the unset GNATSRC and copy manually."

> 2. The version.c file was not being compiled. I added one line to
> asis_install.cmd, immediately after this line:

Yes I only use make and not the batch - so I have missed that. 
 
> I now have a working gnatstub, which was what I wanted.

Cool. If you could have a look make_release batch and create a similar
make_release.cmd than we could all have a binary release.

You can either e-mail me the package or tell me your sourforge user and I
make you a project member.

Martin 

-- 
mailto://krischik@users.sourceforge.net
Ada programming at: http://ada.krischik.com




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

end of thread, other threads:[~2005-02-12 20:10 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-02-12  4:08 ASIS for MinGW GNAT Fionn mac Cuimhaill
2005-02-12  8:26 ` Martin Krischik
2005-02-12 14:28   ` Martin Dowie
2005-02-12 18:05   ` Fionn mac Cuimhaill
2005-02-12 20:10     ` Martin Krischik
2005-02-12  8:58 ` Stephen Leake

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