www.delorie.com/gnu/docs/gcc/gnat_ug_60.html   search  
Buy the book!

Untitled Document

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

4. Binding Using gnatbind

4.1 Running gnatbind  
4.2 Generating the Binder Program in C  
4.3 Consistency-Checking Modes  
4.4 Binder Error Message Control  
4.5 Elaboration Control  
4.6 Output Control  
4.7 Binding with Non-Ada Main Programs  
4.8 Binding Programs with No Main Subprogram  
4.9 Summary of Binder Switches  
4.10 Command-Line Access  
4.11 Search Paths for gnatbind  
4.12 Examples of gnatbind Usage  

This chapter describes the GNAT binder, gnatbind, which is used to bind compiled GNAT objects. The gnatbind program performs four separate functions:

  1. Checks that a program is consistent, in accordance with the rules in Chapter 10 of the Ada 95 Reference Manual. In particular, error messages are generated if a program uses inconsistent versions of a given unit.

  2. Checks that an acceptable order of elaboration exists for the program and issues an error message if it cannot find an order of elaboration that satisfies the rules in Chapter 10 of the Ada 95 Language Manual.

  3. Generates a main program incorporating the given elaboration order. This program is a small Ada package (body and spec) that must be subsequently compiled using the GNAT compiler. The necessary compilation step is usually performed automatically by gnatlink. The two most important functions of this program are to call the elaboration routines of units in an appropriate order and to call the main program.

  4. Determines the set of object files required by the given main program. This information is output in the forms of comments in the generated program, to be read by the gnatlink utility used to link the Ada application.

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

  webmaster     delorie software   privacy  
  Copyright 2003   by The Free Software Foundation     Updated Jun 2003