Welcome to Ada Semantic Interface Specification for GNAT

This Project is dedicated to providing an up-to-date ASIS interface for the current GNAT. Also various tools based on ASIS are provided; these tools include the very useful gnatelim optimization tool and the adabrowse documentation generator.

Note that the version of ASIS managed by this project is based on a pure GNU Public License (GPL) distribution. While some of the tools have more liberal terms (e.g. GNAT Modified GPL with the generic and linking exception), the fact that the base ASIS source code is GPL means that normal GPL rules apply when distributing binaries linked to this library.

How to get ASIS

Getting ASIS takes three steps.

Get Compiler Sources

ASIS works very closely with the compiler and a single ASIS compile is only guaranteed to work with the compiler it was created with. This leaves you with three options open:

  • Compile your own compiler. The best but also the most difficult option. The following site might help you: http://www.krischik.com/Ada/gnat-3_4.html.
  • Install the source package of your compiler. If you have a pre-compiled compiler then you might try to install the source package which – hopefully – has been provided.
  • Use the compiler extract provided. The ASIS source packages provided contain extracts from various compiler version. They are stored in subdirectories of the ./gnat directory called ./gnat/gnat-3.4.0, ./gnat/gnat-3.4.1 and so on. Use the one which best matches your compiler and hope for the best.

Get ASIS

The current version is always available from the SVN repository. See https://sourceforge.net/svn/?group_id=104293 how to download it from SVN.

For those who are not confident with SVN, binary and source packages are provided. If you decide to download a source package download the newest one. All source packages contain all compiler extracts gathered until it was released, regardless of the package version number. If you decide for a binary release use the one which match your compiler closest and hope for the best.

Compile ASIS

In order to create a working A.S.I.S. you have to copy some of the files from the original compiler sources to the ./gnat directory within ASIS. This is done automatically when the GNATSRC environment variable is set. If you have downloaded your compiler sources at /work/gnu_4.0/gcc then set GNATSRC=/work/gnu_4.0/gcc/gcc/ada. If you want to use the sources provided the unset GNATSRC and copy manually.

You can then compile ASIS with the following commands:

 unset ADA_INCLUDE_PATH
 unset ADA_OBJECTS_PATH
 unset ADA_PROJECT_PATH
 unset CFLAGS
 unset CPPFLAGS
 unset ADA_CFLAGS
 unset ADAFLAGS

 make
 make install
 make
 make install

Notes:

  • Of course you only need to “unset” variables which you set in the first place.
  • You might need to use make/make install twice – as indicated – because some of the provided tools need an installed ASIS to compile.

The ASIS library will be installed to /opt/ada/include/asis and the ASIS tools to /opt/ada/bin. You can change the installation directory inside the Makefile.stub makefile. If you would rather have a full featured “configure” drop me a mail and I make you a project developer.


Ada programming, © 2005,2006 the Authors, Content is available under GNU Free Documentation License.