@copying
@quotation
-GNAT User's Guide for Native Platforms , Nov 04, 2024
+GNAT User's Guide for Native Platforms , Nov 08, 2024
AdaCore
* Automatically Creating a List of Directories::
* Generating the Command Line Switches::
* Overcoming Command Line Length Limits::
+* GNAT with the LLVM Back End::
GNAT Utility Programs
a year suffix apply to all versions of the Ada language starting with
Ada 95.
+GNAT supports both the GCC and LLVM back end compilation families.
+Most GNAT versions use the GCC back end, but some are now available using
+the LLVM back end. In some places in this manual, we distinguish between
+the two back ends, but in most cases, everything in this manual applies
+to both back ends. We refer to GNAT with the LLVM back end as ‘GNAT LLVM’.
+See @ref{7,,GNAT with the LLVM Back End} for limitations of GNAT LLVM.
+
@menu
* What This Guide Contains::
* What You Should Know before Reading This Guide::
@end menu
@node What This Guide Contains,What You Should Know before Reading This Guide,,About This Guide
-@anchor{gnat_ugn/about_this_guide what-this-guide-contains}@anchor{7}
+@anchor{gnat_ugn/about_this_guide what-this-guide-contains}@anchor{8}
@section What This Guide Contains
@itemize *
@item
-@ref{8,,Getting Started with GNAT} describes how to get started compiling
+@ref{9,,Getting Started with GNAT} describes how to get started compiling
and running Ada programs with the GNAT Ada programming environment.
@item
-@ref{9,,The GNAT Compilation Model} describes the compilation model used
+@ref{a,,The GNAT Compilation Model} describes the compilation model used
by GNAT.
@item
-@ref{a,,Building Executable Programs with GNAT} describes how to use the
+@ref{b,,Building Executable Programs with GNAT} describes how to use the
main GNAT tools to build executable programs, and it also gives examples of
using the GNU make utility with GNAT.
@item
-@ref{b,,GNAT Utility Programs} explains the various utility programs that
+@ref{c,,GNAT Utility Programs} explains the various utility programs that
are included in the GNAT environment.
@item
-@ref{c,,GNAT and Program Execution} covers a number of topics related to
+@ref{d,,GNAT and Program Execution} covers a number of topics related to
running, debugging, and tuning the performance of programs developed
with GNAT.
@end itemize
@itemize *
@item
-@ref{d,,Platform-Specific Information} describes the different run-time
+@ref{e,,Platform-Specific Information} describes the different run-time
library implementations and also presents information on how to use
GNAT on several specific platforms.
@item
-@ref{e,,Example of Binder Output File} shows the source code for the binder
+@ref{f,,Example of Binder Output File} shows the source code for the binder
output file for a sample program.
@item
-@ref{f,,Elaboration Order Handling in GNAT} describes how GNAT helps
+@ref{10,,Elaboration Order Handling in GNAT} describes how GNAT helps
you deal with elaboration order issues.
@item
-@ref{10,,Inline Assembler} shows how to use the inline assembly facility
+@ref{11,,Inline Assembler} shows how to use the inline assembly facility
in an Ada program.
@end itemize
@node What You Should Know before Reading This Guide,Related Information,What This Guide Contains,About This Guide
-@anchor{gnat_ugn/about_this_guide what-you-should-know-before-reading-this-guide}@anchor{11}
+@anchor{gnat_ugn/about_this_guide what-you-should-know-before-reading-this-guide}@anchor{12}
@section What You Should Know before Reading This Guide
the GNAT documentation package.
@node Related Information,Conventions,What You Should Know before Reading This Guide,About This Guide
-@anchor{gnat_ugn/about_this_guide related-information}@anchor{12}
+@anchor{gnat_ugn/about_this_guide related-information}@anchor{13}
@section Related Information
@end itemize
@node Conventions,,Related Information,About This Guide
-@anchor{gnat_ugn/about_this_guide conventions}@anchor{13}
+@anchor{gnat_ugn/about_this_guide conventions}@anchor{14}
@section Conventions
@end itemize
@node Getting Started with GNAT,The GNAT Compilation Model,About This Guide,Top
-@anchor{gnat_ugn/getting_started_with_gnat doc}@anchor{14}@anchor{gnat_ugn/getting_started_with_gnat getting-started-with-gnat}@anchor{8}@anchor{gnat_ugn/getting_started_with_gnat id1}@anchor{15}
+@anchor{gnat_ugn/getting_started_with_gnat doc}@anchor{15}@anchor{gnat_ugn/getting_started_with_gnat getting-started-with-gnat}@anchor{9}@anchor{gnat_ugn/getting_started_with_gnat id1}@anchor{16}
@chapter Getting Started with GNAT
@end menu
@node System Requirements,Running GNAT,,Getting Started with GNAT
-@anchor{gnat_ugn/getting_started_with_gnat id2}@anchor{16}@anchor{gnat_ugn/getting_started_with_gnat system-requirements}@anchor{17}
+@anchor{gnat_ugn/getting_started_with_gnat id2}@anchor{17}@anchor{gnat_ugn/getting_started_with_gnat system-requirements}@anchor{18}
@section System Requirements
@code{Object_Dir} project file attribute.
@node Running GNAT,Running a Simple Ada Program,System Requirements,Getting Started with GNAT
-@anchor{gnat_ugn/getting_started_with_gnat id3}@anchor{18}@anchor{gnat_ugn/getting_started_with_gnat running-gnat}@anchor{19}
+@anchor{gnat_ugn/getting_started_with_gnat id3}@anchor{19}@anchor{gnat_ugn/getting_started_with_gnat running-gnat}@anchor{1a}
@section Running GNAT
performs the necessary compilation, binding, and linking steps.
@node Running a Simple Ada Program,Running a Program with Multiple Units,Running GNAT,Getting Started with GNAT
-@anchor{gnat_ugn/getting_started_with_gnat id4}@anchor{1a}@anchor{gnat_ugn/getting_started_with_gnat running-a-simple-ada-program}@anchor{1b}
+@anchor{gnat_ugn/getting_started_with_gnat id4}@anchor{1b}@anchor{gnat_ugn/getting_started_with_gnat running-a-simple-ada-program}@anchor{1c}
@section Running a Simple Ada Program
extension is @code{ads} for a
spec and @code{adb} for a body.
You can override this default file naming convention by use of the
-special pragma @code{Source_File_Name} (see @ref{1c,,Using Other File Names}).
+special pragma @code{Source_File_Name} (see @ref{1d,,Using Other File Names}).
Alternatively, if you want to rename your files according to this default
convention, which is probably more convenient if you will be using GNAT
for all your compilations, then you use can use the @code{gnatchop} utility
to generate correctly-named source files
-(see @ref{1d,,Renaming Files with gnatchop}).
+(see @ref{1e,,Renaming Files with gnatchop}).
You can compile the program using the following command (@code{$} is used
as the command prompt in the examples in this document):
appear in response to this command.
@node Running a Program with Multiple Units,,Running a Simple Ada Program,Getting Started with GNAT
-@anchor{gnat_ugn/getting_started_with_gnat id5}@anchor{1e}@anchor{gnat_ugn/getting_started_with_gnat running-a-program-with-multiple-units}@anchor{1f}
+@anchor{gnat_ugn/getting_started_with_gnat id5}@anchor{1f}@anchor{gnat_ugn/getting_started_with_gnat running-a-program-with-multiple-units}@anchor{20}
@section Running a Program with Multiple Units
@c -- Example: A |withing| unit has a |with| clause, it |withs| a |withed| unit
@node The GNAT Compilation Model,Building Executable Programs with GNAT,Getting Started with GNAT,Top
-@anchor{gnat_ugn/the_gnat_compilation_model doc}@anchor{20}@anchor{gnat_ugn/the_gnat_compilation_model id1}@anchor{21}@anchor{gnat_ugn/the_gnat_compilation_model the-gnat-compilation-model}@anchor{9}
+@anchor{gnat_ugn/the_gnat_compilation_model doc}@anchor{21}@anchor{gnat_ugn/the_gnat_compilation_model id1}@anchor{22}@anchor{gnat_ugn/the_gnat_compilation_model the-gnat-compilation-model}@anchor{a}
@chapter The GNAT Compilation Model
@itemize *
@item
-@ref{22,,Source Representation}
+@ref{23,,Source Representation}
@item
-@ref{23,,Foreign Language Representation}
+@ref{24,,Foreign Language Representation}
@item
-@ref{24,,File Naming Topics and Utilities}
+@ref{25,,File Naming Topics and Utilities}
@end itemize
@item
-@ref{25,,Configuration Pragmas}
+@ref{26,,Configuration Pragmas}
@item
-@ref{26,,Generating Object Files}
+@ref{27,,Generating Object Files}
@item
-@ref{27,,Source Dependencies}
+@ref{28,,Source Dependencies}
@item
-@ref{28,,The Ada Library Information Files}
+@ref{29,,The Ada Library Information Files}
@item
-@ref{29,,Binding an Ada Program}
+@ref{2a,,Binding an Ada Program}
@item
-@ref{2a,,GNAT and Libraries}
+@ref{2b,,GNAT and Libraries}
@item
-@ref{2b,,Conditional Compilation}
+@ref{2c,,Conditional Compilation}
@item
-@ref{2c,,Mixed Language Programming}
+@ref{2d,,Mixed Language Programming}
@item
-@ref{2d,,GNAT and Other Compilation Models}
+@ref{2e,,GNAT and Other Compilation Models}
@item
-@ref{2e,,Using GNAT Files with External Tools}
+@ref{2f,,Using GNAT Files with External Tools}
@end itemize
@menu
@end menu
@node Source Representation,Foreign Language Representation,,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model id2}@anchor{2f}@anchor{gnat_ugn/the_gnat_compilation_model source-representation}@anchor{22}
+@anchor{gnat_ugn/the_gnat_compilation_model id2}@anchor{30}@anchor{gnat_ugn/the_gnat_compilation_model source-representation}@anchor{23}
@section Source Representation
Ada source programs are represented in standard text files, using
Latin-1 coding. Latin-1 is an 8-bit code that includes the familiar
7-bit ASCII set plus additional characters used for
-representing foreign languages (see @ref{23,,Foreign Language Representation}
+representing foreign languages (see @ref{24,,Foreign Language Representation}
for support of non-USA character sets). The format effector characters
are represented using their standard ASCII encodings, as follows:
you place each subunit or child unit in a separate file.
@node Foreign Language Representation,File Naming Topics and Utilities,Source Representation,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model foreign-language-representation}@anchor{23}@anchor{gnat_ugn/the_gnat_compilation_model id3}@anchor{30}
+@anchor{gnat_ugn/the_gnat_compilation_model foreign-language-representation}@anchor{24}@anchor{gnat_ugn/the_gnat_compilation_model id3}@anchor{31}
@section Foreign Language Representation
GNAT supports the standard character sets defined in Ada as well as
several other non-standard character sets for use in localized versions
-of the compiler (@ref{31,,Character Set Control}).
+of the compiler (@ref{32,,Character Set Control}).
@menu
* Latin-1::
@end menu
@node Latin-1,Other 8-Bit Codes,,Foreign Language Representation
-@anchor{gnat_ugn/the_gnat_compilation_model id4}@anchor{32}@anchor{gnat_ugn/the_gnat_compilation_model latin-1}@anchor{33}
+@anchor{gnat_ugn/the_gnat_compilation_model id4}@anchor{33}@anchor{gnat_ugn/the_gnat_compilation_model latin-1}@anchor{34}
@subsection Latin-1
letters can be used in identifiers.
@node Other 8-Bit Codes,Wide_Character Encodings,Latin-1,Foreign Language Representation
-@anchor{gnat_ugn/the_gnat_compilation_model id5}@anchor{34}@anchor{gnat_ugn/the_gnat_compilation_model other-8-bit-codes}@anchor{35}
+@anchor{gnat_ugn/the_gnat_compilation_model id5}@anchor{35}@anchor{gnat_ugn/the_gnat_compilation_model other-8-bit-codes}@anchor{36}
@subsection Other 8-Bit Codes
of GNAT to obtain this file.
@node Wide_Character Encodings,Wide_Wide_Character Encodings,Other 8-Bit Codes,Foreign Language Representation
-@anchor{gnat_ugn/the_gnat_compilation_model id6}@anchor{36}@anchor{gnat_ugn/the_gnat_compilation_model wide-character-encodings}@anchor{37}
+@anchor{gnat_ugn/the_gnat_compilation_model id6}@anchor{37}@anchor{gnat_ugn/the_gnat_compilation_model wide-character-encodings}@anchor{38}
@subsection Wide_Character Encodings
@end cartouche
@node Wide_Wide_Character Encodings,,Wide_Character Encodings,Foreign Language Representation
-@anchor{gnat_ugn/the_gnat_compilation_model id7}@anchor{38}@anchor{gnat_ugn/the_gnat_compilation_model wide-wide-character-encodings}@anchor{39}
+@anchor{gnat_ugn/the_gnat_compilation_model id7}@anchor{39}@anchor{gnat_ugn/the_gnat_compilation_model wide-wide-character-encodings}@anchor{3a}
@subsection Wide_Wide_Character Encodings
@end table
@node File Naming Topics and Utilities,Configuration Pragmas,Foreign Language Representation,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model file-naming-topics-and-utilities}@anchor{24}@anchor{gnat_ugn/the_gnat_compilation_model id8}@anchor{3a}
+@anchor{gnat_ugn/the_gnat_compilation_model file-naming-topics-and-utilities}@anchor{25}@anchor{gnat_ugn/the_gnat_compilation_model id8}@anchor{3b}
@section File Naming Topics and Utilities
@end menu
@node File Naming Rules,Using Other File Names,,File Naming Topics and Utilities
-@anchor{gnat_ugn/the_gnat_compilation_model file-naming-rules}@anchor{3b}@anchor{gnat_ugn/the_gnat_compilation_model id9}@anchor{3c}
+@anchor{gnat_ugn/the_gnat_compilation_model file-naming-rules}@anchor{3c}@anchor{gnat_ugn/the_gnat_compilation_model id9}@anchor{3d}
@subsection File Naming Rules
heavily nested). An option is available to shorten such long file names
(called file name ‘krunching’). You may find this particularly useful when
programs being developed with GNAT are to be used on operating systems
-with limited file name lengths. @ref{3d,,Using gnatkr}.
+with limited file name lengths. @ref{3e,,Using gnatkr}.
Of course, no file shortening algorithm can guarantee uniqueness over
all possible unit names; if file name krunching is used, it is your
in the next section. Finally, if your Ada programs are migrating from a
compiler with a different naming convention, you can use the @code{gnatchop}
utility to produce source files that follow the GNAT naming conventions.
-(For details see @ref{1d,,Renaming Files with gnatchop}.)
+(For details see @ref{1e,,Renaming Files with gnatchop}.)
Note: in the case of Windows or Mac OS operating systems, case is not
significant. So, for example, on Windows if the canonical name is
you need to follow the procedures described in the next section.
@node Using Other File Names,Alternative File Naming Schemes,File Naming Rules,File Naming Topics and Utilities
-@anchor{gnat_ugn/the_gnat_compilation_model id10}@anchor{3e}@anchor{gnat_ugn/the_gnat_compilation_model using-other-file-names}@anchor{1c}
+@anchor{gnat_ugn/the_gnat_compilation_model id10}@anchor{3f}@anchor{gnat_ugn/the_gnat_compilation_model using-other-file-names}@anchor{1d}
@subsection Using Other File Names
file used to hold configuration
pragmas that apply to a complete compilation environment.
For more details on how the @code{gnat.adc} file is created and used
-see @ref{3f,,Handling of Configuration Pragmas}.
+see @ref{40,,Handling of Configuration Pragmas}.
@geindex gnat.adc
be omitted.
@node Alternative File Naming Schemes,Handling Arbitrary File Naming Conventions with gnatname,Using Other File Names,File Naming Topics and Utilities
-@anchor{gnat_ugn/the_gnat_compilation_model alternative-file-naming-schemes}@anchor{40}@anchor{gnat_ugn/the_gnat_compilation_model id11}@anchor{41}
+@anchor{gnat_ugn/the_gnat_compilation_model alternative-file-naming-schemes}@anchor{41}@anchor{gnat_ugn/the_gnat_compilation_model id11}@anchor{42}
@subsection Alternative File Naming Schemes
@geindex gnatname
@node Handling Arbitrary File Naming Conventions with gnatname,File Name Krunching with gnatkr,Alternative File Naming Schemes,File Naming Topics and Utilities
-@anchor{gnat_ugn/the_gnat_compilation_model handling-arbitrary-file-naming-conventions-with-gnatname}@anchor{42}@anchor{gnat_ugn/the_gnat_compilation_model id12}@anchor{43}
+@anchor{gnat_ugn/the_gnat_compilation_model handling-arbitrary-file-naming-conventions-with-gnatname}@anchor{43}@anchor{gnat_ugn/the_gnat_compilation_model id12}@anchor{44}
@subsection Handling Arbitrary File Naming Conventions with @code{gnatname}
@end menu
@node Arbitrary File Naming Conventions,Running gnatname,,Handling Arbitrary File Naming Conventions with gnatname
-@anchor{gnat_ugn/the_gnat_compilation_model arbitrary-file-naming-conventions}@anchor{44}@anchor{gnat_ugn/the_gnat_compilation_model id13}@anchor{45}
+@anchor{gnat_ugn/the_gnat_compilation_model arbitrary-file-naming-conventions}@anchor{45}@anchor{gnat_ugn/the_gnat_compilation_model id13}@anchor{46}
@subsubsection Arbitrary File Naming Conventions
When the source file names do not follow the standard GNAT default
file naming conventions, you must give the GNAT compiler additional
information through a configuration pragmas file
-(@ref{25,,Configuration Pragmas}) or a project file. When the
+(@ref{26,,Configuration Pragmas}) or a project file. When the
non-standard file naming conventions are well-defined, a small number
of pragmas @code{Source_File_Name} specifying a naming pattern
-(@ref{40,,Alternative File Naming Schemes}) may be sufficient. However,
+(@ref{41,,Alternative File Naming Schemes}) may be sufficient. However,
if the file naming conventions are irregular or arbitrary, you must
define a number of pragma @code{Source_File_Name} for individual
compilation units. To help maintain the correspondence between
set of files.
@node Running gnatname,Switches for gnatname,Arbitrary File Naming Conventions,Handling Arbitrary File Naming Conventions with gnatname
-@anchor{gnat_ugn/the_gnat_compilation_model id14}@anchor{46}@anchor{gnat_ugn/the_gnat_compilation_model running-gnatname}@anchor{47}
+@anchor{gnat_ugn/the_gnat_compilation_model id14}@anchor{47}@anchor{gnat_ugn/the_gnat_compilation_model running-gnatname}@anchor{48}
@subsubsection Running @code{gnatname}
unit.
@node Switches for gnatname,Examples of gnatname Usage,Running gnatname,Handling Arbitrary File Naming Conventions with gnatname
-@anchor{gnat_ugn/the_gnat_compilation_model id15}@anchor{48}@anchor{gnat_ugn/the_gnat_compilation_model switches-for-gnatname}@anchor{49}
+@anchor{gnat_ugn/the_gnat_compilation_model id15}@anchor{49}@anchor{gnat_ugn/the_gnat_compilation_model switches-for-gnatname}@anchor{4a}
@subsubsection Switches for @code{gnatname}
@end table
@node Examples of gnatname Usage,,Switches for gnatname,Handling Arbitrary File Naming Conventions with gnatname
-@anchor{gnat_ugn/the_gnat_compilation_model examples-of-gnatname-usage}@anchor{4a}@anchor{gnat_ugn/the_gnat_compilation_model id16}@anchor{4b}
+@anchor{gnat_ugn/the_gnat_compilation_model examples-of-gnatname-usage}@anchor{4b}@anchor{gnat_ugn/the_gnat_compilation_model id16}@anchor{4c}
@subsubsection Examples of @code{gnatname} Usage
illustrates multiple Naming Patterns and one excluded pattern.
@node File Name Krunching with gnatkr,Renaming Files with gnatchop,Handling Arbitrary File Naming Conventions with gnatname,File Naming Topics and Utilities
-@anchor{gnat_ugn/the_gnat_compilation_model file-name-krunching-with-gnatkr}@anchor{4c}@anchor{gnat_ugn/the_gnat_compilation_model id17}@anchor{4d}
+@anchor{gnat_ugn/the_gnat_compilation_model file-name-krunching-with-gnatkr}@anchor{4d}@anchor{gnat_ugn/the_gnat_compilation_model id17}@anchor{4e}
@subsection File Name Krunching with @code{gnatkr}
@end menu
@node About gnatkr,Using gnatkr,,File Name Krunching with gnatkr
-@anchor{gnat_ugn/the_gnat_compilation_model about-gnatkr}@anchor{4e}@anchor{gnat_ugn/the_gnat_compilation_model id18}@anchor{4f}
+@anchor{gnat_ugn/the_gnat_compilation_model about-gnatkr}@anchor{4f}@anchor{gnat_ugn/the_gnat_compilation_model id18}@anchor{50}
@subsubsection About @code{gnatkr}
a given file when krunched to a specified maximum length.
@node Using gnatkr,Krunching Method,About gnatkr,File Name Krunching with gnatkr
-@anchor{gnat_ugn/the_gnat_compilation_model id19}@anchor{50}@anchor{gnat_ugn/the_gnat_compilation_model using-gnatkr}@anchor{3d}
+@anchor{gnat_ugn/the_gnat_compilation_model id19}@anchor{51}@anchor{gnat_ugn/the_gnat_compilation_model using-gnatkr}@anchor{3e}
@subsubsection Using @code{gnatkr}
original argument was a file name with an extension.
@node Krunching Method,Examples of gnatkr Usage,Using gnatkr,File Name Krunching with gnatkr
-@anchor{gnat_ugn/the_gnat_compilation_model id20}@anchor{51}@anchor{gnat_ugn/the_gnat_compilation_model krunching-method}@anchor{52}
+@anchor{gnat_ugn/the_gnat_compilation_model id20}@anchor{52}@anchor{gnat_ugn/the_gnat_compilation_model krunching-method}@anchor{53}
@subsubsection Krunching Method
krunched name of a file.
@node Examples of gnatkr Usage,,Krunching Method,File Name Krunching with gnatkr
-@anchor{gnat_ugn/the_gnat_compilation_model examples-of-gnatkr-usage}@anchor{53}@anchor{gnat_ugn/the_gnat_compilation_model id21}@anchor{54}
+@anchor{gnat_ugn/the_gnat_compilation_model examples-of-gnatkr-usage}@anchor{54}@anchor{gnat_ugn/the_gnat_compilation_model id21}@anchor{55}
@subsubsection Examples of @code{gnatkr} Usage
@end example
@node Renaming Files with gnatchop,,File Name Krunching with gnatkr,File Naming Topics and Utilities
-@anchor{gnat_ugn/the_gnat_compilation_model id22}@anchor{55}@anchor{gnat_ugn/the_gnat_compilation_model renaming-files-with-gnatchop}@anchor{1d}
+@anchor{gnat_ugn/the_gnat_compilation_model id22}@anchor{56}@anchor{gnat_ugn/the_gnat_compilation_model renaming-files-with-gnatchop}@anchor{1e}
@subsection Renaming Files with @code{gnatchop}
@end menu
@node Handling Files with Multiple Units,Operating gnatchop in Compilation Mode,,Renaming Files with gnatchop
-@anchor{gnat_ugn/the_gnat_compilation_model handling-files-with-multiple-units}@anchor{56}@anchor{gnat_ugn/the_gnat_compilation_model id23}@anchor{57}
+@anchor{gnat_ugn/the_gnat_compilation_model handling-files-with-multiple-units}@anchor{57}@anchor{gnat_ugn/the_gnat_compilation_model id23}@anchor{58}
@subsubsection Handling Files with Multiple Units
you can use @code{gnatname} to generate or update your project files, which
can be processed by GNAT.
-See @ref{42,,Handling Arbitrary File Naming Conventions with gnatname}
+See @ref{43,,Handling Arbitrary File Naming Conventions with gnatname}
for more details on how to use @cite{gnatname}.
Alternatively, if you want to permanently restructure a set of
automatically in UTF-8 mode without you needing to specify an explicit encoding.
@node Operating gnatchop in Compilation Mode,Command Line for gnatchop,Handling Files with Multiple Units,Renaming Files with gnatchop
-@anchor{gnat_ugn/the_gnat_compilation_model id24}@anchor{58}@anchor{gnat_ugn/the_gnat_compilation_model operating-gnatchop-in-compilation-mode}@anchor{59}
+@anchor{gnat_ugn/the_gnat_compilation_model id24}@anchor{59}@anchor{gnat_ugn/the_gnat_compilation_model operating-gnatchop-in-compilation-mode}@anchor{5a}
@subsubsection Operating gnatchop in Compilation Mode
environment. Using GNAT, the current directory, possibly containing a
@code{gnat.adc} file is the representation
of a compilation environment. For more information on the
-@code{gnat.adc} file, see @ref{3f,,Handling of Configuration Pragmas}.
+@code{gnat.adc} file, see @ref{40,,Handling of Configuration Pragmas}.
Second, in compilation mode, if you give @code{gnatchop} a file that
starts with configuration pragmas and contains one or more units, then
in which GNAT processes the ACVC tests.
@node Command Line for gnatchop,Switches for gnatchop,Operating gnatchop in Compilation Mode,Renaming Files with gnatchop
-@anchor{gnat_ugn/the_gnat_compilation_model command-line-for-gnatchop}@anchor{5a}@anchor{gnat_ugn/the_gnat_compilation_model id25}@anchor{5b}
+@anchor{gnat_ugn/the_gnat_compilation_model command-line-for-gnatchop}@anchor{5b}@anchor{gnat_ugn/the_gnat_compilation_model id25}@anchor{5c}
@subsubsection Command Line for @code{gnatchop}
@end example
@node Switches for gnatchop,Examples of gnatchop Usage,Command Line for gnatchop,Renaming Files with gnatchop
-@anchor{gnat_ugn/the_gnat_compilation_model id26}@anchor{5c}@anchor{gnat_ugn/the_gnat_compilation_model switches-for-gnatchop}@anchor{5d}
+@anchor{gnat_ugn/the_gnat_compilation_model id26}@anchor{5d}@anchor{gnat_ugn/the_gnat_compilation_model switches-for-gnatchop}@anchor{5e}
@subsubsection Switches for @code{gnatchop}
@end table
@node Examples of gnatchop Usage,,Switches for gnatchop,Renaming Files with gnatchop
-@anchor{gnat_ugn/the_gnat_compilation_model examples-of-gnatchop-usage}@anchor{5e}@anchor{gnat_ugn/the_gnat_compilation_model id27}@anchor{5f}
+@anchor{gnat_ugn/the_gnat_compilation_model examples-of-gnatchop-usage}@anchor{5f}@anchor{gnat_ugn/the_gnat_compilation_model id27}@anchor{60}
@subsubsection Examples of @code{gnatchop} Usage
the same unit.
@node Configuration Pragmas,Generating Object Files,File Naming Topics and Utilities,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model configuration-pragmas}@anchor{25}@anchor{gnat_ugn/the_gnat_compilation_model id28}@anchor{60}
+@anchor{gnat_ugn/the_gnat_compilation_model configuration-pragmas}@anchor{26}@anchor{gnat_ugn/the_gnat_compilation_model id28}@anchor{61}
@section Configuration Pragmas
@end menu
@node Handling of Configuration Pragmas,The Configuration Pragmas Files,,Configuration Pragmas
-@anchor{gnat_ugn/the_gnat_compilation_model handling-of-configuration-pragmas}@anchor{3f}@anchor{gnat_ugn/the_gnat_compilation_model id29}@anchor{61}
+@anchor{gnat_ugn/the_gnat_compilation_model handling-of-configuration-pragmas}@anchor{40}@anchor{gnat_ugn/the_gnat_compilation_model id29}@anchor{62}
@subsection Handling of Configuration Pragmas
GNAT includes the @code{gnatchop} utility to provide an automatic
way to handle configuration pragmas that follows the semantics for
compilations (that is, files with multiple units) described in the RM.
-See @ref{59,,Operating gnatchop in Compilation Mode} for details.
+See @ref{5a,,Operating gnatchop in Compilation Mode} for details.
However, for most purposes, you will find it more convenient to edit the
@code{gnat.adc} file that contains configuration pragmas directly,
as described in the following section.
you have previously placed it in the body of spec.
@node The Configuration Pragmas Files,,Handling of Configuration Pragmas,Configuration Pragmas
-@anchor{gnat_ugn/the_gnat_compilation_model id30}@anchor{62}@anchor{gnat_ugn/the_gnat_compilation_model the-configuration-pragmas-files}@anchor{63}
+@anchor{gnat_ugn/the_gnat_compilation_model id30}@anchor{63}@anchor{gnat_ugn/the_gnat_compilation_model the-configuration-pragmas-files}@anchor{64}
@subsection The Configuration Pragmas Files
@c See :ref:`Specifying_Configuration_Pragmas` for more details.
@node Generating Object Files,Source Dependencies,Configuration Pragmas,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model generating-object-files}@anchor{26}@anchor{gnat_ugn/the_gnat_compilation_model id31}@anchor{64}
+@anchor{gnat_ugn/the_gnat_compilation_model generating-object-files}@anchor{27}@anchor{gnat_ugn/the_gnat_compilation_model id31}@anchor{65}
@section Generating Object Files
checking mode, use the @code{-gnatc} switch.
@node Source Dependencies,The Ada Library Information Files,Generating Object Files,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model id32}@anchor{65}@anchor{gnat_ugn/the_gnat_compilation_model source-dependencies}@anchor{27}
+@anchor{gnat_ugn/the_gnat_compilation_model id32}@anchor{66}@anchor{gnat_ugn/the_gnat_compilation_model source-dependencies}@anchor{28}
@section Source Dependencies
@end itemize
@node The Ada Library Information Files,Binding an Ada Program,Source Dependencies,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model id33}@anchor{66}@anchor{gnat_ugn/the_gnat_compilation_model the-ada-library-information-files}@anchor{28}
+@anchor{gnat_ugn/the_gnat_compilation_model id33}@anchor{67}@anchor{gnat_ugn/the_gnat_compilation_model the-ada-library-information-files}@anchor{29}
@section The Ada Library Information Files
@code{lib-writ.adb} in the GNAT compiler sources.
@node Binding an Ada Program,GNAT and Libraries,The Ada Library Information Files,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model binding-an-ada-program}@anchor{29}@anchor{gnat_ugn/the_gnat_compilation_model id34}@anchor{67}
+@anchor{gnat_ugn/the_gnat_compilation_model binding-an-ada-program}@anchor{2a}@anchor{gnat_ugn/the_gnat_compilation_model id34}@anchor{68}
@section Binding an Ada Program
object files for the Ada units of the program.
@node GNAT and Libraries,Conditional Compilation,Binding an Ada Program,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model gnat-and-libraries}@anchor{2a}@anchor{gnat_ugn/the_gnat_compilation_model id35}@anchor{68}
+@anchor{gnat_ugn/the_gnat_compilation_model gnat-and-libraries}@anchor{2b}@anchor{gnat_ugn/the_gnat_compilation_model id35}@anchor{69}
@section GNAT and Libraries
@end menu
@node Introduction to Libraries in GNAT,General Ada Libraries,,GNAT and Libraries
-@anchor{gnat_ugn/the_gnat_compilation_model id36}@anchor{69}@anchor{gnat_ugn/the_gnat_compilation_model introduction-to-libraries-in-gnat}@anchor{6a}
+@anchor{gnat_ugn/the_gnat_compilation_model id36}@anchor{6a}@anchor{gnat_ugn/the_gnat_compilation_model introduction-to-libraries-in-gnat}@anchor{6b}
@subsection Introduction to Libraries in GNAT
Source files,
@item
-@code{ALI} files (see @ref{28,,The Ada Library Information Files}), and
+@code{ALI} files (see @ref{29,,The Ada Library Information Files}), and
@item
Object files, an archive, or a shared library.
reflecting the library services along with all the units needed to compile
those specs, which can include generic bodies or any body implementing an
inlined routine. In the case of `stand-alone libraries' those exposed
-units are called `interface units' (@ref{6b,,Stand-alone Ada Libraries}).
+units are called `interface units' (@ref{6c,,Stand-alone Ada Libraries}).
All compilation units comprising an application, including those in a library,
need to be elaborated in an order partially defined by Ada’s semantics. GNAT
using the library.
@node General Ada Libraries,Stand-alone Ada Libraries,Introduction to Libraries in GNAT,GNAT and Libraries
-@anchor{gnat_ugn/the_gnat_compilation_model general-ada-libraries}@anchor{6c}@anchor{gnat_ugn/the_gnat_compilation_model id37}@anchor{6d}
+@anchor{gnat_ugn/the_gnat_compilation_model general-ada-libraries}@anchor{6d}@anchor{gnat_ugn/the_gnat_compilation_model id37}@anchor{6e}
@subsection General Ada Libraries
@end menu
@node Building a library,Installing a library,,General Ada Libraries
-@anchor{gnat_ugn/the_gnat_compilation_model building-a-library}@anchor{6e}@anchor{gnat_ugn/the_gnat_compilation_model id38}@anchor{6f}
+@anchor{gnat_ugn/the_gnat_compilation_model building-a-library}@anchor{6f}@anchor{gnat_ugn/the_gnat_compilation_model id38}@anchor{70}
@subsubsection Building a library
There are various possibilities for compiling the units that make up
the library: for example with a @code{Makefile}
-(@ref{70,,Using the GNU make Utility}) or with a conventional script. For
+(@ref{71,,Using the GNU make Utility}) or with a conventional script. For
simple libraries, you can also create a dummy main program
that depends upon all the packages that comprise the interface of the
library. You can then pass this dummy main program to @code{gnatmake},
be accessed by the @code{-l`xxx'} switch at link time.
@node Installing a library,Using a library,Building a library,General Ada Libraries
-@anchor{gnat_ugn/the_gnat_compilation_model id39}@anchor{71}@anchor{gnat_ugn/the_gnat_compilation_model installing-a-library}@anchor{72}
+@anchor{gnat_ugn/the_gnat_compilation_model id39}@anchor{72}@anchor{gnat_ugn/the_gnat_compilation_model installing-a-library}@anchor{73}
@subsubsection Installing a library
When you’re not able to use project files for some reason, you can
also install the library so that the sources needed to use the library
are on the Ada source path and the ALI files & libraries be on the Ada
-Object path (see @ref{73,,Search Paths and the Run-Time Library (RTL)}),
+Object path (see @ref{74,,Search Paths and the Run-Time Library (RTL)}),
but we don’t recommend doing this. Alternatively, the system
administrator can place general-purpose libraries in the default
compiler paths, by specifying the libraries’ location in the
redefines any part of it.
@node Using a library,,Installing a library,General Ada Libraries
-@anchor{gnat_ugn/the_gnat_compilation_model id40}@anchor{74}@anchor{gnat_ugn/the_gnat_compilation_model using-a-library}@anchor{75}
+@anchor{gnat_ugn/the_gnat_compilation_model id40}@anchor{75}@anchor{gnat_ugn/the_gnat_compilation_model using-a-library}@anchor{76}
@subsubsection Using a library
In order to use an Ada library manually, you need to make sure that this
library is on both your source and object path
-(see @ref{73,,Search Paths and the Run-Time Library (RTL)}
-and @ref{76,,Search Paths for gnatbind}). Furthermore, when the objects are grouped
+(see @ref{74,,Search Paths and the Run-Time Library (RTL)}
+and @ref{77,,Search Paths for gnatbind}). Furthermore, when the objects are grouped
in an archive or a shared library, you need to specify the desired
library at link time.
install area.
@node Stand-alone Ada Libraries,Rebuilding the GNAT Run-Time Library,General Ada Libraries,GNAT and Libraries
-@anchor{gnat_ugn/the_gnat_compilation_model id41}@anchor{77}@anchor{gnat_ugn/the_gnat_compilation_model stand-alone-ada-libraries}@anchor{6b}
+@anchor{gnat_ugn/the_gnat_compilation_model id41}@anchor{78}@anchor{gnat_ugn/the_gnat_compilation_model stand-alone-ada-libraries}@anchor{6c}
@subsection Stand-alone Ada Libraries
@end menu
@node Introduction to Stand-alone Libraries,Building a Stand-alone Library,,Stand-alone Ada Libraries
-@anchor{gnat_ugn/the_gnat_compilation_model id42}@anchor{78}@anchor{gnat_ugn/the_gnat_compilation_model introduction-to-stand-alone-libraries}@anchor{79}
+@anchor{gnat_ugn/the_gnat_compilation_model id42}@anchor{79}@anchor{gnat_ugn/the_gnat_compilation_model introduction-to-stand-alone-libraries}@anchor{7a}
@subsubsection Introduction to Stand-alone Libraries
main routine is not written in Ada.
@node Building a Stand-alone Library,Creating a Stand-alone Library to be used in a non-Ada context,Introduction to Stand-alone Libraries,Stand-alone Ada Libraries
-@anchor{gnat_ugn/the_gnat_compilation_model building-a-stand-alone-library}@anchor{7a}@anchor{gnat_ugn/the_gnat_compilation_model id43}@anchor{7b}
+@anchor{gnat_ugn/the_gnat_compilation_model building-a-stand-alone-library}@anchor{7b}@anchor{gnat_ugn/the_gnat_compilation_model id43}@anchor{7c}
@subsubsection Building a Stand-alone Library
@end itemize
Using SALs is not different from using other libraries
-(see @ref{75,,Using a library}).
+(see @ref{76,,Using a library}).
@node Creating a Stand-alone Library to be used in a non-Ada context,Restrictions in Stand-alone Libraries,Building a Stand-alone Library,Stand-alone Ada Libraries
-@anchor{gnat_ugn/the_gnat_compilation_model creating-a-stand-alone-library-to-be-used-in-a-non-ada-context}@anchor{7c}@anchor{gnat_ugn/the_gnat_compilation_model id44}@anchor{7d}
+@anchor{gnat_ugn/the_gnat_compilation_model creating-a-stand-alone-library-to-be-used-in-a-non-ada-context}@anchor{7d}@anchor{gnat_ugn/the_gnat_compilation_model id44}@anchor{7e}
@subsubsection Creating a Stand-alone Library to be used in a non-Ada context
after the finalization phase.
Information on limitations of binding Ada code in non-Ada contexts can be
-found under @ref{7e,,Binding with Non-Ada Main Programs}.
+found under @ref{7f,,Binding with Non-Ada Main Programs}.
Note also that you must take special care with multi-tasking
applications. In that case, the initialization and finalization
critical-section.
@node Restrictions in Stand-alone Libraries,,Creating a Stand-alone Library to be used in a non-Ada context,Stand-alone Ada Libraries
-@anchor{gnat_ugn/the_gnat_compilation_model id45}@anchor{7f}@anchor{gnat_ugn/the_gnat_compilation_model restrictions-in-stand-alone-libraries}@anchor{80}
+@anchor{gnat_ugn/the_gnat_compilation_model id45}@anchor{80}@anchor{gnat_ugn/the_gnat_compilation_model restrictions-in-stand-alone-libraries}@anchor{81}
@subsubsection Restrictions in Stand-alone Libraries
to be a consideration.
@node Rebuilding the GNAT Run-Time Library,,Stand-alone Ada Libraries,GNAT and Libraries
-@anchor{gnat_ugn/the_gnat_compilation_model id46}@anchor{81}@anchor{gnat_ugn/the_gnat_compilation_model rebuilding-the-gnat-run-time-library}@anchor{82}
+@anchor{gnat_ugn/the_gnat_compilation_model id46}@anchor{82}@anchor{gnat_ugn/the_gnat_compilation_model rebuilding-the-gnat-run-time-library}@anchor{83}
@subsection Rebuilding the GNAT Run-Time Library
@geindex Conditional compilation
@node Conditional Compilation,Mixed Language Programming,GNAT and Libraries,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model conditional-compilation}@anchor{2b}@anchor{gnat_ugn/the_gnat_compilation_model id47}@anchor{83}
+@anchor{gnat_ugn/the_gnat_compilation_model conditional-compilation}@anchor{2c}@anchor{gnat_ugn/the_gnat_compilation_model id47}@anchor{84}
@section Conditional Compilation
@end menu
@node Modeling Conditional Compilation in Ada,Preprocessing with gnatprep,,Conditional Compilation
-@anchor{gnat_ugn/the_gnat_compilation_model id48}@anchor{84}@anchor{gnat_ugn/the_gnat_compilation_model modeling-conditional-compilation-in-ada}@anchor{85}
+@anchor{gnat_ugn/the_gnat_compilation_model id48}@anchor{85}@anchor{gnat_ugn/the_gnat_compilation_model modeling-conditional-compilation-in-ada}@anchor{86}
@subsection Modeling Conditional Compilation in Ada
@end menu
@node Use of Boolean Constants,Debugging - A Special Case,,Modeling Conditional Compilation in Ada
-@anchor{gnat_ugn/the_gnat_compilation_model id49}@anchor{86}@anchor{gnat_ugn/the_gnat_compilation_model use-of-boolean-constants}@anchor{87}
+@anchor{gnat_ugn/the_gnat_compilation_model id49}@anchor{87}@anchor{gnat_ugn/the_gnat_compilation_model use-of-boolean-constants}@anchor{88}
@subsubsection Use of Boolean Constants
of @code{Config} to make the constants visible.
@node Debugging - A Special Case,Conditionalizing Declarations,Use of Boolean Constants,Modeling Conditional Compilation in Ada
-@anchor{gnat_ugn/the_gnat_compilation_model debugging-a-special-case}@anchor{88}@anchor{gnat_ugn/the_gnat_compilation_model id50}@anchor{89}
+@anchor{gnat_ugn/the_gnat_compilation_model debugging-a-special-case}@anchor{89}@anchor{gnat_ugn/the_gnat_compilation_model id50}@anchor{8a}
@subsubsection Debugging - A Special Case
@end example
@node Conditionalizing Declarations,Use of Alternative Implementations,Debugging - A Special Case,Modeling Conditional Compilation in Ada
-@anchor{gnat_ugn/the_gnat_compilation_model conditionalizing-declarations}@anchor{8a}@anchor{gnat_ugn/the_gnat_compilation_model id51}@anchor{8b}
+@anchor{gnat_ugn/the_gnat_compilation_model conditionalizing-declarations}@anchor{8b}@anchor{gnat_ugn/the_gnat_compilation_model id51}@anchor{8c}
@subsubsection Conditionalizing Declarations
need to define this one yourself).
@node Use of Alternative Implementations,Preprocessing,Conditionalizing Declarations,Modeling Conditional Compilation in Ada
-@anchor{gnat_ugn/the_gnat_compilation_model id52}@anchor{8c}@anchor{gnat_ugn/the_gnat_compilation_model use-of-alternative-implementations}@anchor{8d}
+@anchor{gnat_ugn/the_gnat_compilation_model id52}@anchor{8d}@anchor{gnat_ugn/the_gnat_compilation_model use-of-alternative-implementations}@anchor{8e}
@subsubsection Use of Alternative Implementations
dispatching calls.
@node Preprocessing,,Use of Alternative Implementations,Modeling Conditional Compilation in Ada
-@anchor{gnat_ugn/the_gnat_compilation_model id53}@anchor{8e}@anchor{gnat_ugn/the_gnat_compilation_model preprocessing}@anchor{8f}
+@anchor{gnat_ugn/the_gnat_compilation_model id53}@anchor{8f}@anchor{gnat_ugn/the_gnat_compilation_model preprocessing}@anchor{90}
@subsubsection Preprocessing
separately from the compiler to generate a separate output source file,
which you then feed to the compiler as a separate step. This is the
@code{gnatprep} utility, whose use is fully described in
-@ref{90,,Preprocessing with gnatprep}.
+@ref{91,,Preprocessing with gnatprep}.
The preprocessing language allows such constructs as
the compilation process. You pass the compiler the preprocessor input, which
includes @code{#if} lines etc, and the compiler carries out the
preprocessing internally and compiles the resulting output.
-For more details on this approach, see @ref{91,,Integrated Preprocessing}.
+For more details on this approach, see @ref{92,,Integrated Preprocessing}.
@node Preprocessing with gnatprep,Integrated Preprocessing,Modeling Conditional Compilation in Ada,Conditional Compilation
-@anchor{gnat_ugn/the_gnat_compilation_model id54}@anchor{92}@anchor{gnat_ugn/the_gnat_compilation_model preprocessing-with-gnatprep}@anchor{90}
+@anchor{gnat_ugn/the_gnat_compilation_model id54}@anchor{93}@anchor{gnat_ugn/the_gnat_compilation_model preprocessing-with-gnatprep}@anchor{91}
@subsection Preprocessing with @code{gnatprep}
for simple preprocessing. Although designed for use with GNAT,
@code{gnatprep} does not depend on any special GNAT features. For
further discussion of conditional compilation in general, see
-@ref{2b,,Conditional Compilation}.
+@ref{2c,,Conditional Compilation}.
@menu
* Preprocessing Symbols::
@end menu
@node Preprocessing Symbols,Using gnatprep,,Preprocessing with gnatprep
-@anchor{gnat_ugn/the_gnat_compilation_model id55}@anchor{93}@anchor{gnat_ugn/the_gnat_compilation_model preprocessing-symbols}@anchor{94}
+@anchor{gnat_ugn/the_gnat_compilation_model id55}@anchor{94}@anchor{gnat_ugn/the_gnat_compilation_model preprocessing-symbols}@anchor{95}
@subsubsection Preprocessing Symbols
all characters need to be in the ASCII set (no accented letters).
@node Using gnatprep,Switches for gnatprep,Preprocessing Symbols,Preprocessing with gnatprep
-@anchor{gnat_ugn/the_gnat_compilation_model id56}@anchor{95}@anchor{gnat_ugn/the_gnat_compilation_model using-gnatprep}@anchor{96}
+@anchor{gnat_ugn/the_gnat_compilation_model id56}@anchor{96}@anchor{gnat_ugn/the_gnat_compilation_model using-gnatprep}@anchor{97}
@subsubsection Using @code{gnatprep}
@end itemize
@node Switches for gnatprep,Form of Definitions File,Using gnatprep,Preprocessing with gnatprep
-@anchor{gnat_ugn/the_gnat_compilation_model id57}@anchor{97}@anchor{gnat_ugn/the_gnat_compilation_model switches-for-gnatprep}@anchor{98}
+@anchor{gnat_ugn/the_gnat_compilation_model id57}@anchor{98}@anchor{gnat_ugn/the_gnat_compilation_model switches-for-gnatprep}@anchor{99}
@subsubsection Switches for @code{gnatprep}
@code{-r}, in which case @code{gnatprep} enables the @code{-b} switch.
@node Form of Definitions File,Form of Input Text for gnatprep,Switches for gnatprep,Preprocessing with gnatprep
-@anchor{gnat_ugn/the_gnat_compilation_model form-of-definitions-file}@anchor{99}@anchor{gnat_ugn/the_gnat_compilation_model id58}@anchor{9a}
+@anchor{gnat_ugn/the_gnat_compilation_model form-of-definitions-file}@anchor{9a}@anchor{gnat_ugn/the_gnat_compilation_model id58}@anchor{9b}
@subsubsection Form of Definitions File
and comments may be added to the end of each definition line.
@node Form of Input Text for gnatprep,,Form of Definitions File,Preprocessing with gnatprep
-@anchor{gnat_ugn/the_gnat_compilation_model form-of-input-text-for-gnatprep}@anchor{9b}@anchor{gnat_ugn/the_gnat_compilation_model id59}@anchor{9c}
+@anchor{gnat_ugn/the_gnat_compilation_model form-of-input-text-for-gnatprep}@anchor{9c}@anchor{gnat_ugn/the_gnat_compilation_model id59}@anchor{9d}
@subsubsection Form of Input Text for @code{gnatprep}
and then the substitution will occur as desired.
@node Integrated Preprocessing,,Preprocessing with gnatprep,Conditional Compilation
-@anchor{gnat_ugn/the_gnat_compilation_model id60}@anchor{9d}@anchor{gnat_ugn/the_gnat_compilation_model integrated-preprocessing}@anchor{91}
+@anchor{gnat_ugn/the_gnat_compilation_model id60}@anchor{9e}@anchor{gnat_ugn/the_gnat_compilation_model integrated-preprocessing}@anchor{92}
@subsection Integrated Preprocessing
preprocessing.
The actual preprocessing function is described in detail in
-@ref{90,,Preprocessing with gnatprep}. This section explains the switches
+@ref{91,,Preprocessing with gnatprep}. This section explains the switches
that relate to integrated preprocessing.
@geindex -gnatep (gcc)
After the file name or ‘*’, you can place an optional literal string
to specify the name of the definition file to be used for
-preprocessing (@ref{99,,Form of Definitions File}). The definition
+preprocessing (@ref{9a,,Form of Definitions File}). The definition
files are found by the compiler in one of the source directories. In
some cases, when compiling a source in a directory other than the
current directory, if the definition file is in the current
@end table
@node Mixed Language Programming,GNAT and Other Compilation Models,Conditional Compilation,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model id61}@anchor{9e}@anchor{gnat_ugn/the_gnat_compilation_model mixed-language-programming}@anchor{2c}
+@anchor{gnat_ugn/the_gnat_compilation_model id61}@anchor{9f}@anchor{gnat_ugn/the_gnat_compilation_model mixed-language-programming}@anchor{2d}
@section Mixed Language Programming
@end menu
@node Interfacing to C,Calling Conventions,,Mixed Language Programming
-@anchor{gnat_ugn/the_gnat_compilation_model id62}@anchor{9f}@anchor{gnat_ugn/the_gnat_compilation_model interfacing-to-c}@anchor{a0}
+@anchor{gnat_ugn/the_gnat_compilation_model id62}@anchor{a0}@anchor{gnat_ugn/the_gnat_compilation_model interfacing-to-c}@anchor{a1}
@subsection Interfacing to C
If the main program is in a language other than Ada, you may have more
than one entry point into the Ada subsystem. You must use a special
binder option to generate callable routines that initialize and
-finalize the Ada units (@ref{7e,,Binding with Non-Ada Main Programs}).
+finalize the Ada units (@ref{7f,,Binding with Non-Ada Main Programs}).
You must insert calls to the initialization and finalization routines
in the main program or some other appropriate point in the code. You
must place the call to initialize the Ada units so that it occurs
@code{-nostartfiles} switch to @code{gnatlink}.
@node Calling Conventions,Building Mixed Ada and C++ Programs,Interfacing to C,Mixed Language Programming
-@anchor{gnat_ugn/the_gnat_compilation_model calling-conventions}@anchor{a1}@anchor{gnat_ugn/the_gnat_compilation_model id63}@anchor{a2}
+@anchor{gnat_ugn/the_gnat_compilation_model calling-conventions}@anchor{a2}@anchor{gnat_ugn/the_gnat_compilation_model id63}@anchor{a3}
@subsection Calling Conventions
@item
General subprogram entities. This is used to bind an Ada subprogram
declaration to
-a compiler builtin by name with back-ends where such interfaces are
+a compiler builtin by name with back ends where such interfaces are
available. A typical example is the set of @code{__builtin} functions
-exposed by the @code{gcc} back-end, as in the following example:
+exposed by the @code{gcc} back end, as in the following example:
@example
function builtin_sqrt (F : Float) return Float;
meaning as @code{Fortran}.
@node Building Mixed Ada and C++ Programs,Partition-Wide Settings,Calling Conventions,Mixed Language Programming
-@anchor{gnat_ugn/the_gnat_compilation_model building-mixed-ada-and-c-programs}@anchor{a3}@anchor{gnat_ugn/the_gnat_compilation_model id64}@anchor{a4}
+@anchor{gnat_ugn/the_gnat_compilation_model building-mixed-ada-and-c-programs}@anchor{a4}@anchor{gnat_ugn/the_gnat_compilation_model id64}@anchor{a5}
@subsection Building Mixed Ada and C++ Programs
@end menu
@node Interfacing to C++,Linking a Mixed C++ & Ada Program,,Building Mixed Ada and C++ Programs
-@anchor{gnat_ugn/the_gnat_compilation_model id65}@anchor{a5}@anchor{gnat_ugn/the_gnat_compilation_model id66}@anchor{a6}
+@anchor{gnat_ugn/the_gnat_compilation_model id65}@anchor{a6}@anchor{gnat_ugn/the_gnat_compilation_model id66}@anchor{a7}
@subsubsection Interfacing to C++
classes. In the first two cases, GNAT offers a specific @code{Convention C_Plus_Plus}
(or @code{CPP}) that behaves exactly like @code{Convention C}.
Usually, C++ mangles the names of subprograms. To generate proper mangled
-names automatically, see @ref{a7,,Generating Ada Bindings for C and C++ headers}).
+names automatically, see @ref{a8,,Generating Ada Bindings for C and C++ headers}).
You can also address this problem addressed manually in two ways:
pragmas such as @code{CPP_Constructor}. See the @cite{GNAT_Reference_Manual} for additional information.
@node Linking a Mixed C++ & Ada Program,A Simple Example,Interfacing to C++,Building Mixed Ada and C++ Programs
-@anchor{gnat_ugn/the_gnat_compilation_model linking-a-mixed-c-ada-program}@anchor{a8}@anchor{gnat_ugn/the_gnat_compilation_model linking-a-mixed-c-and-ada-program}@anchor{a9}
+@anchor{gnat_ugn/the_gnat_compilation_model linking-a-mixed-c-ada-program}@anchor{a9}@anchor{gnat_ugn/the_gnat_compilation_model linking-a-mixed-c-and-ada-program}@anchor{aa}
@subsubsection Linking a Mixed C++ & Ada Program
together automatically in most cases.
@node A Simple Example,Interfacing with C++ constructors,Linking a Mixed C++ & Ada Program,Building Mixed Ada and C++ Programs
-@anchor{gnat_ugn/the_gnat_compilation_model a-simple-example}@anchor{aa}@anchor{gnat_ugn/the_gnat_compilation_model id67}@anchor{ab}
+@anchor{gnat_ugn/the_gnat_compilation_model a-simple-example}@anchor{ab}@anchor{gnat_ugn/the_gnat_compilation_model id67}@anchor{ac}
@subsubsection A Simple Example
@end example
@node Interfacing with C++ constructors,Interfacing with C++ at the Class Level,A Simple Example,Building Mixed Ada and C++ Programs
-@anchor{gnat_ugn/the_gnat_compilation_model id68}@anchor{ac}@anchor{gnat_ugn/the_gnat_compilation_model interfacing-with-c-constructors}@anchor{ad}
+@anchor{gnat_ugn/the_gnat_compilation_model id68}@anchor{ad}@anchor{gnat_ugn/the_gnat_compilation_model interfacing-with-c-constructors}@anchor{ae}
@subsubsection Interfacing with C++ constructors
For this purpose, we can write the following package spec (further
information on how to build this spec is available in
-@ref{ae,,Interfacing with C++ at the Class Level} and
-@ref{a7,,Generating Ada Bindings for C and C++ headers}).
+@ref{af,,Interfacing with C++ at the Class Level} and
+@ref{a8,,Generating Ada Bindings for C and C++ headers}).
@example
with Interfaces.C; use Interfaces.C;
associated with the constructor inside the construct.
@node Interfacing with C++ at the Class Level,,Interfacing with C++ constructors,Building Mixed Ada and C++ Programs
-@anchor{gnat_ugn/the_gnat_compilation_model id69}@anchor{af}@anchor{gnat_ugn/the_gnat_compilation_model interfacing-with-c-at-the-class-level}@anchor{ae}
+@anchor{gnat_ugn/the_gnat_compilation_model id69}@anchor{b0}@anchor{gnat_ugn/the_gnat_compilation_model interfacing-with-c-at-the-class-level}@anchor{af}
@subsubsection Interfacing with C++ at the Class Level
@end example
@node Partition-Wide Settings,Generating Ada Bindings for C and C++ headers,Building Mixed Ada and C++ Programs,Mixed Language Programming
-@anchor{gnat_ugn/the_gnat_compilation_model id70}@anchor{b0}@anchor{gnat_ugn/the_gnat_compilation_model partition-wide-settings}@anchor{b1}
+@anchor{gnat_ugn/the_gnat_compilation_model id70}@anchor{b1}@anchor{gnat_ugn/the_gnat_compilation_model partition-wide-settings}@anchor{b2}
@subsection Partition-Wide Settings
while @code{SIGABRT} is used to asynchronously abort an action or a task.
@node Generating Ada Bindings for C and C++ headers,Generating C Headers for Ada Specifications,Partition-Wide Settings,Mixed Language Programming
-@anchor{gnat_ugn/the_gnat_compilation_model generating-ada-bindings-for-c-and-c-headers}@anchor{a7}@anchor{gnat_ugn/the_gnat_compilation_model id71}@anchor{b2}
+@anchor{gnat_ugn/the_gnat_compilation_model generating-ada-bindings-for-c-and-c-headers}@anchor{a8}@anchor{gnat_ugn/the_gnat_compilation_model id71}@anchor{b3}
@subsection Generating Ada Bindings for C and C++ headers
@end menu
@node Running the Binding Generator,Generating Bindings for C++ Headers,,Generating Ada Bindings for C and C++ headers
-@anchor{gnat_ugn/the_gnat_compilation_model id72}@anchor{b3}@anchor{gnat_ugn/the_gnat_compilation_model running-the-binding-generator}@anchor{b4}
+@anchor{gnat_ugn/the_gnat_compilation_model id72}@anchor{b4}@anchor{gnat_ugn/the_gnat_compilation_model running-the-binding-generator}@anchor{b5}
@subsubsection Running the Binding Generator
@end example
@node Generating Bindings for C++ Headers,Switches,Running the Binding Generator,Generating Ada Bindings for C and C++ headers
-@anchor{gnat_ugn/the_gnat_compilation_model generating-bindings-for-c-headers}@anchor{b5}@anchor{gnat_ugn/the_gnat_compilation_model id73}@anchor{b6}
+@anchor{gnat_ugn/the_gnat_compilation_model generating-bindings-for-c-headers}@anchor{b6}@anchor{gnat_ugn/the_gnat_compilation_model id73}@anchor{b7}
@subsubsection Generating Bindings for C++ Headers
@end example
@node Switches,,Generating Bindings for C++ Headers,Generating Ada Bindings for C and C++ headers
-@anchor{gnat_ugn/the_gnat_compilation_model switches}@anchor{b7}@anchor{gnat_ugn/the_gnat_compilation_model switches-for-ada-binding-generation}@anchor{b8}
+@anchor{gnat_ugn/the_gnat_compilation_model switches}@anchor{b8}@anchor{gnat_ugn/the_gnat_compilation_model switches-for-ada-binding-generation}@anchor{b9}
@subsubsection Switches
@end table
@node Generating C Headers for Ada Specifications,,Generating Ada Bindings for C and C++ headers,Mixed Language Programming
-@anchor{gnat_ugn/the_gnat_compilation_model generating-c-headers-for-ada-specifications}@anchor{b9}@anchor{gnat_ugn/the_gnat_compilation_model id74}@anchor{ba}
+@anchor{gnat_ugn/the_gnat_compilation_model generating-c-headers-for-ada-specifications}@anchor{ba}@anchor{gnat_ugn/the_gnat_compilation_model id74}@anchor{bb}
@subsection Generating C Headers for Ada Specifications
@end menu
@node Running the C Header Generator,,,Generating C Headers for Ada Specifications
-@anchor{gnat_ugn/the_gnat_compilation_model running-the-c-header-generator}@anchor{bb}
+@anchor{gnat_ugn/the_gnat_compilation_model running-the-c-header-generator}@anchor{bc}
@subsubsection Running the C Header Generator
call subprograms, reference objects, and constants.
@node GNAT and Other Compilation Models,Using GNAT Files with External Tools,Mixed Language Programming,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model gnat-and-other-compilation-models}@anchor{2d}@anchor{gnat_ugn/the_gnat_compilation_model id75}@anchor{bc}
+@anchor{gnat_ugn/the_gnat_compilation_model gnat-and-other-compilation-models}@anchor{2e}@anchor{gnat_ugn/the_gnat_compilation_model id75}@anchor{bd}
@section GNAT and Other Compilation Models
@end menu
@node Comparison between GNAT and C/C++ Compilation Models,Comparison between GNAT and Conventional Ada Library Models,,GNAT and Other Compilation Models
-@anchor{gnat_ugn/the_gnat_compilation_model comparison-between-gnat-and-c-c-compilation-models}@anchor{bd}@anchor{gnat_ugn/the_gnat_compilation_model id76}@anchor{be}
+@anchor{gnat_ugn/the_gnat_compilation_model comparison-between-gnat-and-c-c-compilation-models}@anchor{be}@anchor{gnat_ugn/the_gnat_compilation_model id76}@anchor{bf}
@subsection Comparison between GNAT and C/C++ Compilation Models
malfunctioned at run time.
@node Comparison between GNAT and Conventional Ada Library Models,,Comparison between GNAT and C/C++ Compilation Models,GNAT and Other Compilation Models
-@anchor{gnat_ugn/the_gnat_compilation_model comparison-between-gnat-and-conventional-ada-library-models}@anchor{bf}@anchor{gnat_ugn/the_gnat_compilation_model id77}@anchor{c0}
+@anchor{gnat_ugn/the_gnat_compilation_model comparison-between-gnat-and-conventional-ada-library-models}@anchor{c0}@anchor{gnat_ugn/the_gnat_compilation_model id77}@anchor{c1}
@subsection Comparison between GNAT and Conventional Ada Library Models
compiled.
@node Using GNAT Files with External Tools,,GNAT and Other Compilation Models,The GNAT Compilation Model
-@anchor{gnat_ugn/the_gnat_compilation_model id78}@anchor{c1}@anchor{gnat_ugn/the_gnat_compilation_model using-gnat-files-with-external-tools}@anchor{2e}
+@anchor{gnat_ugn/the_gnat_compilation_model id78}@anchor{c2}@anchor{gnat_ugn/the_gnat_compilation_model using-gnat-files-with-external-tools}@anchor{2f}
@section Using GNAT Files with External Tools
@end menu
@node Using Other Utility Programs with GNAT,The External Symbol Naming Scheme of GNAT,,Using GNAT Files with External Tools
-@anchor{gnat_ugn/the_gnat_compilation_model id79}@anchor{c2}@anchor{gnat_ugn/the_gnat_compilation_model using-other-utility-programs-with-gnat}@anchor{c3}
+@anchor{gnat_ugn/the_gnat_compilation_model id79}@anchor{c3}@anchor{gnat_ugn/the_gnat_compilation_model using-other-utility-programs-with-gnat}@anchor{c4}
@subsection Using Other Utility Programs with GNAT
as @code{Purify}.
@node The External Symbol Naming Scheme of GNAT,,Using Other Utility Programs with GNAT,Using GNAT Files with External Tools
-@anchor{gnat_ugn/the_gnat_compilation_model id80}@anchor{c4}@anchor{gnat_ugn/the_gnat_compilation_model the-external-symbol-naming-scheme-of-gnat}@anchor{c5}
+@anchor{gnat_ugn/the_gnat_compilation_model id80}@anchor{c5}@anchor{gnat_ugn/the_gnat_compilation_model the-external-symbol-naming-scheme-of-gnat}@anchor{c6}
@subsection The External Symbol Naming Scheme of GNAT
@c -- Example: A |withing| unit has a |with| clause, it |withs| a |withed| unit
@node Building Executable Programs with GNAT,GNAT Utility Programs,The GNAT Compilation Model,Top
-@anchor{gnat_ugn/building_executable_programs_with_gnat doc}@anchor{c6}@anchor{gnat_ugn/building_executable_programs_with_gnat building-executable-programs-with-gnat}@anchor{a}@anchor{gnat_ugn/building_executable_programs_with_gnat id1}@anchor{c7}
+@anchor{gnat_ugn/building_executable_programs_with_gnat doc}@anchor{c7}@anchor{gnat_ugn/building_executable_programs_with_gnat building-executable-programs-with-gnat}@anchor{b}@anchor{gnat_ugn/building_executable_programs_with_gnat id1}@anchor{c8}
@chapter Building Executable Programs with GNAT
This chapter describes first the gnatmake tool
-(@ref{c8,,Building with gnatmake}),
+(@ref{c9,,Building with gnatmake}),
which automatically determines the set of sources
needed by an Ada compilation unit and executes the necessary
(re)compilations, binding and linking.
It also explains how to use each tool individually: the
-compiler (gcc, see @ref{c9,,Compiling with gcc}),
-binder (gnatbind, see @ref{ca,,Binding with gnatbind}),
-and linker (gnatlink, see @ref{cb,,Linking with gnatlink})
+compiler (gcc, see @ref{ca,,Compiling with gcc}),
+binder (gnatbind, see @ref{cb,,Binding with gnatbind}),
+and linker (gnatlink, see @ref{cc,,Linking with gnatlink})
to build executable programs.
Finally, this chapter provides examples of
how to make use of the general GNU make mechanism
-in a GNAT context (see @ref{70,,Using the GNU make Utility}).
+in a GNAT context (see @ref{71,,Using the GNU make Utility}).
@menu
@end menu
@node Building with gnatmake,Compiling with gcc,,Building Executable Programs with GNAT
-@anchor{gnat_ugn/building_executable_programs_with_gnat building-with-gnatmake}@anchor{cc}@anchor{gnat_ugn/building_executable_programs_with_gnat the-gnat-make-program-gnatmake}@anchor{c8}
+@anchor{gnat_ugn/building_executable_programs_with_gnat building-with-gnatmake}@anchor{cd}@anchor{gnat_ugn/building_executable_programs_with_gnat the-gnat-make-program-gnatmake}@anchor{c9}
@section Building with @code{gnatmake}
@end menu
@node Running gnatmake,Switches for gnatmake,,Building with gnatmake
-@anchor{gnat_ugn/building_executable_programs_with_gnat id2}@anchor{cd}@anchor{gnat_ugn/building_executable_programs_with_gnat running-gnatmake}@anchor{ce}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id2}@anchor{ce}@anchor{gnat_ugn/building_executable_programs_with_gnat running-gnatmake}@anchor{cf}
@subsection Running @code{gnatmake}
source file will first be searched in the directory where
@code{gnatmake} was invoked and if it is not found, it will be search on
the source path of the compiler as described in
-@ref{73,,Search Paths and the Run-Time Library (RTL)}.
+@ref{74,,Search Paths and the Run-Time Library (RTL)}.
All @code{gnatmake} output (except when you specify @code{-M}) is sent to
@code{stderr}. The output produced by the
@code{-M} switch is sent to @code{stdout}.
@node Switches for gnatmake,Mode Switches for gnatmake,Running gnatmake,Building with gnatmake
-@anchor{gnat_ugn/building_executable_programs_with_gnat id3}@anchor{cf}@anchor{gnat_ugn/building_executable_programs_with_gnat switches-for-gnatmake}@anchor{d0}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id3}@anchor{d0}@anchor{gnat_ugn/building_executable_programs_with_gnat switches-for-gnatmake}@anchor{d1}
@subsection Switches for @code{gnatmake}
in place. This means that once a large project is organized into separate
directories in the desired manner, then @code{gnatmake} will automatically
maintain and update this organization. If no ALI files are found on the
-Ada object path (see @ref{73,,Search Paths and the Run-Time Library (RTL)}),
+Ada object path (see @ref{74,,Search Paths and the Run-Time Library (RTL)}),
the new object and ALI files are created in the
directory containing the source being compiled. If another organization
is desired, where objects and sources are kept in different directories,
@item @code{-vP`x'}
Indicate the verbosity of the parsing of GNAT project files.
-See @ref{d1,,Switches Related to Project Files}.
+See @ref{d2,,Switches Related to Project Files}.
@end table
@geindex -x (gnatmake)
Indicate that external variable @code{name} has the value @code{value}.
The Project Manager will use this value for occurrences of
@code{external(name)} when parsing the project file.
-@ref{d1,,Switches Related to Project Files}.
+@ref{d2,,Switches Related to Project Files}.
@end table
@geindex -z (gnatmake)
When looking for source files also look in directory @code{dir}.
The order in which source files search is undertaken is
-described in @ref{73,,Search Paths and the Run-Time Library (RTL)}.
+described in @ref{74,,Search Paths and the Run-Time Library (RTL)}.
@end table
@geindex -aL (gnatmake)
When searching for library and object files, look in directory
@code{dir}. The order in which library files are searched is described in
-@ref{76,,Search Paths for gnatbind}.
+@ref{77,,Search Paths for gnatbind}.
@end table
@geindex Search paths
@end table
@node Mode Switches for gnatmake,Notes on the Command Line,Switches for gnatmake,Building with gnatmake
-@anchor{gnat_ugn/building_executable_programs_with_gnat id4}@anchor{d2}@anchor{gnat_ugn/building_executable_programs_with_gnat mode-switches-for-gnatmake}@anchor{d3}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id4}@anchor{d3}@anchor{gnat_ugn/building_executable_programs_with_gnat mode-switches-for-gnatmake}@anchor{d4}
@subsection Mode Switches for @code{gnatmake}
@end table
@node Notes on the Command Line,How gnatmake Works,Mode Switches for gnatmake,Building with gnatmake
-@anchor{gnat_ugn/building_executable_programs_with_gnat id5}@anchor{d4}@anchor{gnat_ugn/building_executable_programs_with_gnat notes-on-the-command-line}@anchor{d5}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id5}@anchor{d5}@anchor{gnat_ugn/building_executable_programs_with_gnat notes-on-the-command-line}@anchor{d6}
@subsection Notes on the Command Line
@end itemize
@node How gnatmake Works,Examples of gnatmake Usage,Notes on the Command Line,Building with gnatmake
-@anchor{gnat_ugn/building_executable_programs_with_gnat how-gnatmake-works}@anchor{d6}@anchor{gnat_ugn/building_executable_programs_with_gnat id6}@anchor{d7}
+@anchor{gnat_ugn/building_executable_programs_with_gnat how-gnatmake-works}@anchor{d7}@anchor{gnat_ugn/building_executable_programs_with_gnat id6}@anchor{d8}
@subsection How @code{gnatmake} Works
imported by several of the executables, it will be recompiled at most once.
Note: when using non-standard naming conventions
-(@ref{1c,,Using Other File Names}), changing through a configuration pragmas
+(@ref{1d,,Using Other File Names}), changing through a configuration pragmas
file the version of a source and invoking @code{gnatmake} to recompile may
have no effect, if the previous version of the source is still accessible
by @code{gnatmake}. It may be necessary to use the switch
-f.
@node Examples of gnatmake Usage,,How gnatmake Works,Building with gnatmake
-@anchor{gnat_ugn/building_executable_programs_with_gnat examples-of-gnatmake-usage}@anchor{d8}@anchor{gnat_ugn/building_executable_programs_with_gnat id7}@anchor{d9}
+@anchor{gnat_ugn/building_executable_programs_with_gnat examples-of-gnatmake-usage}@anchor{d9}@anchor{gnat_ugn/building_executable_programs_with_gnat id7}@anchor{da}
@subsection Examples of @code{gnatmake} Usage
@end table
@node Compiling with gcc,Compiler Switches,Building with gnatmake,Building Executable Programs with GNAT
-@anchor{gnat_ugn/building_executable_programs_with_gnat compiling-with-gcc}@anchor{c9}@anchor{gnat_ugn/building_executable_programs_with_gnat id8}@anchor{da}
+@anchor{gnat_ugn/building_executable_programs_with_gnat compiling-with-gcc}@anchor{ca}@anchor{gnat_ugn/building_executable_programs_with_gnat id8}@anchor{db}
@section Compiling with @code{gcc}
@end menu
@node Compiling Programs,Search Paths and the Run-Time Library RTL,,Compiling with gcc
-@anchor{gnat_ugn/building_executable_programs_with_gnat compiling-programs}@anchor{db}@anchor{gnat_ugn/building_executable_programs_with_gnat id9}@anchor{dc}
+@anchor{gnat_ugn/building_executable_programs_with_gnat compiling-programs}@anchor{dc}@anchor{gnat_ugn/building_executable_programs_with_gnat id9}@anchor{dd}
@subsection Compiling Programs
The compiler generates two object files @code{x.o} and @code{y.o}
and the two ALI files @code{x.ali} and @code{y.ali}.
-Any switches apply to all the files listed, see @ref{dd,,Compiler Switches} for a
+Any switches apply to all the files listed, see @ref{de,,Compiler Switches} for a
list of available @code{gcc} switches.
@node Search Paths and the Run-Time Library RTL,Order of Compilation Issues,Compiling Programs,Compiling with gcc
-@anchor{gnat_ugn/building_executable_programs_with_gnat id10}@anchor{de}@anchor{gnat_ugn/building_executable_programs_with_gnat search-paths-and-the-run-time-library-rtl}@anchor{73}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id10}@anchor{df}@anchor{gnat_ugn/building_executable_programs_with_gnat search-paths-and-the-run-time-library-rtl}@anchor{74}
@subsection Search Paths and the Run-Time Library (RTL)
The content of the @code{ada_source_path} file which is part of the GNAT
installation tree and is used to store standard libraries such as the
GNAT Run Time Library (RTL) source files.
-See also @ref{72,,Installing a library}.
+See also @ref{73,,Installing a library}.
@end itemize
Specifying the switch @code{-I-}
development environments much more flexible.
@node Order of Compilation Issues,Examples,Search Paths and the Run-Time Library RTL,Compiling with gcc
-@anchor{gnat_ugn/building_executable_programs_with_gnat id11}@anchor{df}@anchor{gnat_ugn/building_executable_programs_with_gnat order-of-compilation-issues}@anchor{e0}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id11}@anchor{e0}@anchor{gnat_ugn/building_executable_programs_with_gnat order-of-compilation-issues}@anchor{e1}
@subsection Order of Compilation Issues
@item
There is no library as such, apart from the ALI files
-(@ref{28,,The Ada Library Information Files}, for information on the format
+(@ref{29,,The Ada Library Information Files}, for information on the format
of these files). For now we find it convenient to create separate ALI files,
but eventually the information therein may be incorporated into the object
file directly.
@end itemize
@node Examples,,Order of Compilation Issues,Compiling with gcc
-@anchor{gnat_ugn/building_executable_programs_with_gnat examples}@anchor{e1}@anchor{gnat_ugn/building_executable_programs_with_gnat id12}@anchor{e2}
+@anchor{gnat_ugn/building_executable_programs_with_gnat examples}@anchor{e2}@anchor{gnat_ugn/building_executable_programs_with_gnat id12}@anchor{e3}
@subsection Examples
mode.
@node Compiler Switches,Linker Switches,Compiling with gcc,Building Executable Programs with GNAT
-@anchor{gnat_ugn/building_executable_programs_with_gnat compiler-switches}@anchor{e3}@anchor{gnat_ugn/building_executable_programs_with_gnat switches-for-gcc}@anchor{dd}
+@anchor{gnat_ugn/building_executable_programs_with_gnat compiler-switches}@anchor{e4}@anchor{gnat_ugn/building_executable_programs_with_gnat switches-for-gcc}@anchor{de}
@section Compiler Switches
@end menu
@node Alphabetical List of All Switches,Output and Error Message Control,,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat alphabetical-list-of-all-switches}@anchor{e4}@anchor{gnat_ugn/building_executable_programs_with_gnat id13}@anchor{e5}
+@anchor{gnat_ugn/building_executable_programs_with_gnat alphabetical-list-of-all-switches}@anchor{e5}@anchor{gnat_ugn/building_executable_programs_with_gnat id13}@anchor{e6}
@subsection Alphabetical List of All Switches
Causes the compiler to avoid assumptions regarding non-aliasing
of objects of different types. See
-@ref{e6,,Optimization and Strict Aliasing} for details.
+@ref{e7,,Optimization and Strict Aliasing} for details.
@end table
@geindex -fno-strict-overflow (gcc)
@item @code{-fstack-check}
Activates stack checking.
-See @ref{e7,,Stack Overflow Checking} for details.
+See @ref{e8,,Stack Overflow Checking} for details.
@end table
@geindex -fstack-usage (gcc)
@item @code{-fstack-usage}
Makes the compiler output stack usage information for the program, on a
-per-subprogram basis. See @ref{e8,,Static Stack Usage Analysis} for details.
+per-subprogram basis. See @ref{e9,,Static Stack Usage Analysis} for details.
@end table
@geindex -g (gcc)
@item @code{-gnatB}
Assume no invalid (bad) values except for ‘Valid attribute use
-(@ref{e9,,Validity Checking}).
+(@ref{ea,,Validity Checking}).
@end table
@geindex -gnatc (gcc)
Specify a configuration pragma file
(the equal sign is optional)
-(@ref{63,,The Configuration Pragmas Files}).
+(@ref{64,,The Configuration Pragmas Files}).
@end table
@geindex -gnateC (gcc)
@item @code{-gnateDsymbol[=`value']}
Defines a symbol, associated with @code{value}, for preprocessing.
-(@ref{91,,Integrated Preprocessing}).
+(@ref{92,,Integrated Preprocessing}).
@end table
@geindex -gnateE (gcc)
The @code{-gnatc} switch must always be specified before this switch, e.g.
@code{-gnatceg}. Generate a C header from the Ada input file. See
-@ref{b9,,Generating C Headers for Ada Specifications} for more
+@ref{ba,,Generating C Headers for Ada Specifications} for more
information.
@end quotation
Specify a mapping file
(the equal sign is optional)
-(@ref{ea,,Units to Sources Mapping Files}).
+(@ref{eb,,Units to Sources Mapping Files}).
@end table
@geindex -gnatep (gcc)
Specify a preprocessing data file
(the equal sign is optional)
-(@ref{91,,Integrated Preprocessing}).
+(@ref{92,,Integrated Preprocessing}).
@end table
@geindex -gnateP (gcc)
@code{Maximum_Alignment} is the maximum alignment that the compiler can choose
by default for a type or object, which is also the maximum alignment that can
-be specified in GNAT. It is computed for GCC backends as @code{BIGGEST_ALIGNMENT
+be specified in GNAT. It is computed for GCC back ends as @code{BIGGEST_ALIGNMENT
/ BITS_PER_UNIT} where GCC macro @code{BIGGEST_ALIGNMENT} is documented as
follows: @cite{Biggest alignment that any data type can require on this machine@comma{} in bits.}
@item @code{-gnateV}
Check that all actual parameters of a subprogram call are valid according to
-the rules of validity checking (@ref{e9,,Validity Checking}).
+the rules of validity checking (@ref{ea,,Validity Checking}).
@end table
@geindex -gnateY (gcc)
@item @code{-gnatE}
Dynamic elaboration checking mode enabled. For further details see
-@ref{f,,Elaboration Order Handling in GNAT}.
+@ref{10,,Elaboration Order Handling in GNAT}.
@end table
@geindex -gnatf (gcc)
Legacy elaboration-checking mode enabled. When this switch is in effect,
the pre-18.x access-before-elaboration model becomes the de facto model.
-For further details see @ref{f,,Elaboration Order Handling in GNAT}.
+For further details see @ref{10,,Elaboration Order Handling in GNAT}.
@end table
@geindex -gnati (gcc)
Identifier character set (@code{c} = 1/2/3/4/5/9/p/8/f/n/w).
For details of the possible selections for @code{c},
-see @ref{31,,Character Set Control}.
+see @ref{32,,Character Set Control}.
@end table
@geindex -gnatI (gcc)
@end itemize
and does not emit compile-time diagnostics or run-time checks. For further
-details see @ref{f,,Elaboration Order Handling in GNAT}.
+details see @ref{10,,Elaboration Order Handling in GNAT}.
@end table
@geindex -gnatk (gcc)
@item @code{-gnatn[12]}
Activate inlining across units for subprograms for which pragma @code{Inline}
-is specified. This inlining is performed by the GCC back-end. An optional
+is specified. This inlining is performed by the GCC back end. An optional
digit sets the inlining level: 1 for moderate inlining across units
or 2 for full inlining across units. If no inlining level is specified,
the compiler will pick it based on the optimization level.
Note that division by zero is a separate check that is not
controlled by this switch (divide-by-zero checking is on by default).
-See also @ref{eb,,Specifying the Desired Mode}.
+See also @ref{ec,,Specifying the Desired Mode}.
@end table
@geindex -gnatp (gcc)
@item @code{-gnatp}
-Suppress all checks. See @ref{ec,,Run-Time Checks} for details. This switch
+Suppress all checks. See @ref{ed,,Run-Time Checks} for details. This switch
has no effect if cancelled by a subsequent @code{-gnat-p} switch.
@end table
@item @code{-gnatV}
-Control level of validity checking (@ref{e9,,Validity Checking}).
+Control level of validity checking (@ref{ea,,Validity Checking}).
@end table
@geindex -gnatw (gcc)
Warning mode where
@code{xxx} is a string of option letters that denotes
the exact warnings that
-are enabled or disabled (@ref{ed,,Warning Message Control}).
+are enabled or disabled (@ref{ee,,Warning Message Control}).
@end table
@geindex -gnatW (gcc)
@item @code{-gnaty}
-Enable built-in style checks (@ref{ee,,Style Checking}).
+Enable built-in style checks (@ref{ef,,Style Checking}).
@end table
@geindex -gnatz (gcc)
Direct GNAT to search the @code{dir} directory for source files needed by
the current compilation
-(see @ref{73,,Search Paths and the Run-Time Library (RTL)}).
+(see @ref{74,,Search Paths and the Run-Time Library (RTL)}).
@end table
@geindex -I- (gcc)
Except for the source file named in the command line, do not look for source
files in the directory containing the source file named in the command line
-(see @ref{73,,Search Paths and the Run-Time Library (RTL)}).
+(see @ref{74,,Search Paths and the Run-Time Library (RTL)}).
@end table
@geindex -o (gcc)
@end multitable
-See also @ref{ef,,Optimization Levels}.
+See also @ref{f0,,Optimization Levels}.
@end table
@geindex -pass-exit-codes (gcc)
@item @code{--RTS=`rts-path'}
Specifies the default location of the run-time library. Same meaning as the
-equivalent @code{gnatmake} flag (@ref{d0,,Switches for gnatmake}).
+equivalent @code{gnatmake} flag (@ref{d1,,Switches for gnatmake}).
@end table
@geindex -S (gcc)
@item
Once a ‘V’ appears in the string (that is a use of the @code{-gnatV}
switch), then all further characters in the switch are interpreted
-as validity checking options (@ref{e9,,Validity Checking}).
+as validity checking options (@ref{ea,,Validity Checking}).
@item
Option ‘em’, ‘ec’, ‘ep’, ‘l=’ and ‘R’ must be the last options in
@end itemize
@node Output and Error Message Control,Warning Message Control,Alphabetical List of All Switches,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat id14}@anchor{f0}@anchor{gnat_ugn/building_executable_programs_with_gnat output-and-error-message-control}@anchor{f1}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id14}@anchor{f1}@anchor{gnat_ugn/building_executable_programs_with_gnat output-and-error-message-control}@anchor{f2}
@subsection Output and Error Message Control
@end table
@node Warning Message Control,Info message Control,Output and Error Message Control,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat id15}@anchor{f2}@anchor{gnat_ugn/building_executable_programs_with_gnat warning-message-control}@anchor{ed}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id15}@anchor{f3}@anchor{gnat_ugn/building_executable_programs_with_gnat warning-message-control}@anchor{ee}
@subsection Warning Message Control
many reasons for not being able to inline a call, including most
commonly that the call is too complex to inline. The default is
that such warnings are not given.
-Warnings on ineffective inlining by the gcc back-end can be activated
+Warnings on ineffective inlining by the gcc back end can be activated
separately, using the gcc switch -Winline.
@end table
@item @code{-Wstack-usage=`len'}
Warn if the stack usage of a subprogram might be larger than @code{len} bytes.
-See @ref{e8,,Static Stack Usage Analysis} for details.
+See @ref{e9,,Static Stack Usage Analysis} for details.
@end table
@geindex -Wall (gcc)
@end quotation
@node Info message Control,Debugging and Assertion Control,Warning Message Control,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat debugging-and-assertion-control}@anchor{f3}@anchor{gnat_ugn/building_executable_programs_with_gnat info-message-control}@anchor{f4}
+@anchor{gnat_ugn/building_executable_programs_with_gnat debugging-and-assertion-control}@anchor{f4}@anchor{gnat_ugn/building_executable_programs_with_gnat info-message-control}@anchor{f5}
@subsection Info message Control
@end table
@node Debugging and Assertion Control,Validity Checking,Info message Control,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat id16}@anchor{f5}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id16}@anchor{f6}
@subsection Debugging and Assertion Control
@end table
@node Validity Checking,Style Checking,Debugging and Assertion Control,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat id17}@anchor{f6}@anchor{gnat_ugn/building_executable_programs_with_gnat validity-checking}@anchor{e9}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id17}@anchor{f7}@anchor{gnat_ugn/building_executable_programs_with_gnat validity-checking}@anchor{ea}
@subsection Validity Checking
temporary disabling of validity checks.
@node Style Checking,Run-Time Checks,Validity Checking,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat id18}@anchor{f7}@anchor{gnat_ugn/building_executable_programs_with_gnat style-checking}@anchor{ee}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id18}@anchor{f8}@anchor{gnat_ugn/building_executable_programs_with_gnat style-checking}@anchor{ef}
@subsection Style Checking
The switch @code{-gnatyN} clears any previously set style checks.
@node Run-Time Checks,Using gcc for Syntax Checking,Style Checking,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat id19}@anchor{f8}@anchor{gnat_ugn/building_executable_programs_with_gnat run-time-checks}@anchor{ec}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id19}@anchor{f9}@anchor{gnat_ugn/building_executable_programs_with_gnat run-time-checks}@anchor{ed}
@subsection Run-Time Checks
Note that @code{-gnatE} is not necessary for safety, because in the
default mode, GNAT ensures statically that the checks would not fail.
For full details of the effect and use of this switch,
-@ref{c9,,Compiling with gcc}.
+@ref{ca,,Compiling with gcc}.
@end table
@geindex -fstack-check (gcc)
@item @code{-fstack-check}
Activates stack overflow checking. For full details of the effect and use of
-this switch see @ref{e7,,Stack Overflow Checking}.
+this switch see @ref{e8,,Stack Overflow Checking}.
@end table
@geindex Unsuppress
the program source.
@node Using gcc for Syntax Checking,Using gcc for Semantic Checking,Run-Time Checks,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat id20}@anchor{f9}@anchor{gnat_ugn/building_executable_programs_with_gnat using-gcc-for-syntax-checking}@anchor{fa}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id20}@anchor{fa}@anchor{gnat_ugn/building_executable_programs_with_gnat using-gcc-for-syntax-checking}@anchor{fb}
@subsection Using @code{gcc} for Syntax Checking
restriction does not apply in syntax-check-only mode, and it is possible
to check a file containing multiple compilation units concatenated
together. This is primarily used by the @code{gnatchop} utility
-(@ref{1d,,Renaming Files with gnatchop}).
+(@ref{1e,,Renaming Files with gnatchop}).
@end table
@node Using gcc for Semantic Checking,Compiling Different Versions of Ada,Using gcc for Syntax Checking,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat id21}@anchor{fb}@anchor{gnat_ugn/building_executable_programs_with_gnat using-gcc-for-semantic-checking}@anchor{fc}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id21}@anchor{fc}@anchor{gnat_ugn/building_executable_programs_with_gnat using-gcc-for-semantic-checking}@anchor{fd}
@subsection Using @code{gcc} for Semantic Checking
@item
The needed source files must be accessible
-(see @ref{73,,Search Paths and the Run-Time Library (RTL)}).
+(see @ref{74,,Search Paths and the Run-Time Library (RTL)}).
@item
Each file must contain only one compilation unit.
@item
-The file name and unit name must match (@ref{3b,,File Naming Rules}).
+The file name and unit name must match (@ref{3c,,File Naming Rules}).
@end itemize
The output consists of error messages as appropriate. No object file is
@end table
@node Compiling Different Versions of Ada,Character Set Control,Using gcc for Semantic Checking,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat compiling-different-versions-of-ada}@anchor{6}@anchor{gnat_ugn/building_executable_programs_with_gnat id22}@anchor{fd}
+@anchor{gnat_ugn/building_executable_programs_with_gnat compiling-different-versions-of-ada}@anchor{6}@anchor{gnat_ugn/building_executable_programs_with_gnat id22}@anchor{fe}
@subsection Compiling Different Versions of Ada
@end table
@node Character Set Control,File Naming Control,Compiling Different Versions of Ada,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat character-set-control}@anchor{31}@anchor{gnat_ugn/building_executable_programs_with_gnat id23}@anchor{fe}
+@anchor{gnat_ugn/building_executable_programs_with_gnat character-set-control}@anchor{32}@anchor{gnat_ugn/building_executable_programs_with_gnat id23}@anchor{ff}
@subsection Character Set Control
@end multitable
-See @ref{23,,Foreign Language Representation} for full details on the
+See @ref{24,,Foreign Language Representation} for full details on the
implementation of these character sets.
@end table
For full details on these encoding
-methods see @ref{37,,Wide_Character Encodings}.
+methods see @ref{38,,Wide_Character Encodings}.
Note that brackets coding is always accepted, even if one of the other
options is specified, so for example @code{-gnatW8} specifies that both
brackets and UTF-8 encodings will be recognized. The units that are
This is a common mode for many programs with foreign language comments.
@node File Naming Control,Subprogram Inlining Control,Character Set Control,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat file-naming-control}@anchor{ff}@anchor{gnat_ugn/building_executable_programs_with_gnat id24}@anchor{100}
+@anchor{gnat_ugn/building_executable_programs_with_gnat file-naming-control}@anchor{100}@anchor{gnat_ugn/building_executable_programs_with_gnat id24}@anchor{101}
@subsection File Naming Control
including the @code{.ads} or @code{.adb} extension). The default is not
to enable file name krunching.
-For the source file naming rules, @ref{3b,,File Naming Rules}.
+For the source file naming rules, @ref{3c,,File Naming Rules}.
@end table
@node Subprogram Inlining Control,Auxiliary Output Control,File Naming Control,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat id25}@anchor{101}@anchor{gnat_ugn/building_executable_programs_with_gnat subprogram-inlining-control}@anchor{102}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id25}@anchor{102}@anchor{gnat_ugn/building_executable_programs_with_gnat subprogram-inlining-control}@anchor{103}
@subsection Subprogram Inlining Control
creating an extra source dependency for the resulting object file, and
where possible, the call will be inlined.
For further details on when inlining is possible
-see @ref{103,,Inlining of Subprograms}.
+see @ref{104,,Inlining of Subprograms}.
@end table
@geindex -gnatN (gcc)
@end table
@node Auxiliary Output Control,Debugging Control,Subprogram Inlining Control,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat auxiliary-output-control}@anchor{104}@anchor{gnat_ugn/building_executable_programs_with_gnat id26}@anchor{105}
+@anchor{gnat_ugn/building_executable_programs_with_gnat auxiliary-output-control}@anchor{105}@anchor{gnat_ugn/building_executable_programs_with_gnat id26}@anchor{106}
@subsection Auxiliary Output Control
@end table
@node Debugging Control,Exception Handling Control,Auxiliary Output Control,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat debugging-control}@anchor{106}@anchor{gnat_ugn/building_executable_programs_with_gnat id27}@anchor{107}
+@anchor{gnat_ugn/building_executable_programs_with_gnat debugging-control}@anchor{107}@anchor{gnat_ugn/building_executable_programs_with_gnat id27}@anchor{108}
@subsection Debugging Control
@end table
@node Exception Handling Control,Units to Sources Mapping Files,Debugging Control,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat exception-handling-control}@anchor{108}@anchor{gnat_ugn/building_executable_programs_with_gnat id28}@anchor{109}
+@anchor{gnat_ugn/building_executable_programs_with_gnat exception-handling-control}@anchor{109}@anchor{gnat_ugn/building_executable_programs_with_gnat id28}@anchor{10a}
@subsection Exception Handling Control
The same option @code{--RTS} must be used both for @code{gcc}
and @code{gnatbind}. Passing this option to @code{gnatmake}
-(@ref{d0,,Switches for gnatmake}) will ensure the required consistency
+(@ref{d1,,Switches for gnatmake}) will ensure the required consistency
through the compilation and binding steps.
@node Units to Sources Mapping Files,Code Generation Control,Exception Handling Control,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat id29}@anchor{10a}@anchor{gnat_ugn/building_executable_programs_with_gnat units-to-sources-mapping-files}@anchor{ea}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id29}@anchor{10b}@anchor{gnat_ugn/building_executable_programs_with_gnat units-to-sources-mapping-files}@anchor{eb}
@subsection Units to Sources Mapping Files
@end table
@node Code Generation Control,,Units to Sources Mapping Files,Compiler Switches
-@anchor{gnat_ugn/building_executable_programs_with_gnat code-generation-control}@anchor{10b}@anchor{gnat_ugn/building_executable_programs_with_gnat id30}@anchor{10c}
+@anchor{gnat_ugn/building_executable_programs_with_gnat code-generation-control}@anchor{10c}@anchor{gnat_ugn/building_executable_programs_with_gnat id30}@anchor{10d}
@subsection Code Generation Control
unless you actually see a performance improvement.
@node Linker Switches,Binding with gnatbind,Compiler Switches,Building Executable Programs with GNAT
-@anchor{gnat_ugn/building_executable_programs_with_gnat id31}@anchor{10d}@anchor{gnat_ugn/building_executable_programs_with_gnat linker-switches}@anchor{10e}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id31}@anchor{10e}@anchor{gnat_ugn/building_executable_programs_with_gnat linker-switches}@anchor{10f}
@section Linker Switches
@end table
@node Binding with gnatbind,Linking with gnatlink,Linker Switches,Building Executable Programs with GNAT
-@anchor{gnat_ugn/building_executable_programs_with_gnat binding-with-gnatbind}@anchor{ca}@anchor{gnat_ugn/building_executable_programs_with_gnat id32}@anchor{10f}
+@anchor{gnat_ugn/building_executable_programs_with_gnat binding-with-gnatbind}@anchor{cb}@anchor{gnat_ugn/building_executable_programs_with_gnat id32}@anchor{110}
@section Binding with @code{gnatbind}
@end menu
@node Running gnatbind,Switches for gnatbind,,Binding with gnatbind
-@anchor{gnat_ugn/building_executable_programs_with_gnat id33}@anchor{110}@anchor{gnat_ugn/building_executable_programs_with_gnat running-gnatbind}@anchor{111}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id33}@anchor{111}@anchor{gnat_ugn/building_executable_programs_with_gnat running-gnatbind}@anchor{112}
@subsection Running @code{gnatbind}
Now both files must be recompiled as indicated, and then the bind can
succeed, generating a main program. You need not normally be concerned
with the contents of this file, but for reference purposes a sample
-binder output file is given in @ref{e,,Example of Binder Output File}.
+binder output file is given in @ref{f,,Example of Binder Output File}.
In most normal usage, the default mode of @code{gnatbind} which is to
generate the main package in Ada, as described in the previous section.
@code{gnatbind} and @code{gnatlink}.
@node Switches for gnatbind,Command-Line Access,Running gnatbind,Binding with gnatbind
-@anchor{gnat_ugn/building_executable_programs_with_gnat id34}@anchor{112}@anchor{gnat_ugn/building_executable_programs_with_gnat switches-for-gnatbind}@anchor{113}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id34}@anchor{113}@anchor{gnat_ugn/building_executable_programs_with_gnat switches-for-gnatbind}@anchor{114}
@subsection Switches for @code{gnatbind}
@item @code{-f`elab-order'}
-Force elaboration order. For further details see @ref{114,,Elaboration Control}
-and @ref{f,,Elaboration Order Handling in GNAT}.
+Force elaboration order. For further details see @ref{115,,Elaboration Control}
+and @ref{10,,Elaboration Order Handling in GNAT}.
@end table
@geindex -F (gnatbind)
@item @code{-H}
Legacy elaboration order model enabled. For further details see
-@ref{f,,Elaboration Order Handling in GNAT}.
+@ref{10,,Elaboration Order Handling in GNAT}.
@end table
@geindex -H32 (gnatbind)
@item @code{-H32}
Use 32-bit allocations for @code{__gnat_malloc} (and thus for access types).
-For further details see @ref{115,,Dynamic Allocation Control}.
+For further details see @ref{116,,Dynamic Allocation Control}.
@end table
@geindex -H64 (gnatbind)
@item @code{-H64}
Use 64-bit allocations for @code{__gnat_malloc} (and thus for access types).
-For further details see @ref{115,,Dynamic Allocation Control}.
+For further details see @ref{116,,Dynamic Allocation Control}.
@geindex -I (gnatbind)
@item @code{-L`xxx'}
Bind the units for library building. In this case the @code{adainit} and
-@code{adafinal} procedures (@ref{7e,,Binding with Non-Ada Main Programs})
+@code{adafinal} procedures (@ref{7f,,Binding with Non-Ada Main Programs})
are renamed to @code{@var{xxx}init} and
@code{@var{xxx}final}.
Implies -n.
-(@ref{2a,,GNAT and Libraries}, for more details.)
+(@ref{2b,,GNAT and Libraries}, for more details.)
@geindex -M (gnatbind)
@item @code{--RTS=`rts-path'}
Specifies the default location of the run-time library. Same meaning as the
-equivalent @code{gnatmake} flag (@ref{d0,,Switches for gnatmake}).
+equivalent @code{gnatmake} flag (@ref{d1,,Switches for gnatmake}).
@geindex -o (gnatbind)
at program termination. A result is generated when a task
terminates. Results that can’t be stored are displayed on the fly, at
task termination. This option is currently not supported on Itanium
-platforms. (See @ref{116,,Dynamic Stack Usage Analysis} for details.)
+platforms. (See @ref{117,,Dynamic Stack Usage Analysis} for details.)
@geindex -v (gnatbind)
@end menu
@node Consistency-Checking Modes,Binder Error Message Control,,Switches for gnatbind
-@anchor{gnat_ugn/building_executable_programs_with_gnat consistency-checking-modes}@anchor{117}@anchor{gnat_ugn/building_executable_programs_with_gnat id35}@anchor{118}
+@anchor{gnat_ugn/building_executable_programs_with_gnat consistency-checking-modes}@anchor{118}@anchor{gnat_ugn/building_executable_programs_with_gnat id35}@anchor{119}
@subsubsection Consistency-Checking Modes
@end table
@node Binder Error Message Control,Elaboration Control,Consistency-Checking Modes,Switches for gnatbind
-@anchor{gnat_ugn/building_executable_programs_with_gnat binder-error-message-control}@anchor{119}@anchor{gnat_ugn/building_executable_programs_with_gnat id36}@anchor{11a}
+@anchor{gnat_ugn/building_executable_programs_with_gnat binder-error-message-control}@anchor{11a}@anchor{gnat_ugn/building_executable_programs_with_gnat id36}@anchor{11b}
@subsubsection Binder Error Message Control
@end table
@node Elaboration Control,Output Control,Binder Error Message Control,Switches for gnatbind
-@anchor{gnat_ugn/building_executable_programs_with_gnat elaboration-control}@anchor{114}@anchor{gnat_ugn/building_executable_programs_with_gnat id37}@anchor{11b}
+@anchor{gnat_ugn/building_executable_programs_with_gnat elaboration-control}@anchor{115}@anchor{gnat_ugn/building_executable_programs_with_gnat id37}@anchor{11c}
@subsubsection Elaboration Control
The following switches provide additional control over the elaboration
-order. For further details see @ref{f,,Elaboration Order Handling in GNAT}.
+order. For further details see @ref{10,,Elaboration Order Handling in GNAT}.
@geindex -f (gnatbind)
@end table
@node Output Control,Dynamic Allocation Control,Elaboration Control,Switches for gnatbind
-@anchor{gnat_ugn/building_executable_programs_with_gnat id38}@anchor{11c}@anchor{gnat_ugn/building_executable_programs_with_gnat output-control}@anchor{11d}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id38}@anchor{11d}@anchor{gnat_ugn/building_executable_programs_with_gnat output-control}@anchor{11e}
@subsubsection Output Control
@end table
@node Dynamic Allocation Control,Binding with Non-Ada Main Programs,Output Control,Switches for gnatbind
-@anchor{gnat_ugn/building_executable_programs_with_gnat dynamic-allocation-control}@anchor{115}@anchor{gnat_ugn/building_executable_programs_with_gnat id39}@anchor{11e}
+@anchor{gnat_ugn/building_executable_programs_with_gnat dynamic-allocation-control}@anchor{116}@anchor{gnat_ugn/building_executable_programs_with_gnat id39}@anchor{11f}
@subsubsection Dynamic Allocation Control
These switches are only effective on VMS platforms.
@node Binding with Non-Ada Main Programs,Binding Programs with No Main Subprogram,Dynamic Allocation Control,Switches for gnatbind
-@anchor{gnat_ugn/building_executable_programs_with_gnat binding-with-non-ada-main-programs}@anchor{7e}@anchor{gnat_ugn/building_executable_programs_with_gnat id40}@anchor{11f}
+@anchor{gnat_ugn/building_executable_programs_with_gnat binding-with-non-ada-main-programs}@anchor{7f}@anchor{gnat_ugn/building_executable_programs_with_gnat id40}@anchor{120}
@subsubsection Binding with Non-Ada Main Programs
corresponding function @code{main} that invokes this Ada main
program. GNAT also supports the building of executable programs where
the main program is not in Ada, but some of the called routines are
-written in Ada and compiled using GNAT (@ref{2c,,Mixed Language Programming}).
+written in Ada and compiled using GNAT (@ref{2d,,Mixed Language Programming}).
The following switch is used in this situation:
@quotation
where floating point computation could be broken after this call.
@node Binding Programs with No Main Subprogram,,Binding with Non-Ada Main Programs,Switches for gnatbind
-@anchor{gnat_ugn/building_executable_programs_with_gnat binding-programs-with-no-main-subprogram}@anchor{120}@anchor{gnat_ugn/building_executable_programs_with_gnat id41}@anchor{121}
+@anchor{gnat_ugn/building_executable_programs_with_gnat binding-programs-with-no-main-subprogram}@anchor{121}@anchor{gnat_ugn/building_executable_programs_with_gnat id41}@anchor{122}
@subsubsection Binding Programs with No Main Subprogram
@end table
@node Command-Line Access,Search Paths for gnatbind,Switches for gnatbind,Binding with gnatbind
-@anchor{gnat_ugn/building_executable_programs_with_gnat command-line-access}@anchor{122}@anchor{gnat_ugn/building_executable_programs_with_gnat id42}@anchor{123}
+@anchor{gnat_ugn/building_executable_programs_with_gnat command-line-access}@anchor{123}@anchor{gnat_ugn/building_executable_programs_with_gnat id42}@anchor{124}
@subsection Command-Line Access
it.
@node Search Paths for gnatbind,Examples of gnatbind Usage,Command-Line Access,Binding with gnatbind
-@anchor{gnat_ugn/building_executable_programs_with_gnat id43}@anchor{124}@anchor{gnat_ugn/building_executable_programs_with_gnat search-paths-for-gnatbind}@anchor{76}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id43}@anchor{125}@anchor{gnat_ugn/building_executable_programs_with_gnat search-paths-for-gnatbind}@anchor{77}
@subsection Search Paths for @code{gnatbind}
locate source files as well as other ALI files to verify object consistency.
For source files, it follows exactly the same search rules as @code{gcc}
-(see @ref{73,,Search Paths and the Run-Time Library (RTL)}). For ALI files the
+(see @ref{74,,Search Paths and the Run-Time Library (RTL)}). For ALI files the
directories searched are:
The content of the @code{ada_object_path} file which is part of the GNAT
installation tree and is used to store standard libraries such as the
GNAT Run-Time Library (RTL) unless the switch @code{-nostdlib} is
-specified. See @ref{72,,Installing a library}
+specified. See @ref{73,,Installing a library}
@end itemize
@geindex -I (gnatbind)
development environments much more flexible.
@node Examples of gnatbind Usage,,Search Paths for gnatbind,Binding with gnatbind
-@anchor{gnat_ugn/building_executable_programs_with_gnat examples-of-gnatbind-usage}@anchor{125}@anchor{gnat_ugn/building_executable_programs_with_gnat id44}@anchor{126}
+@anchor{gnat_ugn/building_executable_programs_with_gnat examples-of-gnatbind-usage}@anchor{126}@anchor{gnat_ugn/building_executable_programs_with_gnat id44}@anchor{127}
@subsection Examples of @code{gnatbind} Usage
@end quotation
@node Linking with gnatlink,Using the GNU make Utility,Binding with gnatbind,Building Executable Programs with GNAT
-@anchor{gnat_ugn/building_executable_programs_with_gnat id45}@anchor{127}@anchor{gnat_ugn/building_executable_programs_with_gnat linking-with-gnatlink}@anchor{cb}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id45}@anchor{128}@anchor{gnat_ugn/building_executable_programs_with_gnat linking-with-gnatlink}@anchor{cc}
@section Linking with @code{gnatlink}
@end menu
@node Running gnatlink,Switches for gnatlink,,Linking with gnatlink
-@anchor{gnat_ugn/building_executable_programs_with_gnat id46}@anchor{128}@anchor{gnat_ugn/building_executable_programs_with_gnat running-gnatlink}@anchor{129}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id46}@anchor{129}@anchor{gnat_ugn/building_executable_programs_with_gnat running-gnatlink}@anchor{12a}
@subsection Running @code{gnatlink}
Using @code{linker options} it is possible to set the program stack and
heap size.
-See @ref{12a,,Setting Stack Size from gnatlink} and
-@ref{12b,,Setting Heap Size from gnatlink}.
+See @ref{12b,,Setting Stack Size from gnatlink} and
+@ref{12c,,Setting Heap Size from gnatlink}.
@code{gnatlink} determines the list of objects required by the Ada
program and prepends them to the list of objects passed to the linker.
presented to the linker.
@node Switches for gnatlink,,Running gnatlink,Linking with gnatlink
-@anchor{gnat_ugn/building_executable_programs_with_gnat id47}@anchor{12c}@anchor{gnat_ugn/building_executable_programs_with_gnat switches-for-gnatlink}@anchor{12d}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id47}@anchor{12d}@anchor{gnat_ugn/building_executable_programs_with_gnat switches-for-gnatlink}@anchor{12e}
@subsection Switches for @code{gnatlink}
command that will be used by @code{gnatlink} will be @code{foo -c -x -y}.
A limitation of this syntax is that the name and path name of the executable
itself must not include any embedded spaces. If the compiler executable is
-different from the default one (gcc or <prefix>-gcc), then the back-end
+different from the default one (gcc or <prefix>-gcc), then the back end
switches in the ALI file are not used to compile the binder generated source.
For example, this is the case with @code{--GCC="foo -x -y"}. But the back end
switches will be used for @code{--GCC="gcc -gnatv"}. If several
@end table
@node Using the GNU make Utility,,Linking with gnatlink,Building Executable Programs with GNAT
-@anchor{gnat_ugn/building_executable_programs_with_gnat id48}@anchor{12e}@anchor{gnat_ugn/building_executable_programs_with_gnat using-the-gnu-make-utility}@anchor{70}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id48}@anchor{12f}@anchor{gnat_ugn/building_executable_programs_with_gnat using-the-gnu-make-utility}@anchor{71}
@section Using the GNU @code{make} Utility
This chapter offers some examples of makefiles that solve specific
problems. It does not explain how to write a makefile, nor does it try to replace the
-@code{gnatmake} utility (@ref{c8,,Building with gnatmake}).
+@code{gnatmake} utility (@ref{c9,,Building with gnatmake}).
All the examples in this section are specific to the GNU version of
make. Although @code{make} is a standard utility, and the basic language
* Automatically Creating a List of Directories::
* Generating the Command Line Switches::
* Overcoming Command Line Length Limits::
+* GNAT with the LLVM Back End::
@end menu
@node Using gnatmake in a Makefile,Automatically Creating a List of Directories,,Using the GNU make Utility
-@anchor{gnat_ugn/building_executable_programs_with_gnat id49}@anchor{12f}@anchor{gnat_ugn/building_executable_programs_with_gnat using-gnatmake-in-a-makefile}@anchor{130}
+@anchor{gnat_ugn/building_executable_programs_with_gnat id49}@anchor{130}@anchor{gnat_ugn/building_executable_programs_with_gnat using-gnatmake-in-a-makefile}@anchor{131}
@subsection Using gnatmake in a Makefile
Note that you should also read the example on how to automatically
create the list of directories
-(@ref{131,,Automatically Creating a List of Directories})
+(@ref{132,,Automatically Creating a List of Directories})
which might help you in case your project has a lot of subdirectories.
@example
@end example
@node Automatically Creating a List of Directories,Generating the Command Line Switches,Using gnatmake in a Makefile,Using the GNU make Utility
-@anchor{gnat_ugn/building_executable_programs_with_gnat automatically-creating-a-list-of-directories}@anchor{131}@anchor{gnat_ugn/building_executable_programs_with_gnat id50}@anchor{132}
+@anchor{gnat_ugn/building_executable_programs_with_gnat automatically-creating-a-list-of-directories}@anchor{132}@anchor{gnat_ugn/building_executable_programs_with_gnat id50}@anchor{133}
@subsection Automatically Creating a List of Directories
@end example
@node Generating the Command Line Switches,Overcoming Command Line Length Limits,Automatically Creating a List of Directories,Using the GNU make Utility
-@anchor{gnat_ugn/building_executable_programs_with_gnat generating-the-command-line-switches}@anchor{133}@anchor{gnat_ugn/building_executable_programs_with_gnat id51}@anchor{134}
+@anchor{gnat_ugn/building_executable_programs_with_gnat generating-the-command-line-switches}@anchor{134}@anchor{gnat_ugn/building_executable_programs_with_gnat id51}@anchor{135}
@subsection Generating the Command Line Switches
Once you have created the list of directories as explained in the
-previous section (@ref{131,,Automatically Creating a List of Directories}),
+previous section (@ref{132,,Automatically Creating a List of Directories}),
you can easily generate the command line arguments to pass to gnatmake.
For the sake of completeness, this example assumes that the source path
gnatmake $@{GNATMAKE_SWITCHES@} main_unit
@end example
-@node Overcoming Command Line Length Limits,,Generating the Command Line Switches,Using the GNU make Utility
-@anchor{gnat_ugn/building_executable_programs_with_gnat id52}@anchor{135}@anchor{gnat_ugn/building_executable_programs_with_gnat overcoming-command-line-length-limits}@anchor{136}
+@node Overcoming Command Line Length Limits,GNAT with the LLVM Back End,Generating the Command Line Switches,Using the GNU make Utility
+@anchor{gnat_ugn/building_executable_programs_with_gnat id52}@anchor{136}@anchor{gnat_ugn/building_executable_programs_with_gnat overcoming-command-line-length-limits}@anchor{137}
@subsection Overcoming Command Line Length Limits
It assumes that you have created a list of directories in your Makefile,
using one of the methods presented in
-@ref{131,,Automatically Creating a List of Directories}.
+@ref{132,,Automatically Creating a List of Directories}.
For the sake of completeness, we assume that the object
path (where the ALI files are found) is different from the sources patch.
gnatmake main_unit
@end example
+@node GNAT with the LLVM Back End,,Overcoming Command Line Length Limits,Using the GNU make Utility
+@anchor{gnat_ugn/building_executable_programs_with_gnat gnat-with-the-llvm-back-end}@anchor{138}@anchor{gnat_ugn/building_executable_programs_with_gnat gnatllvm}@anchor{7}
+@subsection GNAT with the LLVM Back End
+
+
+This section outlines the usage of the GNAT compiler with the LLVM
+back end and highlights its key limitations. Certain GNAT versions,
+referred to as GNAT LLVM, include an alternative LLVM back end
+alongside the GCC back end, providing access to utilities that operate
+at the LLVM Intermediate Representation (IR) level. This also enhances
+safety by facilitating dissimilar redundancy through diverse code
+generation techniques, allowing for the creation of two distinct
+binaries from the same source code.
+
+Although both GNAT LLVM and the GCC-based GNAT follow most ABI rules,
+there are some cases where there you may encounter an incompatibility
+between the two compilers. One such case for the 64-bit Intel X86 is
+a difference in parameter passing when a structure that consists of 64
+bits is passed. The native LLVM handling (and hence that of GNAT LLVM)
+and @code{clang} disagree in this case. GCC follows @code{clang}. The formal
+ABI agrees with LLVM.
+
+In any case, we don’t recommend you link code compiled with GNAT LLVM
+to code compiled by the GCC version of GNAT. This is a specific case
+of the general rule that you should compile all your Ada code with the
+same version of GNAT. Both @code{gnatmake} and @code{gprbuild} ensure this
+is done.
+
+You may, however, run into this incompatibility if you pass such a
+record between C and Ada. In general, we recommend keeping the data
+passed between C and Ada as simple as practical.
+
+GNAT LLVM currently provides limited support for debugging data. It
+provides full line number information for declarations and statements,
+but not sufficient debugging data to display all Ada data
+structures. GNAT LLVM outputs complete debugging data only for types
+with a direct equivalent in C, namely records without discriminants
+and constrained arrays whose dimensions are known at compile time. You
+will not be able to use @code{gdb} print commands to look at objects not
+of those types or to display components of those types. You can use
+low-level @code{gdb} commands that display memory to view such data
+provided you know how they’re laid out. Debugging information may
+also be limited for bitfields (fields whose size and position
+aren’t on byte boundaries)
+
+In addition, debugging information may be confusing if you have
+@code{out} parameters to subprograms. If you have a procedure with only
+one @code{out} parameter, GNAT LLVM converts that to a function returning
+an object of that type. If you have multiple @code{out} parameters or
+have a function that also has an @code{out} parameter, GNAT LLVM converts
+that subprogram into a function that returns a record where each field
+is either an @code{out} parameter or the function return value, if any.
+The debug information reflects these transformations and not the original
+Ada source code.
+
+GNAT LLVM doesn’t fully implement the :switch:@code{-fcheck-stack} switch.
+When you specify it, the code generated by GNAT LLVM tests for allocating
+overly-large items on the stack, but not all cases of stack overflow. For
+example, if you have a very deep recursion where each call only uses a
+small amount of stack and the total stack depth exceeds the amount of
+available stack, the program will be terminated by a signal instead of
+raising an Ada exception.
+
+GNAT LLVM doesn’t support the @code{Scalar_Storage_Order} pragma except when
+it’s used to confirm the chosen storage order. This is because this facility
+is provided by GCC but not by LLVM.
+
+GNAT LLVM doesn’t support Convention C++, which provides so-called
+‘name mangling’ by encoding parameter and return datatypes into a
+function name.
+
+
+We provide two options that you can use to build code with GNAT LLVM:
+
+
+@itemize *
+
+@item
+GNAT LLVM includes a version of @code{gnatmake} called
+@code{llvm-gnatmake}, which is equivalent to @code{gnatmake} and has the
+same switches, except that it uses GNAT LLVM instead of the GCC
+version of GNAT.
+
+@item
+@code{gprbuild} can detect and use GNAT LLVM when it is installed.
+
+@code{gprbuild} uses the first applicable compiler on the executable
+search path, including GNAT LLVM. An easy way to build with GNAT
+LLVM is to make it available on the operating system’s search path
+before any other Ada compiler (such as the GCC version of GNAT). To
+avoid accidentally using a different compiler than the one you want
+to use, we recommend generating an explicit toolchain configuration
+file with @code{gprconfig} and using it with @code{gprbuild}; see the
+`GPRbuild and GPR Companion Tools User’s Guide' for details. You
+can determine from the first line of the @code{.ali} file
+which version of GNAT built that file because it contains either
+:code:@code{GNAT} or :code:@code{GNAT-LLVM}.
+@end itemize
+
+
+GNAT LLVM understands the same target triplets as the GCC version of
+GNAT.
+
+
@node GNAT Utility Programs,GNAT and Program Execution,Building Executable Programs with GNAT,Top
-@anchor{gnat_ugn/gnat_utility_programs doc}@anchor{137}@anchor{gnat_ugn/gnat_utility_programs gnat-utility-programs}@anchor{b}@anchor{gnat_ugn/gnat_utility_programs id1}@anchor{138}
+@anchor{gnat_ugn/gnat_utility_programs doc}@anchor{139}@anchor{gnat_ugn/gnat_utility_programs gnat-utility-programs}@anchor{c}@anchor{gnat_ugn/gnat_utility_programs id1}@anchor{13a}
@chapter GNAT Utility Programs
@itemize *
@item
-@ref{139,,The File Cleanup Utility gnatclean}
+@ref{13b,,The File Cleanup Utility gnatclean}
@item
-@ref{13a,,The GNAT Library Browser gnatls}
+@ref{13c,,The GNAT Library Browser gnatls}
@end itemize
Other GNAT utilities are described elsewhere in this manual:
@itemize *
@item
-@ref{42,,Handling Arbitrary File Naming Conventions with gnatname}
+@ref{43,,Handling Arbitrary File Naming Conventions with gnatname}
@item
-@ref{4c,,File Name Krunching with gnatkr}
+@ref{4d,,File Name Krunching with gnatkr}
@item
-@ref{1d,,Renaming Files with gnatchop}
+@ref{1e,,Renaming Files with gnatchop}
@item
-@ref{90,,Preprocessing with gnatprep}
+@ref{91,,Preprocessing with gnatprep}
@end itemize
@menu
@end menu
@node The File Cleanup Utility gnatclean,The GNAT Library Browser gnatls,,GNAT Utility Programs
-@anchor{gnat_ugn/gnat_utility_programs id2}@anchor{13b}@anchor{gnat_ugn/gnat_utility_programs the-file-cleanup-utility-gnatclean}@anchor{139}
+@anchor{gnat_ugn/gnat_utility_programs id2}@anchor{13d}@anchor{gnat_ugn/gnat_utility_programs the-file-cleanup-utility-gnatclean}@anchor{13b}
@section The File Cleanup Utility @code{gnatclean}
@end menu
@node Running gnatclean,Switches for gnatclean,,The File Cleanup Utility gnatclean
-@anchor{gnat_ugn/gnat_utility_programs id3}@anchor{13c}@anchor{gnat_ugn/gnat_utility_programs running-gnatclean}@anchor{13d}
+@anchor{gnat_ugn/gnat_utility_programs id3}@anchor{13e}@anchor{gnat_ugn/gnat_utility_programs running-gnatclean}@anchor{13f}
@subsection Running @code{gnatclean}
normal mode, but doesn’t actually delete any files.
@node Switches for gnatclean,,Running gnatclean,The File Cleanup Utility gnatclean
-@anchor{gnat_ugn/gnat_utility_programs id4}@anchor{13e}@anchor{gnat_ugn/gnat_utility_programs switches-for-gnatclean}@anchor{13f}
+@anchor{gnat_ugn/gnat_utility_programs id4}@anchor{140}@anchor{gnat_ugn/gnat_utility_programs switches-for-gnatclean}@anchor{141}
@subsection Switches for @code{gnatclean}
@item @code{-vP`x'}
Indicates the verbosity of the parsing of GNAT project files.
-@ref{d1,,Switches Related to Project Files}.
+@ref{d2,,Switches Related to Project Files}.
@end table
@geindex -X (gnatclean)
Indicates that external variable @code{name} has the value @code{value}.
The Project Manager will use this value for occurrences of
@code{external(name)} when parsing the project file.
-See @ref{d1,,Switches Related to Project Files}.
+See @ref{d2,,Switches Related to Project Files}.
@end table
@geindex -aO (gnatclean)
@end table
@node The GNAT Library Browser gnatls,,The File Cleanup Utility gnatclean,GNAT Utility Programs
-@anchor{gnat_ugn/gnat_utility_programs id5}@anchor{140}@anchor{gnat_ugn/gnat_utility_programs the-gnat-library-browser-gnatls}@anchor{13a}
+@anchor{gnat_ugn/gnat_utility_programs id5}@anchor{142}@anchor{gnat_ugn/gnat_utility_programs the-gnat-library-browser-gnatls}@anchor{13c}
@section The GNAT Library Browser @code{gnatls}
@end menu
@node Running gnatls,Switches for gnatls,,The GNAT Library Browser gnatls
-@anchor{gnat_ugn/gnat_utility_programs id6}@anchor{141}@anchor{gnat_ugn/gnat_utility_programs running-gnatls}@anchor{142}
+@anchor{gnat_ugn/gnat_utility_programs id6}@anchor{143}@anchor{gnat_ugn/gnat_utility_programs running-gnatls}@anchor{144}
@subsection Running @code{gnatls}
@end quotation
The main argument is the list of object or @code{ali} files
-(see @ref{28,,The Ada Library Information Files})
+(see @ref{29,,The Ada Library Information Files})
for which you are requesting information.
In the default mode, without additional options, @code{gnatls} produces a
@end table
@node Switches for gnatls,Example of gnatls Usage,Running gnatls,The GNAT Library Browser gnatls
-@anchor{gnat_ugn/gnat_utility_programs id7}@anchor{143}@anchor{gnat_ugn/gnat_utility_programs switches-for-gnatls}@anchor{144}
+@anchor{gnat_ugn/gnat_utility_programs id7}@anchor{145}@anchor{gnat_ugn/gnat_utility_programs switches-for-gnatls}@anchor{146}
@subsection Switches for @code{gnatls}
@item @code{-aO`dir'}, @code{-aI`dir'}, @code{-I`dir'}, @code{-I-}, @code{-nostdinc}
Source path manipulation. It has the same meaning as the equivalent
-@code{gnatmake} switches (@ref{d0,,Switches for gnatmake}).
+@code{gnatmake} switches (@ref{d1,,Switches for gnatmake}).
@end table
@geindex -aP (gnatls)
Specifies the default location of the runtime library. It has the
same meaning as the equivalent @code{gnatmake} switch
-(@ref{d0,,Switches for gnatmake}).
+(@ref{d1,,Switches for gnatmake}).
@end table
@geindex -v (gnatls)
@end table
@node Example of gnatls Usage,,Switches for gnatls,The GNAT Library Browser gnatls
-@anchor{gnat_ugn/gnat_utility_programs example-of-gnatls-usage}@anchor{145}@anchor{gnat_ugn/gnat_utility_programs id8}@anchor{146}
+@anchor{gnat_ugn/gnat_utility_programs example-of-gnatls-usage}@anchor{147}@anchor{gnat_ugn/gnat_utility_programs id8}@anchor{148}
@subsection Example of @code{gnatls} Usage
@c -- Example: A |withing| unit has a |with| clause, it |withs| a |withed| unit
@node GNAT and Program Execution,Platform-Specific Information,GNAT Utility Programs,Top
-@anchor{gnat_ugn/gnat_and_program_execution doc}@anchor{147}@anchor{gnat_ugn/gnat_and_program_execution gnat-and-program-execution}@anchor{c}@anchor{gnat_ugn/gnat_and_program_execution id1}@anchor{148}
+@anchor{gnat_ugn/gnat_and_program_execution doc}@anchor{149}@anchor{gnat_ugn/gnat_and_program_execution gnat-and-program-execution}@anchor{d}@anchor{gnat_ugn/gnat_and_program_execution id1}@anchor{14a}
@chapter GNAT and Program Execution
@itemize *
@item
-@ref{149,,Running and Debugging Ada Programs}
+@ref{14b,,Running and Debugging Ada Programs}
@item
-@ref{14a,,Profiling}
+@ref{14c,,Profiling}
@item
-@ref{14b,,Improving Performance}
+@ref{14d,,Improving Performance}
@item
-@ref{14c,,Overflow Check Handling in GNAT}
+@ref{14e,,Overflow Check Handling in GNAT}
@item
-@ref{14d,,Performing Dimensionality Analysis in GNAT}
+@ref{14f,,Performing Dimensionality Analysis in GNAT}
@item
-@ref{14e,,Stack Related Facilities}
+@ref{150,,Stack Related Facilities}
@item
-@ref{14f,,Memory Management Issues}
+@ref{151,,Memory Management Issues}
@end itemize
@menu
@end menu
@node Running and Debugging Ada Programs,Profiling,,GNAT and Program Execution
-@anchor{gnat_ugn/gnat_and_program_execution id2}@anchor{149}@anchor{gnat_ugn/gnat_and_program_execution running-and-debugging-ada-programs}@anchor{150}
+@anchor{gnat_ugn/gnat_and_program_execution id2}@anchor{14b}@anchor{gnat_ugn/gnat_and_program_execution running-and-debugging-ada-programs}@anchor{152}
@section Running and Debugging Ada Programs
@end menu
@node The GNAT Debugger GDB,Running GDB,,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution id3}@anchor{151}@anchor{gnat_ugn/gnat_and_program_execution the-gnat-debugger-gdb}@anchor{152}
+@anchor{gnat_ugn/gnat_and_program_execution id3}@anchor{153}@anchor{gnat_ugn/gnat_and_program_execution the-gnat-debugger-gdb}@anchor{154}
@subsection The GNAT Debugger GDB
variables and more generally to report on the state of execution.
@node Running GDB,Introduction to GDB Commands,The GNAT Debugger GDB,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution id4}@anchor{153}@anchor{gnat_ugn/gnat_and_program_execution running-gdb}@anchor{154}
+@anchor{gnat_ugn/gnat_and_program_execution id4}@anchor{155}@anchor{gnat_ugn/gnat_and_program_execution running-gdb}@anchor{156}
@subsection Running GDB
describes some of the additional commands that you can give to @code{GDB}.
@node Introduction to GDB Commands,Using Ada Expressions,Running GDB,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution id5}@anchor{155}@anchor{gnat_ugn/gnat_and_program_execution introduction-to-gdb-commands}@anchor{156}
+@anchor{gnat_ugn/gnat_and_program_execution id5}@anchor{157}@anchor{gnat_ugn/gnat_and_program_execution introduction-to-gdb-commands}@anchor{158}
@subsection Introduction to GDB Commands
@code{breakpoint}).
@node Using Ada Expressions,Calling User-Defined Subprograms,Introduction to GDB Commands,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution id6}@anchor{157}@anchor{gnat_ugn/gnat_and_program_execution using-ada-expressions}@anchor{158}
+@anchor{gnat_ugn/gnat_and_program_execution id6}@anchor{159}@anchor{gnat_ugn/gnat_and_program_execution using-ada-expressions}@anchor{15a}
@subsection Using Ada Expressions
For details on the supported Ada syntax, see @cite{Debugging with GDB}.
@node Calling User-Defined Subprograms,Using the next Command in a Function,Using Ada Expressions,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution calling-user-defined-subprograms}@anchor{159}@anchor{gnat_ugn/gnat_and_program_execution id7}@anchor{15a}
+@anchor{gnat_ugn/gnat_and_program_execution calling-user-defined-subprograms}@anchor{15b}@anchor{gnat_ugn/gnat_and_program_execution id7}@anchor{15c}
@subsection Calling User-Defined Subprograms
the elements in the format you desire.
@node Using the next Command in a Function,Stopping When Ada Exceptions Are Raised,Calling User-Defined Subprograms,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution id8}@anchor{15b}@anchor{gnat_ugn/gnat_and_program_execution using-the-next-command-in-a-function}@anchor{15c}
+@anchor{gnat_ugn/gnat_and_program_execution id8}@anchor{15d}@anchor{gnat_ugn/gnat_and_program_execution using-the-next-command-in-a-function}@anchor{15e}
@subsection Using the `next' Command in a Function
that was stepped through.
@node Stopping When Ada Exceptions Are Raised,Ada Tasks,Using the next Command in a Function,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution id9}@anchor{15d}@anchor{gnat_ugn/gnat_and_program_execution stopping-when-ada-exceptions-are-raised}@anchor{15e}
+@anchor{gnat_ugn/gnat_and_program_execution id9}@anchor{15f}@anchor{gnat_ugn/gnat_and_program_execution stopping-when-ada-exceptions-are-raised}@anchor{160}
@subsection Stopping When Ada Exceptions Are Raised
@geindex Tasks (in gdb)
@node Ada Tasks,Debugging Generic Units,Stopping When Ada Exceptions Are Raised,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution ada-tasks}@anchor{15f}@anchor{gnat_ugn/gnat_and_program_execution id10}@anchor{160}
+@anchor{gnat_ugn/gnat_and_program_execution ada-tasks}@anchor{161}@anchor{gnat_ugn/gnat_and_program_execution id10}@anchor{162}
@subsection Ada Tasks
@geindex Generics
@node Debugging Generic Units,Remote Debugging with gdbserver,Ada Tasks,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution debugging-generic-units}@anchor{161}@anchor{gnat_ugn/gnat_and_program_execution id11}@anchor{162}
+@anchor{gnat_ugn/gnat_and_program_execution debugging-generic-units}@anchor{163}@anchor{gnat_ugn/gnat_and_program_execution id11}@anchor{164}
@subsection Debugging Generic Units
@geindex Remote Debugging with gdbserver
@node Remote Debugging with gdbserver,GNAT Abnormal Termination or Failure to Terminate,Debugging Generic Units,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution id12}@anchor{163}@anchor{gnat_ugn/gnat_and_program_execution remote-debugging-with-gdbserver}@anchor{164}
+@anchor{gnat_ugn/gnat_and_program_execution id12}@anchor{165}@anchor{gnat_ugn/gnat_and_program_execution remote-debugging-with-gdbserver}@anchor{166}
@subsection Remote Debugging with gdbserver
@geindex Abnormal Termination or Failure to Terminate
@node GNAT Abnormal Termination or Failure to Terminate,Naming Conventions for GNAT Source Files,Remote Debugging with gdbserver,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution gnat-abnormal-termination-or-failure-to-terminate}@anchor{165}@anchor{gnat_ugn/gnat_and_program_execution id13}@anchor{166}
+@anchor{gnat_ugn/gnat_and_program_execution gnat-abnormal-termination-or-failure-to-terminate}@anchor{167}@anchor{gnat_ugn/gnat_and_program_execution id13}@anchor{168}
@subsection GNAT Abnormal Termination or Failure to Terminate
@code{gdb} directly on the @code{gnat1} executable. @code{gnat1} is the
front-end of GNAT and can be run independently (normally it is just
called from @code{gcc}). You can use @code{gdb} on @code{gnat1} as you
-would on a C program (but @ref{152,,The GNAT Debugger GDB} for caveats). The
+would on a C program (but @ref{154,,The GNAT Debugger GDB} for caveats). The
@code{where} command is the first line of attack; the variable
@code{lineno} (seen by @code{print lineno}), used by the second phase of
-@code{gnat1} and by the @code{gcc} backend, indicates the source line at
+@code{gnat1} and by the @code{gcc} back end, indicates the source line at
which the execution stopped, and @code{input_file name} indicates the name of
the source file.
@end itemize
@node Naming Conventions for GNAT Source Files,Getting Internal Debugging Information,GNAT Abnormal Termination or Failure to Terminate,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution id14}@anchor{167}@anchor{gnat_ugn/gnat_and_program_execution naming-conventions-for-gnat-source-files}@anchor{168}
+@anchor{gnat_ugn/gnat_and_program_execution id14}@anchor{169}@anchor{gnat_ugn/gnat_and_program_execution naming-conventions-for-gnat-source-files}@anchor{16a}
@subsection Naming Conventions for GNAT Source Files
All files prefixed with @code{exp} perform normalization and
expansion of the intermediate representation (abstract syntax tree, or AST).
The expansion has the effect of lowering the semantic level of the AST to
-a level closer to what the backend can handle. For example, it converts
+a level closer to what the back end can handle. For example, it converts
tasking operations into calls to the appropriate runtime routines.
These files use the same numbering scheme as the parser and semantics files.
For example, the construction of record initialization procedures is done in
@end itemize
@node Getting Internal Debugging Information,Stack Traceback,Naming Conventions for GNAT Source Files,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution getting-internal-debugging-information}@anchor{169}@anchor{gnat_ugn/gnat_and_program_execution id15}@anchor{16a}
+@anchor{gnat_ugn/gnat_and_program_execution getting-internal-debugging-information}@anchor{16b}@anchor{gnat_ugn/gnat_and_program_execution id15}@anchor{16c}
@subsection Getting Internal Debugging Information
@geindex stack unwinding
@node Stack Traceback,Pretty-Printers for the GNAT runtime,Getting Internal Debugging Information,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution id16}@anchor{16b}@anchor{gnat_ugn/gnat_and_program_execution stack-traceback}@anchor{16c}
+@anchor{gnat_ugn/gnat_and_program_execution id16}@anchor{16d}@anchor{gnat_ugn/gnat_and_program_execution stack-traceback}@anchor{16e}
@subsection Stack Traceback
@end menu
@node Non-Symbolic Traceback,Symbolic Traceback,,Stack Traceback
-@anchor{gnat_ugn/gnat_and_program_execution id17}@anchor{16d}@anchor{gnat_ugn/gnat_and_program_execution non-symbolic-traceback}@anchor{16e}
+@anchor{gnat_ugn/gnat_and_program_execution id17}@anchor{16f}@anchor{gnat_ugn/gnat_and_program_execution non-symbolic-traceback}@anchor{170}
@subsubsection Non-Symbolic Traceback
runtime as part of exception information.
You can translate this information using the @code{addr2line} tool, provided that
-the program is compiled with debugging options (see @ref{dd,,Compiler Switches})
+the program is compiled with debugging options (see @ref{de,,Compiler Switches})
and linked at a fixed position with @code{-no-pie}.
Here’s a simple example with @code{gnatmake}:
From this traceback, we can see that the exception was raised in @code{stb.adb}
at line 5, which was reached from a procedure call in @code{stb.adb} at line
10, and so on. @code{b~std.adb} is the binder file, which contains the
-call to the main program; @ref{111,,Running gnatbind}. The remaining entries are
+call to the main program; @ref{112,,Running gnatbind}. The remaining entries are
assorted runtime routines. The output will vary from platform to platform.
You can also use @code{GDB} with these traceback addresses to debug
@geindex symbolic
@node Symbolic Traceback,,Non-Symbolic Traceback,Stack Traceback
-@anchor{gnat_ugn/gnat_and_program_execution id18}@anchor{16f}@anchor{gnat_ugn/gnat_and_program_execution symbolic-traceback}@anchor{170}
+@anchor{gnat_ugn/gnat_and_program_execution id18}@anchor{171}@anchor{gnat_ugn/gnat_and_program_execution symbolic-traceback}@anchor{172}
@subsubsection Symbolic Traceback
terminates the program.
@node Pretty-Printers for the GNAT runtime,,Stack Traceback,Running and Debugging Ada Programs
-@anchor{gnat_ugn/gnat_and_program_execution id19}@anchor{171}@anchor{gnat_ugn/gnat_and_program_execution pretty-printers-for-the-gnat-runtime}@anchor{172}
+@anchor{gnat_ugn/gnat_and_program_execution id19}@anchor{173}@anchor{gnat_ugn/gnat_and_program_execution pretty-printers-for-the-gnat-runtime}@anchor{174}
@subsection Pretty-Printers for the GNAT runtime
@geindex Profiling
@node Profiling,Improving Performance,Running and Debugging Ada Programs,GNAT and Program Execution
-@anchor{gnat_ugn/gnat_and_program_execution id20}@anchor{173}@anchor{gnat_ugn/gnat_and_program_execution profiling}@anchor{14a}
+@anchor{gnat_ugn/gnat_and_program_execution id20}@anchor{175}@anchor{gnat_ugn/gnat_and_program_execution profiling}@anchor{14c}
@section Profiling
@end menu
@node Profiling an Ada Program with gprof,,,Profiling
-@anchor{gnat_ugn/gnat_and_program_execution id21}@anchor{174}@anchor{gnat_ugn/gnat_and_program_execution profiling-an-ada-program-with-gprof}@anchor{175}
+@anchor{gnat_ugn/gnat_and_program_execution id21}@anchor{176}@anchor{gnat_ugn/gnat_and_program_execution profiling-an-ada-program-with-gprof}@anchor{177}
@subsection Profiling an Ada Program with gprof
@end menu
@node Compilation for profiling,Program execution,,Profiling an Ada Program with gprof
-@anchor{gnat_ugn/gnat_and_program_execution compilation-for-profiling}@anchor{176}@anchor{gnat_ugn/gnat_and_program_execution id22}@anchor{177}
+@anchor{gnat_ugn/gnat_and_program_execution compilation-for-profiling}@anchor{178}@anchor{gnat_ugn/gnat_and_program_execution id22}@anchor{179}
@subsubsection Compilation for profiling
the @code{-no-pie} switch to the linker flags to disable PIE.
@node Program execution,Running gprof,Compilation for profiling,Profiling an Ada Program with gprof
-@anchor{gnat_ugn/gnat_and_program_execution id23}@anchor{178}@anchor{gnat_ugn/gnat_and_program_execution program-execution}@anchor{179}
+@anchor{gnat_ugn/gnat_and_program_execution id23}@anchor{17a}@anchor{gnat_ugn/gnat_and_program_execution program-execution}@anchor{17b}
@subsubsection Program execution
already exists, it will be overwritten by running the program.
@node Running gprof,Interpretation of profiling results,Program execution,Profiling an Ada Program with gprof
-@anchor{gnat_ugn/gnat_and_program_execution id24}@anchor{17a}@anchor{gnat_ugn/gnat_and_program_execution running-gprof}@anchor{17b}
+@anchor{gnat_ugn/gnat_and_program_execution id24}@anchor{17c}@anchor{gnat_ugn/gnat_and_program_execution running-gprof}@anchor{17d}
@subsubsection Running gprof
@end table
@node Interpretation of profiling results,,Running gprof,Profiling an Ada Program with gprof
-@anchor{gnat_ugn/gnat_and_program_execution id25}@anchor{17c}@anchor{gnat_ugn/gnat_and_program_execution interpretation-of-profiling-results}@anchor{17d}
+@anchor{gnat_ugn/gnat_and_program_execution id25}@anchor{17e}@anchor{gnat_ugn/gnat_and_program_execution interpretation-of-profiling-results}@anchor{17f}
@subsubsection Interpretation of profiling results
spent in each of those callers and called subprograms.
@node Improving Performance,Overflow Check Handling in GNAT,Profiling,GNAT and Program Execution
-@anchor{gnat_ugn/gnat_and_program_execution id26}@anchor{14b}@anchor{gnat_ugn/gnat_and_program_execution improving-performance}@anchor{17e}
+@anchor{gnat_ugn/gnat_and_program_execution id26}@anchor{14d}@anchor{gnat_ugn/gnat_and_program_execution improving-performance}@anchor{180}
@section Improving Performance
@end menu
@node Performance Considerations,Text_IO Suggestions,,Improving Performance
-@anchor{gnat_ugn/gnat_and_program_execution id27}@anchor{17f}@anchor{gnat_ugn/gnat_and_program_execution performance-considerations}@anchor{180}
+@anchor{gnat_ugn/gnat_and_program_execution id27}@anchor{181}@anchor{gnat_ugn/gnat_and_program_execution performance-considerations}@anchor{182}
@subsection Performance Considerations
@end menu
@node Controlling Run-Time Checks,Use of Restrictions,,Performance Considerations
-@anchor{gnat_ugn/gnat_and_program_execution controlling-run-time-checks}@anchor{181}@anchor{gnat_ugn/gnat_and_program_execution id28}@anchor{182}
+@anchor{gnat_ugn/gnat_and_program_execution controlling-run-time-checks}@anchor{183}@anchor{gnat_ugn/gnat_and_program_execution id28}@anchor{184}
@subsubsection Controlling Run-Time Checks
@geindex -gnato (gcc)
The GNAT switch, @code{-gnatp} allows you to modify this default; see
-@ref{ec,,Run-Time Checks}.
+@ref{ed,,Run-Time Checks}.
Our experience is that the default is suitable for most development
purposes.
checks) in your program source.
@node Use of Restrictions,Optimization Levels,Controlling Run-Time Checks,Performance Considerations
-@anchor{gnat_ugn/gnat_and_program_execution id29}@anchor{183}@anchor{gnat_ugn/gnat_and_program_execution use-of-restrictions}@anchor{184}
+@anchor{gnat_ugn/gnat_and_program_execution id29}@anchor{185}@anchor{gnat_ugn/gnat_and_program_execution use-of-restrictions}@anchor{186}
@subsubsection Use of Restrictions
possibility of an immediate abort at any point.
@node Optimization Levels,Debugging Optimized Code,Use of Restrictions,Performance Considerations
-@anchor{gnat_ugn/gnat_and_program_execution id30}@anchor{185}@anchor{gnat_ugn/gnat_and_program_execution optimization-levels}@anchor{ef}
+@anchor{gnat_ugn/gnat_and_program_execution id30}@anchor{187}@anchor{gnat_ugn/gnat_and_program_execution optimization-levels}@anchor{f0}
@subsubsection Optimization Levels
Full optimization as in @code{-O2};
also uses more aggressive automatic inlining of subprograms within a unit
-(@ref{103,,Inlining of Subprograms}) and attempts to vectorize loops.
+(@ref{104,,Inlining of Subprograms}) and attempts to vectorize loops.
@end table
@item
A note regarding the use of @code{-O3}: The use of this optimization level
ought not to be automatically preferred over that of level @code{-O2},
since it often results in larger executables which may run more slowly.
-See further discussion of this point in @ref{103,,Inlining of Subprograms}.
+See further discussion of this point in @ref{104,,Inlining of Subprograms}.
@node Debugging Optimized Code,Inlining of Subprograms,Optimization Levels,Performance Considerations
-@anchor{gnat_ugn/gnat_and_program_execution debugging-optimized-code}@anchor{186}@anchor{gnat_ugn/gnat_and_program_execution id31}@anchor{187}
+@anchor{gnat_ugn/gnat_and_program_execution debugging-optimized-code}@anchor{188}@anchor{gnat_ugn/gnat_and_program_execution id31}@anchor{189}
@subsubsection Debugging Optimized Code
which removes both debugging information and global symbols.
@node Inlining of Subprograms,Floating Point Operations,Debugging Optimized Code,Performance Considerations
-@anchor{gnat_ugn/gnat_and_program_execution id32}@anchor{188}@anchor{gnat_ugn/gnat_and_program_execution inlining-of-subprograms}@anchor{103}
+@anchor{gnat_ugn/gnat_and_program_execution id32}@anchor{18a}@anchor{gnat_ugn/gnat_and_program_execution inlining-of-subprograms}@anchor{104}
@subsubsection Inlining of Subprograms
@item
The called subprogram is suitable for inlining: it must be small enough
-and not contain something that the backend cannot support in inlined
+and not contain something that the back end cannot support in inlined
subprograms.
@geindex pragma Inline
@item
The called subprogram is suitable for inlining: It must be small enough
-and not contain something that the backend cannot support in inlined
+and not contain something that the back end cannot support in inlined
subprograms.
@item
enough, but now @code{Main} depends on the body of @code{R} in
@code{r.adb} as well as on the spec. This means that if this body is edited,
the main program must be recompiled. Note that this extra dependency
-occurs whether or not the call is in fact inlined by the backend.
+occurs whether or not the call is in fact inlined by the back end.
The use of front end inlining with @code{-gnatN} generates similar
additional dependencies.
@geindex -fno-inline (gcc)
-Note: The @code{-fno-inline} switch overrides all other conditions and ensures that
-no inlining occurs, unless requested with pragma Inline_Always for most
-back-ends. The extra dependences resulting from @code{-gnatn} will still be active,
-even if this switch is used to suppress the resulting inlining actions.
+Note: The @code{-fno-inline} switch overrides all other conditions
+and ensures that no inlining occurs, unless requested with pragma
+Inline_Always for most back ends. The extra dependences resulting from
+@code{-gnatn} will still be active, even if this switch is used to
+suppress the resulting inlining actions.
@geindex -fno-inline-functions (gcc)
-For the GCC backend, you can use the
+For the GCC back end, you can use the
@code{-fno-inline-functions} switch to prevent automatic inlining
of subprograms if you use @code{-O3}.
@geindex -fno-inline-small-functions (gcc)
-For the GCC backend, you can use the
+For the GCC back end, you can use the
@code{-fno-inline-small-functions} switch to prevent automatic
inlining of small subprograms if you use @code{-O2}.
@geindex -fno-inline-functions-called-once (gcc)
-For the GC backend, you can use the
+For the GC back end, you can use the
@code{-fno-inline-functions-called-once} switch to prevent inlining
of subprograms local to the unit and called once from within it if you
use @code{-O1}.
improves performance for your program.
@node Floating Point Operations,Vectorization of loops,Inlining of Subprograms,Performance Considerations
-@anchor{gnat_ugn/gnat_and_program_execution floating-point-operations}@anchor{189}@anchor{gnat_ugn/gnat_and_program_execution id33}@anchor{18a}
+@anchor{gnat_ugn/gnat_and_program_execution floating-point-operations}@anchor{18b}@anchor{gnat_ugn/gnat_and_program_execution id33}@anchor{18c}
@subsubsection Floating Point Operations
so you can mix units compiled with and without these switches.
@node Vectorization of loops,Other Optimization Switches,Floating Point Operations,Performance Considerations
-@anchor{gnat_ugn/gnat_and_program_execution id34}@anchor{18b}@anchor{gnat_ugn/gnat_and_program_execution vectorization-of-loops}@anchor{18c}
+@anchor{gnat_ugn/gnat_and_program_execution id34}@anchor{18d}@anchor{gnat_ugn/gnat_and_program_execution vectorization-of-loops}@anchor{18e}
@subsubsection Vectorization of loops
@geindex Optimization Switches
-The GCC and LLVM backends have an auto-vectorizer that’s enabled by
-default at some optimization levels. For the GCC backend, it’s
+The GCC and LLVM back ends have an auto-vectorizer that’s enabled by
+default at some optimization levels. For the GCC back end, it’s
enabled by default at @code{-O3} and you can request it at other
-levels with @code{-ftree-vectorize}. For the LLVM backend, it’s
+levels with @code{-ftree-vectorize}. For the LLVM back end, it’s
enabled by default at lower levels, but you can explicitly enable or
disable it with the @code{-fno-vectorize}, @code{-fvectorize},
@code{-fno-slp-vectorize}, and @code{-fslp-vectorize} switches.
placed immediately within the loop will convey the appropriate hint to the
compiler for this loop. This is currently only supported for the GCC
-backend.
+back end.
You can also help the compiler generate better vectorized code
for a given loop by asserting that there are no loop-carried dependencies
placed immediately within the loop will tell the compiler that it can safely
omit the non-vectorized version of the loop as well as the run-time test.
-This is also currently only supported by the GCC backend.
+This is also currently only supported by the GCC back end.
@node Other Optimization Switches,Optimization and Strict Aliasing,Vectorization of loops,Performance Considerations
-@anchor{gnat_ugn/gnat_and_program_execution id35}@anchor{18d}@anchor{gnat_ugn/gnat_and_program_execution other-optimization-switches}@anchor{18e}
+@anchor{gnat_ugn/gnat_and_program_execution id35}@anchor{18f}@anchor{gnat_ugn/gnat_and_program_execution other-optimization-switches}@anchor{190}
@subsubsection Other Optimization Switches
@geindex Optimization Switches
You can also use any specialized optimization switches supported by
-the backend being used. These switches have not been extensively
+the back end being used. These switches have not been extensively
tested with GNAT but can generally be expected to work. Examples of
-switches in this category for the GCC backend are
+switches in this category for the GCC back end are
@code{-funroll-loops} and the various target-specific @code{-m}
options (in particular, it has been observed that @code{-march=xxx}
can significantly improve performance on appropriate machines). For
the `Hardware Models and Configurations' chapter of @cite{Using the GNU Compiler Collection (GCC)}.
@node Optimization and Strict Aliasing,Aliased Variables and Optimization,Other Optimization Switches,Performance Considerations
-@anchor{gnat_ugn/gnat_and_program_execution id36}@anchor{18f}@anchor{gnat_ugn/gnat_and_program_execution optimization-and-strict-aliasing}@anchor{e6}
+@anchor{gnat_ugn/gnat_and_program_execution id36}@anchor{191}@anchor{gnat_ugn/gnat_and_program_execution optimization-and-strict-aliasing}@anchor{e7}
@subsubsection Optimization and Strict Aliasing
This kind of optimizations, based on strict type-based aliasing, is
triggered by specifying an optimization level of @code{-O2} or
-higher (or @code{-Os}) for the GCC backend and @code{-O1} or higher for the
-LLVM backend and allows the compiler to generate more
+higher (or @code{-Os}) for the GCC back end and @code{-O1} or
+higher for the LLVM back end and allows the compiler to generate more
efficient code.
-However, although this optimization is always correct in terms of
-the formal semantics of the Ada Reference Manual, you can run into difficulties
-arise if you use features like @code{Unchecked_Conversion} to break
-the typing system. Consider the following complete program example:
+However, although this optimization is always correct in terms of the
+formal semantics of the Ada Reference Manual, you can run into
+difficulties arise if you use features like @code{Unchecked_Conversion}
+to break the typing system. Consider the following complete program
+example:
@quotation
scale application code where the execution time is increased by up to
5% when these optimizations are turned off. However, if you have code
that make significant use of unchecked conversion, you might want to
-just stick with @code{-O1} (with the GCC backend) and avoid the
+just stick with @code{-O1} (with the GCC back end) and avoid the
entire issue. If you get adequate performance at this level of
optimization, that’s probably the safest approach. If tests show that
you really need higher levels of optimization, then you can experiment
getting the warnings described above.
@node Aliased Variables and Optimization,Atomic Variables and Optimization,Optimization and Strict Aliasing,Performance Considerations
-@anchor{gnat_ugn/gnat_and_program_execution aliased-variables-and-optimization}@anchor{190}@anchor{gnat_ugn/gnat_and_program_execution id37}@anchor{191}
+@anchor{gnat_ugn/gnat_and_program_execution aliased-variables-and-optimization}@anchor{192}@anchor{gnat_ugn/gnat_and_program_execution id37}@anchor{193}
@subsubsection Aliased Variables and Optimization
functin as you expect with all compilers.
@node Atomic Variables and Optimization,Passive Task Optimization,Aliased Variables and Optimization,Performance Considerations
-@anchor{gnat_ugn/gnat_and_program_execution atomic-variables-and-optimization}@anchor{192}@anchor{gnat_ugn/gnat_and_program_execution id38}@anchor{193}
+@anchor{gnat_ugn/gnat_and_program_execution atomic-variables-and-optimization}@anchor{194}@anchor{gnat_ugn/gnat_and_program_execution id38}@anchor{195}
@subsubsection Atomic Variables and Optimization
useful to disable it.
@node Passive Task Optimization,,Atomic Variables and Optimization,Performance Considerations
-@anchor{gnat_ugn/gnat_and_program_execution id39}@anchor{194}@anchor{gnat_ugn/gnat_and_program_execution passive-task-optimization}@anchor{195}
+@anchor{gnat_ugn/gnat_and_program_execution id39}@anchor{196}@anchor{gnat_ugn/gnat_and_program_execution passive-task-optimization}@anchor{197}
@subsubsection Passive Task Optimization
to be modified, only the task definitions themselves.
@node Text_IO Suggestions,Reducing Size of Executables with Unused Subprogram/Data Elimination,Performance Considerations,Improving Performance
-@anchor{gnat_ugn/gnat_and_program_execution id40}@anchor{196}@anchor{gnat_ugn/gnat_and_program_execution text-io-suggestions}@anchor{197}
+@anchor{gnat_ugn/gnat_and_program_execution id40}@anchor{198}@anchor{gnat_ugn/gnat_and_program_execution text-io-suggestions}@anchor{199}
@subsection @code{Text_IO} Suggestions
be buffered using @code{Interfaces.C_Streams.setvbuf}.
@node Reducing Size of Executables with Unused Subprogram/Data Elimination,,Text_IO Suggestions,Improving Performance
-@anchor{gnat_ugn/gnat_and_program_execution id41}@anchor{198}@anchor{gnat_ugn/gnat_and_program_execution reducing-size-of-executables-with-unused-subprogram-data-elimination}@anchor{199}
+@anchor{gnat_ugn/gnat_and_program_execution id41}@anchor{19a}@anchor{gnat_ugn/gnat_and_program_execution reducing-size-of-executables-with-unused-subprogram-data-elimination}@anchor{19b}
@subsection Reducing Size of Executables with Unused Subprogram/Data Elimination
@end menu
@node About unused subprogram/data elimination,Compilation options,,Reducing Size of Executables with Unused Subprogram/Data Elimination
-@anchor{gnat_ugn/gnat_and_program_execution about-unused-subprogram-data-elimination}@anchor{19a}@anchor{gnat_ugn/gnat_and_program_execution id42}@anchor{19b}
+@anchor{gnat_ugn/gnat_and_program_execution about-unused-subprogram-data-elimination}@anchor{19c}@anchor{gnat_ugn/gnat_and_program_execution id42}@anchor{19d}
@subsubsection About unused subprogram/data elimination
In both cases, GNU binutils version 2.16 or later are required to enable it.
@node Compilation options,Example of unused subprogram/data elimination,About unused subprogram/data elimination,Reducing Size of Executables with Unused Subprogram/Data Elimination
-@anchor{gnat_ugn/gnat_and_program_execution compilation-options}@anchor{19c}@anchor{gnat_ugn/gnat_and_program_execution id43}@anchor{19d}
+@anchor{gnat_ugn/gnat_and_program_execution compilation-options}@anchor{19e}@anchor{gnat_ugn/gnat_and_program_execution id43}@anchor{19f}
@subsubsection Compilation options
@geindex -fdata-sections (gcc)
In order to do this, it has to work with objects compiled with the
-following switches passed to the GCC backend:
+following switches passed to the GCC back end:
@code{-ffunction-sections} @code{-fdata-sections}.
These options are usable with C and Ada files.
executable.
@node Example of unused subprogram/data elimination,,Compilation options,Reducing Size of Executables with Unused Subprogram/Data Elimination
-@anchor{gnat_ugn/gnat_and_program_execution example-of-unused-subprogram-data-elimination}@anchor{19e}@anchor{gnat_ugn/gnat_and_program_execution id44}@anchor{19f}
+@anchor{gnat_ugn/gnat_and_program_execution example-of-unused-subprogram-data-elimination}@anchor{1a0}@anchor{gnat_ugn/gnat_and_program_execution id44}@anchor{1a1}
@subsubsection Example of unused subprogram/data elimination
@geindex Checks (overflow)
@node Overflow Check Handling in GNAT,Performing Dimensionality Analysis in GNAT,Improving Performance,GNAT and Program Execution
-@anchor{gnat_ugn/gnat_and_program_execution id45}@anchor{14c}@anchor{gnat_ugn/gnat_and_program_execution overflow-check-handling-in-gnat}@anchor{1a0}
+@anchor{gnat_ugn/gnat_and_program_execution id45}@anchor{14e}@anchor{gnat_ugn/gnat_and_program_execution overflow-check-handling-in-gnat}@anchor{1a2}
@section Overflow Check Handling in GNAT
@end menu
@node Background,Management of Overflows in GNAT,,Overflow Check Handling in GNAT
-@anchor{gnat_ugn/gnat_and_program_execution background}@anchor{1a1}@anchor{gnat_ugn/gnat_and_program_execution id46}@anchor{1a2}
+@anchor{gnat_ugn/gnat_and_program_execution background}@anchor{1a3}@anchor{gnat_ugn/gnat_and_program_execution id46}@anchor{1a4}
@subsection Background
would prefer this precondition to be considered @code{True} at run time).
@node Management of Overflows in GNAT,Specifying the Desired Mode,Background,Overflow Check Handling in GNAT
-@anchor{gnat_ugn/gnat_and_program_execution id47}@anchor{1a3}@anchor{gnat_ugn/gnat_and_program_execution management-of-overflows-in-gnat}@anchor{1a4}
+@anchor{gnat_ugn/gnat_and_program_execution id47}@anchor{1a5}@anchor{gnat_ugn/gnat_and_program_execution management-of-overflows-in-gnat}@anchor{1a6}
@subsection Management of Overflows in GNAT
range checks).
@node Specifying the Desired Mode,Default Settings,Management of Overflows in GNAT,Overflow Check Handling in GNAT
-@anchor{gnat_ugn/gnat_and_program_execution id48}@anchor{1a5}@anchor{gnat_ugn/gnat_and_program_execution specifying-the-desired-mode}@anchor{eb}
+@anchor{gnat_ugn/gnat_and_program_execution id48}@anchor{1a7}@anchor{gnat_ugn/gnat_and_program_execution specifying-the-desired-mode}@anchor{ec}
@subsection Specifying the Desired Mode
to be computed using the base type (@code{STRICT} mode).
@node Default Settings,Implementation Notes,Specifying the Desired Mode,Overflow Check Handling in GNAT
-@anchor{gnat_ugn/gnat_and_program_execution default-settings}@anchor{1a6}@anchor{gnat_ugn/gnat_and_program_execution id49}@anchor{1a7}
+@anchor{gnat_ugn/gnat_and_program_execution default-settings}@anchor{1a8}@anchor{gnat_ugn/gnat_and_program_execution id49}@anchor{1a9}
@subsection Default Settings
intermediate results.
@node Implementation Notes,,Default Settings,Overflow Check Handling in GNAT
-@anchor{gnat_ugn/gnat_and_program_execution id50}@anchor{1a8}@anchor{gnat_ugn/gnat_and_program_execution implementation-notes}@anchor{1a9}
+@anchor{gnat_ugn/gnat_and_program_execution id50}@anchor{1aa}@anchor{gnat_ugn/gnat_and_program_execution implementation-notes}@anchor{1ab}
@subsection Implementation Notes
platforms).
@node Performing Dimensionality Analysis in GNAT,Stack Related Facilities,Overflow Check Handling in GNAT,GNAT and Program Execution
-@anchor{gnat_ugn/gnat_and_program_execution id51}@anchor{14d}@anchor{gnat_ugn/gnat_and_program_execution performing-dimensionality-analysis-in-gnat}@anchor{1aa}
+@anchor{gnat_ugn/gnat_and_program_execution id51}@anchor{14f}@anchor{gnat_ugn/gnat_and_program_execution performing-dimensionality-analysis-in-gnat}@anchor{1ac}
@section Performing Dimensionality Analysis in GNAT
@end quotation
@node Stack Related Facilities,Memory Management Issues,Performing Dimensionality Analysis in GNAT,GNAT and Program Execution
-@anchor{gnat_ugn/gnat_and_program_execution id52}@anchor{14e}@anchor{gnat_ugn/gnat_and_program_execution stack-related-facilities}@anchor{1ab}
+@anchor{gnat_ugn/gnat_and_program_execution id52}@anchor{150}@anchor{gnat_ugn/gnat_and_program_execution stack-related-facilities}@anchor{1ad}
@section Stack Related Facilities
@end menu
@node Stack Overflow Checking,Static Stack Usage Analysis,,Stack Related Facilities
-@anchor{gnat_ugn/gnat_and_program_execution id53}@anchor{1ac}@anchor{gnat_ugn/gnat_and_program_execution stack-overflow-checking}@anchor{e7}
+@anchor{gnat_ugn/gnat_and_program_execution id53}@anchor{1ae}@anchor{gnat_ugn/gnat_and_program_execution stack-overflow-checking}@anchor{e8}
@subsection Stack Overflow Checking
For declared tasks, the default stack size is defined by the GNAT runtime,
whose size may be modified at bind time through the @code{-d} bind switch
-(@ref{113,,Switches for gnatbind}). You can set task specific stack sizes using the
+(@ref{114,,Switches for gnatbind}). You can set task specific stack sizes using the
@code{Storage_Size} pragma.
For the environment task, the stack size is determined by the operating system.
Consequently, to modify the size of the environment task please refer to your
operating system documentation.
-When using the LLVM backend, this switch doesn’t perform full stack overflow
+When using the LLVM back end, this switch doesn’t perform full stack overflow
checking, but just checks for very large local dynamic allocations.
@node Static Stack Usage Analysis,Dynamic Stack Usage Analysis,Stack Overflow Checking,Stack Related Facilities
-@anchor{gnat_ugn/gnat_and_program_execution id54}@anchor{1ad}@anchor{gnat_ugn/gnat_and_program_execution static-stack-usage-analysis}@anchor{e8}
+@anchor{gnat_ugn/gnat_and_program_execution id54}@anchor{1af}@anchor{gnat_ugn/gnat_and_program_execution static-stack-usage-analysis}@anchor{e9}
@subsection Static Stack Usage Analysis
than the specified amount of bytes. The wording of that warning is
consistent with that in the file documented above.
-This is not supported by the LLVM backend.
+This is not supported by the LLVM back end.
@node Dynamic Stack Usage Analysis,,Static Stack Usage Analysis,Stack Related Facilities
-@anchor{gnat_ugn/gnat_and_program_execution dynamic-stack-usage-analysis}@anchor{116}@anchor{gnat_ugn/gnat_and_program_execution id55}@anchor{1ae}
+@anchor{gnat_ugn/gnat_and_program_execution dynamic-stack-usage-analysis}@anchor{117}@anchor{gnat_ugn/gnat_and_program_execution id55}@anchor{1b0}
@subsection Dynamic Stack Usage Analysis
would specify to the analyzer that the environment task stack has a limit
of 1.6 megabytes. Any stack usage beyond this will be ignored by the analysis.
-This is not suppored by the LLVM backend.
+This is not suppored by the LLVM back end.
The package @code{GNAT.Task_Stack_Usage} provides facilities to get
stack-usage reports at run time. See its body for the details.
@node Memory Management Issues,,Stack Related Facilities,GNAT and Program Execution
-@anchor{gnat_ugn/gnat_and_program_execution id56}@anchor{14f}@anchor{gnat_ugn/gnat_and_program_execution memory-management-issues}@anchor{1af}
+@anchor{gnat_ugn/gnat_and_program_execution id56}@anchor{151}@anchor{gnat_ugn/gnat_and_program_execution memory-management-issues}@anchor{1b1}
@section Memory Management Issues
@end menu
@node Some Useful Memory Pools,The GNAT Debug Pool Facility,,Memory Management Issues
-@anchor{gnat_ugn/gnat_and_program_execution id57}@anchor{1b0}@anchor{gnat_ugn/gnat_and_program_execution some-useful-memory-pools}@anchor{1b1}
+@anchor{gnat_ugn/gnat_and_program_execution id57}@anchor{1b2}@anchor{gnat_ugn/gnat_and_program_execution some-useful-memory-pools}@anchor{1b3}
@subsection Some Useful Memory Pools
@end quotation
@node The GNAT Debug Pool Facility,,Some Useful Memory Pools,Memory Management Issues
-@anchor{gnat_ugn/gnat_and_program_execution id58}@anchor{1b2}@anchor{gnat_ugn/gnat_and_program_execution the-gnat-debug-pool-facility}@anchor{1b3}
+@anchor{gnat_ugn/gnat_and_program_execution id58}@anchor{1b4}@anchor{gnat_ugn/gnat_and_program_execution the-gnat-debug-pool-facility}@anchor{1b5}
@subsection The GNAT Debug Pool Facility
@c -- E.g. Ada |nbsp| 95
@node Platform-Specific Information,Example of Binder Output File,GNAT and Program Execution,Top
-@anchor{gnat_ugn/platform_specific_information doc}@anchor{1b4}@anchor{gnat_ugn/platform_specific_information id1}@anchor{1b5}@anchor{gnat_ugn/platform_specific_information platform-specific-information}@anchor{d}
+@anchor{gnat_ugn/platform_specific_information doc}@anchor{1b6}@anchor{gnat_ugn/platform_specific_information id1}@anchor{1b7}@anchor{gnat_ugn/platform_specific_information platform-specific-information}@anchor{e}
@chapter Platform-Specific Information
@end menu
@node Run-Time Libraries,Specifying a Run-Time Library,,Platform-Specific Information
-@anchor{gnat_ugn/platform_specific_information id2}@anchor{1b6}@anchor{gnat_ugn/platform_specific_information run-time-libraries}@anchor{1b7}
+@anchor{gnat_ugn/platform_specific_information id2}@anchor{1b8}@anchor{gnat_ugn/platform_specific_information run-time-libraries}@anchor{1b9}
@section Run-Time Libraries
@end menu
@node Summary of Run-Time Configurations,,,Run-Time Libraries
-@anchor{gnat_ugn/platform_specific_information id3}@anchor{1b8}@anchor{gnat_ugn/platform_specific_information summary-of-run-time-configurations}@anchor{1b9}
+@anchor{gnat_ugn/platform_specific_information id3}@anchor{1ba}@anchor{gnat_ugn/platform_specific_information summary-of-run-time-configurations}@anchor{1bb}
@subsection Summary of Run-Time Configurations
@node Specifying a Run-Time Library,GNU/Linux Topics,Run-Time Libraries,Platform-Specific Information
-@anchor{gnat_ugn/platform_specific_information id4}@anchor{1ba}@anchor{gnat_ugn/platform_specific_information specifying-a-run-time-library}@anchor{1bb}
+@anchor{gnat_ugn/platform_specific_information id4}@anchor{1bc}@anchor{gnat_ugn/platform_specific_information specifying-a-run-time-library}@anchor{1bd}
@section Specifying a Run-Time Library
@geindex GNU/Linux
@node GNU/Linux Topics,Microsoft Windows Topics,Specifying a Run-Time Library,Platform-Specific Information
-@anchor{gnat_ugn/platform_specific_information gnu-linux-topics}@anchor{1bc}@anchor{gnat_ugn/platform_specific_information id5}@anchor{1bd}
+@anchor{gnat_ugn/platform_specific_information gnu-linux-topics}@anchor{1be}@anchor{gnat_ugn/platform_specific_information id5}@anchor{1bf}
@section GNU/Linux Topics
@end menu
@node Required Packages on GNU/Linux,Position Independent Executable PIE Enabled by Default on Linux,,GNU/Linux Topics
-@anchor{gnat_ugn/platform_specific_information id6}@anchor{1be}@anchor{gnat_ugn/platform_specific_information required-packages-on-gnu-linux}@anchor{1bf}
+@anchor{gnat_ugn/platform_specific_information id6}@anchor{1c0}@anchor{gnat_ugn/platform_specific_information required-packages-on-gnu-linux}@anchor{1c1}
@subsection Required Packages on GNU/Linux
for those packages.
@node Position Independent Executable PIE Enabled by Default on Linux,Choosing the Scheduling Policy with GNU/Linux,Required Packages on GNU/Linux,GNU/Linux Topics
-@anchor{gnat_ugn/platform_specific_information pie-enabled-by-default-on-linux}@anchor{1c0}@anchor{gnat_ugn/platform_specific_information position-independent-executable-pie-enabled-by-default-on-linux}@anchor{1c1}
+@anchor{gnat_ugn/platform_specific_information pie-enabled-by-default-on-linux}@anchor{1c2}@anchor{gnat_ugn/platform_specific_information position-independent-executable-pie-enabled-by-default-on-linux}@anchor{1c3}
@subsection Position Independent Executable (PIE) Enabled by Default on Linux
@geindex SCHED_RR scheduling policy
@geindex SCHED_OTHER scheduling policy
-@anchor{gnat_ugn/platform_specific_information choosing-the-scheduling-policy-with-gnu-linux}@anchor{1c2}
+@anchor{gnat_ugn/platform_specific_information choosing-the-scheduling-policy-with-gnu-linux}@anchor{1c4}
@node Choosing the Scheduling Policy with GNU/Linux,A GNU/Linux Debug Quirk,Position Independent Executable PIE Enabled by Default on Linux,GNU/Linux Topics
-@anchor{gnat_ugn/platform_specific_information id7}@anchor{1c3}
+@anchor{gnat_ugn/platform_specific_information id7}@anchor{1c5}
@subsection Choosing the Scheduling Policy with GNU/Linux
have sufficient priviledge for running the container image.
@node A GNU/Linux Debug Quirk,,Choosing the Scheduling Policy with GNU/Linux,GNU/Linux Topics
-@anchor{gnat_ugn/platform_specific_information a-gnu-linux-debug-quirk}@anchor{1c4}@anchor{gnat_ugn/platform_specific_information id8}@anchor{1c5}
+@anchor{gnat_ugn/platform_specific_information a-gnu-linux-debug-quirk}@anchor{1c6}@anchor{gnat_ugn/platform_specific_information id8}@anchor{1c7}
@subsection A GNU/Linux Debug Quirk
@geindex Windows
@node Microsoft Windows Topics,Mac OS Topics,GNU/Linux Topics,Platform-Specific Information
-@anchor{gnat_ugn/platform_specific_information id9}@anchor{1c6}@anchor{gnat_ugn/platform_specific_information microsoft-windows-topics}@anchor{1c7}
+@anchor{gnat_ugn/platform_specific_information id9}@anchor{1c8}@anchor{gnat_ugn/platform_specific_information microsoft-windows-topics}@anchor{1c9}
@section Microsoft Windows Topics
@end menu
@node Using GNAT on Windows,Using a network installation of GNAT,,Microsoft Windows Topics
-@anchor{gnat_ugn/platform_specific_information id10}@anchor{1c8}@anchor{gnat_ugn/platform_specific_information using-gnat-on-windows}@anchor{1c9}
+@anchor{gnat_ugn/platform_specific_information id10}@anchor{1ca}@anchor{gnat_ugn/platform_specific_information using-gnat-on-windows}@anchor{1cb}
@subsection Using GNAT on Windows
@end itemize
@node Using a network installation of GNAT,CONSOLE and WINDOWS subsystems,Using GNAT on Windows,Microsoft Windows Topics
-@anchor{gnat_ugn/platform_specific_information id11}@anchor{1ca}@anchor{gnat_ugn/platform_specific_information using-a-network-installation-of-gnat}@anchor{1cb}
+@anchor{gnat_ugn/platform_specific_information id11}@anchor{1cc}@anchor{gnat_ugn/platform_specific_information using-a-network-installation-of-gnat}@anchor{1cd}
@subsection Using a network installation of GNAT
a serious performance penalty.
@node CONSOLE and WINDOWS subsystems,Temporary Files,Using a network installation of GNAT,Microsoft Windows Topics
-@anchor{gnat_ugn/platform_specific_information console-and-windows-subsystems}@anchor{1cc}@anchor{gnat_ugn/platform_specific_information id12}@anchor{1cd}
+@anchor{gnat_ugn/platform_specific_information console-and-windows-subsystems}@anchor{1ce}@anchor{gnat_ugn/platform_specific_information id12}@anchor{1cf}
@subsection CONSOLE and WINDOWS subsystems
@end quotation
@node Temporary Files,Disabling Command Line Argument Expansion,CONSOLE and WINDOWS subsystems,Microsoft Windows Topics
-@anchor{gnat_ugn/platform_specific_information id13}@anchor{1ce}@anchor{gnat_ugn/platform_specific_information temporary-files}@anchor{1cf}
+@anchor{gnat_ugn/platform_specific_information id13}@anchor{1d0}@anchor{gnat_ugn/platform_specific_information temporary-files}@anchor{1d1}
@subsection Temporary Files
directories.
@node Disabling Command Line Argument Expansion,Choosing the Scheduling Policy with Windows,Temporary Files,Microsoft Windows Topics
-@anchor{gnat_ugn/platform_specific_information disabling-command-line-argument-expansion}@anchor{1d0}
+@anchor{gnat_ugn/platform_specific_information disabling-command-line-argument-expansion}@anchor{1d2}
@subsection Disabling Command Line Argument Expansion
@end example
@node Choosing the Scheduling Policy with Windows,Windows Socket Timeouts,Disabling Command Line Argument Expansion,Microsoft Windows Topics
-@anchor{gnat_ugn/platform_specific_information choosing-the-scheduling-policy-with-windows}@anchor{1d1}@anchor{gnat_ugn/platform_specific_information id14}@anchor{1d2}
+@anchor{gnat_ugn/platform_specific_information choosing-the-scheduling-policy-with-windows}@anchor{1d3}@anchor{gnat_ugn/platform_specific_information id14}@anchor{1d4}
@subsection Choosing the Scheduling Policy with Windows
refer to Microsoft documentation.
@node Windows Socket Timeouts,Mixed-Language Programming on Windows,Choosing the Scheduling Policy with Windows,Microsoft Windows Topics
-@anchor{gnat_ugn/platform_specific_information windows-socket-timeouts}@anchor{1d3}
+@anchor{gnat_ugn/platform_specific_information windows-socket-timeouts}@anchor{1d5}
@subsection Windows Socket Timeouts
operations.
@node Mixed-Language Programming on Windows,Windows Specific Add-Ons,Windows Socket Timeouts,Microsoft Windows Topics
-@anchor{gnat_ugn/platform_specific_information id15}@anchor{1d4}@anchor{gnat_ugn/platform_specific_information mixed-language-programming-on-windows}@anchor{1d5}
+@anchor{gnat_ugn/platform_specific_information id15}@anchor{1d6}@anchor{gnat_ugn/platform_specific_information mixed-language-programming-on-windows}@anchor{1d7}
@subsection Mixed-Language Programming on Windows
You can encapsulate your C++ code in a DLL to be linked with your Ada
application. In this case, use the Microsoft or other environment to
build the DLL and use GNAT to build your executable
-(@ref{1d6,,Using DLLs with GNAT}).
+(@ref{1d8,,Using DLLs with GNAT}).
@item
You can encapsulate your Ada code in a DLL to be linked with the
other part of your application. In this case, use GNAT to build the DLL
-(@ref{1d7,,Building DLLs with GNAT Project files}) and use the Microsoft
+(@ref{1d9,,Building DLLs with GNAT Project files}) and use the Microsoft
or other environment to build your executable.
@end itemize
In addition to the description about C @code{main} in
-@ref{2c,,Mixed Language Programming} section, if the C @code{main} uses a
+@ref{2d,,Mixed Language Programming} section, if the C @code{main} uses a
stand-alone library, it is required on x86-windows to
setup the SEH context. For this, the C @code{main} must looks like this:
@end menu
@node Windows Calling Conventions,Introduction to Dynamic Link Libraries DLLs,,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information id16}@anchor{1d8}@anchor{gnat_ugn/platform_specific_information windows-calling-conventions}@anchor{1d9}
+@anchor{gnat_ugn/platform_specific_information id16}@anchor{1da}@anchor{gnat_ugn/platform_specific_information windows-calling-conventions}@anchor{1db}
@subsubsection Windows Calling Conventions
@end menu
@node C Calling Convention,Stdcall Calling Convention,,Windows Calling Conventions
-@anchor{gnat_ugn/platform_specific_information c-calling-convention}@anchor{1da}@anchor{gnat_ugn/platform_specific_information id17}@anchor{1db}
+@anchor{gnat_ugn/platform_specific_information c-calling-convention}@anchor{1dc}@anchor{gnat_ugn/platform_specific_information id17}@anchor{1dd}
@subsubsection @code{C} Calling Convention
When importing a variable defined in C, you should always use the @code{C}
calling convention unless the object containing the variable is part of a
DLL (in which case you should use the @code{Stdcall} calling
-convention, @ref{1dc,,Stdcall Calling Convention}).
+convention, @ref{1de,,Stdcall Calling Convention}).
@node Stdcall Calling Convention,Win32 Calling Convention,C Calling Convention,Windows Calling Conventions
-@anchor{gnat_ugn/platform_specific_information id18}@anchor{1dd}@anchor{gnat_ugn/platform_specific_information stdcall-calling-convention}@anchor{1dc}
+@anchor{gnat_ugn/platform_specific_information id18}@anchor{1df}@anchor{gnat_ugn/platform_specific_information stdcall-calling-convention}@anchor{1de}
@subsubsection @code{Stdcall} Calling Convention
will be handled as a @code{C} calling convention on non-Windows platforms.
@node Win32 Calling Convention,DLL Calling Convention,Stdcall Calling Convention,Windows Calling Conventions
-@anchor{gnat_ugn/platform_specific_information id19}@anchor{1de}@anchor{gnat_ugn/platform_specific_information win32-calling-convention}@anchor{1df}
+@anchor{gnat_ugn/platform_specific_information id19}@anchor{1e0}@anchor{gnat_ugn/platform_specific_information win32-calling-convention}@anchor{1e1}
@subsubsection @code{Win32} Calling Convention
@code{Stdcall} calling convention described above.
@node DLL Calling Convention,,Win32 Calling Convention,Windows Calling Conventions
-@anchor{gnat_ugn/platform_specific_information dll-calling-convention}@anchor{1e0}@anchor{gnat_ugn/platform_specific_information id20}@anchor{1e1}
+@anchor{gnat_ugn/platform_specific_information dll-calling-convention}@anchor{1e2}@anchor{gnat_ugn/platform_specific_information id20}@anchor{1e3}
@subsubsection @code{DLL} Calling Convention
@code{Stdcall} calling convention described above.
@node Introduction to Dynamic Link Libraries DLLs,Using DLLs with GNAT,Windows Calling Conventions,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information id21}@anchor{1e2}@anchor{gnat_ugn/platform_specific_information introduction-to-dynamic-link-libraries-dlls}@anchor{1e3}
+@anchor{gnat_ugn/platform_specific_information id21}@anchor{1e4}@anchor{gnat_ugn/platform_specific_information introduction-to-dynamic-link-libraries-dlls}@anchor{1e5}
@subsubsection Introduction to Dynamic Link Libraries (DLLs)
Unix shared libraries is the fact that on most Unix systems all public
routines are exported by default in a Unix shared library, while under
Windows it is possible (but not required) to list exported routines in
-a definition file (see @ref{1e4,,The Definition File}).
+a definition file (see @ref{1e6,,The Definition File}).
@node Using DLLs with GNAT,Building DLLs with GNAT Project files,Introduction to Dynamic Link Libraries DLLs,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information id22}@anchor{1e5}@anchor{gnat_ugn/platform_specific_information using-dlls-with-gnat}@anchor{1d6}
+@anchor{gnat_ugn/platform_specific_information id22}@anchor{1e7}@anchor{gnat_ugn/platform_specific_information using-dlls-with-gnat}@anchor{1d8}
@subsubsection Using DLLs with GNAT
@end menu
@node Creating an Ada Spec for the DLL Services,Creating an Import Library,,Using DLLs with GNAT
-@anchor{gnat_ugn/platform_specific_information creating-an-ada-spec-for-the-dll-services}@anchor{1e6}@anchor{gnat_ugn/platform_specific_information id23}@anchor{1e7}
+@anchor{gnat_ugn/platform_specific_information creating-an-ada-spec-for-the-dll-services}@anchor{1e8}@anchor{gnat_ugn/platform_specific_information id23}@anchor{1e9}
@subsubsection Creating an Ada Spec for the DLL Services
@end quotation
@node Creating an Import Library,,Creating an Ada Spec for the DLL Services,Using DLLs with GNAT
-@anchor{gnat_ugn/platform_specific_information creating-an-import-library}@anchor{1e8}@anchor{gnat_ugn/platform_specific_information id24}@anchor{1e9}
+@anchor{gnat_ugn/platform_specific_information creating-an-import-library}@anchor{1ea}@anchor{gnat_ugn/platform_specific_information id24}@anchor{1eb}
@subsubsection Creating an Import Library
DLL. Otherwise read on.
@geindex Definition file
-@anchor{gnat_ugn/platform_specific_information the-definition-file}@anchor{1e4}
+@anchor{gnat_ugn/platform_specific_information the-definition-file}@anchor{1e6}
@subsubheading The Definition File
@end table
Note that you must specify the correct suffix (@code{@@@var{nn}})
-(see @ref{1d9,,Windows Calling Conventions}) for a Stdcall
+(see @ref{1db,,Windows Calling Conventions}) for a Stdcall
calling convention function in the exported symbols list.
There can actually be other sections in a definition file, but these
sections are not relevant to the discussion at hand.
-@anchor{gnat_ugn/platform_specific_information create-def-file-automatically}@anchor{1ea}
+@anchor{gnat_ugn/platform_specific_information create-def-file-automatically}@anchor{1ec}
@subsubheading Creating a Definition File Automatically
You can automatically create the definition file @code{API.def}
-(see @ref{1e4,,The Definition File}) from a DLL.
+(see @ref{1e6,,The Definition File}) from a DLL.
To do that, use the @code{dlltool} program as follows:
@quotation
@end example
Note that if some routines in the DLL have the @code{Stdcall} convention
-(@ref{1d9,,Windows Calling Conventions}) with stripped @code{@@@var{nn}}
+(@ref{1db,,Windows Calling Conventions}) with stripped @code{@@@var{nn}}
suffix then you’ll have to edit @code{api.def} to add it and specify
@code{-k} to @code{gnatdll} when creating the import library.
definition file and add the right suffix.
@end itemize
@end quotation
-@anchor{gnat_ugn/platform_specific_information gnat-style-import-library}@anchor{1eb}
+@anchor{gnat_ugn/platform_specific_information gnat-style-import-library}@anchor{1ed}
@subsubheading GNAT-Style Import Library
To create a static import library from @code{API.dll} with the GNAT tools,
you should create the @code{.def} file and use the @code{gnatdll} tool
-(see @ref{1ec,,Using gnatdll}) as follows:
+(see @ref{1ee,,Using gnatdll}) as follows:
@quotation
be @code{libxyz.a}. Note that in the previous example, the switch
@code{-e} could have been removed because the name of the definition
file (before the @code{.def} suffix) is the same as the name of the
-DLL (@ref{1ec,,Using gnatdll} for more information about @code{gnatdll}).
+DLL (@ref{1ee,,Using gnatdll} for more information about @code{gnatdll}).
@end quotation
-@anchor{gnat_ugn/platform_specific_information msvs-style-import-library}@anchor{1ed}
+@anchor{gnat_ugn/platform_specific_information msvs-style-import-library}@anchor{1ef}
@subsubheading Microsoft-Style Import Library
A Microsoft import library is needed only if you plan to make an
Ada DLL available to applications developed with Microsoft
-tools (@ref{1d5,,Mixed-Language Programming on Windows}).
+tools (@ref{1d7,,Mixed-Language Programming on Windows}).
To create a Microsoft-style import library for @code{API.dll} you
should create the @code{.def} file, then build the actual import library using
@end quotation
@node Building DLLs with GNAT Project files,Building DLLs with GNAT,Using DLLs with GNAT,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information building-dlls-with-gnat-project-files}@anchor{1d7}@anchor{gnat_ugn/platform_specific_information id25}@anchor{1ee}
+@anchor{gnat_ugn/platform_specific_information building-dlls-with-gnat-project-files}@anchor{1d9}@anchor{gnat_ugn/platform_specific_information id25}@anchor{1f0}
@subsubsection Building DLLs with GNAT Project files
of shared libraries, so you can’t have library level tasks in SALs.
@node Building DLLs with GNAT,Building DLLs with gnatdll,Building DLLs with GNAT Project files,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information building-dlls-with-gnat}@anchor{1ef}@anchor{gnat_ugn/platform_specific_information id26}@anchor{1f0}
+@anchor{gnat_ugn/platform_specific_information building-dlls-with-gnat}@anchor{1f1}@anchor{gnat_ugn/platform_specific_information id26}@anchor{1f2}
@subsubsection Building DLLs with GNAT
It’s important to note that in this case all symbols found in the
object files are automatically exported. You can restrict
the set of symbols to export by passing to @code{gcc} a definition
-file (see @ref{1e4,,The Definition File}).
+file (see @ref{1e6,,The Definition File}).
For example:
@example
@end quotation
@node Building DLLs with gnatdll,Ada DLLs and Finalization,Building DLLs with GNAT,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information building-dlls-with-gnatdll}@anchor{1f1}@anchor{gnat_ugn/platform_specific_information id27}@anchor{1f2}
+@anchor{gnat_ugn/platform_specific_information building-dlls-with-gnatdll}@anchor{1f3}@anchor{gnat_ugn/platform_specific_information id27}@anchor{1f4}
@subsubsection Building DLLs with gnatdll
@geindex building
Note that it is preferred to use GNAT Project files
-(@ref{1d7,,Building DLLs with GNAT Project files}) or the built-in GNAT
-DLL support (@ref{1ef,,Building DLLs with GNAT}) to build DLLs.
+(@ref{1d9,,Building DLLs with GNAT Project files}) or the built-in GNAT
+DLL support (@ref{1f1,,Building DLLs with GNAT}) to build DLLs.
This section explains how to build DLLs containing Ada code using
@code{gnatdll}. These DLLs will be referred to as Ada DLLs in the
You need to mark each Ada entity exported by the DLL with a @code{C} or
@code{Stdcall} calling convention to avoid any Ada name mangling for the
entities exported by the DLL
-(see @ref{1f3,,Exporting Ada Entities}). You can
+(see @ref{1f5,,Exporting Ada Entities}). You can
skip this step if you plan to use the Ada DLL only from Ada applications.
@item
Your Ada code must export an initialization routine which calls the routine
@code{adainit} (generated by @code{gnatbind}) to perform the elaboration of
-the Ada code in the DLL (@ref{1f4,,Ada DLLs and Elaboration}). The initialization
+the Ada code in the DLL (@ref{1f6,,Ada DLLs and Elaboration}). The initialization
routine exported by the Ada DLL must be invoked by the clients of the DLL
to initialize the DLL.
@item
When useful, the DLL should also export a finalization routine which calls
routine @code{adafinal} (also generated by @code{gnatbind}) to perform the
-finalization of the Ada code in the DLL (@ref{1f5,,Ada DLLs and Finalization}).
+finalization of the Ada code in the DLL (@ref{1f7,,Ada DLLs and Finalization}).
The finalization routine exported by the Ada DLL must be invoked by the
clients of the DLL when the DLL services are no further needed.
@item
You must provide a definition file listing the exported entities
-(@ref{1e4,,The Definition File}).
+(@ref{1e6,,The Definition File}).
@item
Finally, you must use @code{gnatdll} to produce the DLL and the import
-library (@ref{1ec,,Using gnatdll}).
+library (@ref{1ee,,Using gnatdll}).
@end itemize
Note that a relocatable DLL stripped using the @code{strip}
@end menu
@node Limitations When Using Ada DLLs from Ada,Exporting Ada Entities,,Building DLLs with gnatdll
-@anchor{gnat_ugn/platform_specific_information limitations-when-using-ada-dlls-from-ada}@anchor{1f6}
+@anchor{gnat_ugn/platform_specific_information limitations-when-using-ada-dlls-from-ada}@anchor{1f8}
@subsubsection Limitations When Using Ada DLLs from Ada
Windows object handles, etc.
@node Exporting Ada Entities,Ada DLLs and Elaboration,Limitations When Using Ada DLLs from Ada,Building DLLs with gnatdll
-@anchor{gnat_ugn/platform_specific_information exporting-ada-entities}@anchor{1f3}@anchor{gnat_ugn/platform_specific_information id28}@anchor{1f7}
+@anchor{gnat_ugn/platform_specific_information exporting-ada-entities}@anchor{1f5}@anchor{gnat_ugn/platform_specific_information id28}@anchor{1f9}
@subsubsection Exporting Ada Entities
Note that if you do not export the Ada entities with a @code{C} or
@code{Stdcall} convention, you will have to provide the mangled Ada names
in the definition file of the Ada DLL
-(@ref{1f8,,Creating the Definition File}).
+(@ref{1fa,,Creating the Definition File}).
@node Ada DLLs and Elaboration,,Exporting Ada Entities,Building DLLs with gnatdll
-@anchor{gnat_ugn/platform_specific_information ada-dlls-and-elaboration}@anchor{1f4}@anchor{gnat_ugn/platform_specific_information id29}@anchor{1f9}
+@anchor{gnat_ugn/platform_specific_information ada-dlls-and-elaboration}@anchor{1f6}@anchor{gnat_ugn/platform_specific_information id29}@anchor{1fb}
@subsubsection Ada DLLs and Elaboration
The DLL that you are building contains your Ada code as well as all the
routines in the Ada library that are needed by it. The first thing a
user of your DLL must do is elaborate the Ada code
-(@ref{f,,Elaboration Order Handling in GNAT}).
+(@ref{10,,Elaboration Order Handling in GNAT}).
To allow this, you must export an initialization routine
(@code{Initialize_API} in the previous example), which must be invoked
before using any of the DLL services. This elaboration routine must call
the Ada elaboration routine @code{adainit} generated by the GNAT binder
-(@ref{7e,,Binding with Non-Ada Main Programs}). See the body of
+(@ref{7f,,Binding with Non-Ada Main Programs}). See the body of
@code{Initialize_Api} for an example. Note that the GNAT binder is
automatically invoked during the DLL build process by the @code{gnatdll}
-tool (@ref{1ec,,Using gnatdll}).
+tool (@ref{1ee,,Using gnatdll}).
When a DLL is loaded, Windows systematically invokes a routine called
@code{DllMain}. It should therefore be possible to call @code{adainit}
newly created task to complete its initialization.
@node Ada DLLs and Finalization,Creating a Spec for Ada DLLs,Building DLLs with gnatdll,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information ada-dlls-and-finalization}@anchor{1f5}@anchor{gnat_ugn/platform_specific_information id30}@anchor{1fa}
+@anchor{gnat_ugn/platform_specific_information ada-dlls-and-finalization}@anchor{1f7}@anchor{gnat_ugn/platform_specific_information id30}@anchor{1fc}
@subsubsection Ada DLLs and Finalization
routine is in charge of releasing all resources acquired by the DLL. In the
case of the Ada code contained in the DLL, this is achieved by calling
routine @code{adafinal} generated by the GNAT binder
-(@ref{7e,,Binding with Non-Ada Main Programs}).
+(@ref{7f,,Binding with Non-Ada Main Programs}).
See the body of @code{Finalize_Api} for an
example. As already pointed out the GNAT binder is automatically invoked
during the DLL build process by the @code{gnatdll} tool
-(@ref{1ec,,Using gnatdll}).
+(@ref{1ee,,Using gnatdll}).
@node Creating a Spec for Ada DLLs,GNAT and Windows Resources,Ada DLLs and Finalization,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information creating-a-spec-for-ada-dlls}@anchor{1fb}@anchor{gnat_ugn/platform_specific_information id31}@anchor{1fc}
+@anchor{gnat_ugn/platform_specific_information creating-a-spec-for-ada-dlls}@anchor{1fd}@anchor{gnat_ugn/platform_specific_information id31}@anchor{1fe}
@subsubsection Creating a Spec for Ada DLLs
@end menu
@node Creating the Definition File,Using gnatdll,,Creating a Spec for Ada DLLs
-@anchor{gnat_ugn/platform_specific_information creating-the-definition-file}@anchor{1f8}@anchor{gnat_ugn/platform_specific_information id32}@anchor{1fd}
+@anchor{gnat_ugn/platform_specific_information creating-the-definition-file}@anchor{1fa}@anchor{gnat_ugn/platform_specific_information id32}@anchor{1ff}
@subsubsection Creating the Definition File
@end quotation
@node Using gnatdll,,Creating the Definition File,Creating a Spec for Ada DLLs
-@anchor{gnat_ugn/platform_specific_information id33}@anchor{1fe}@anchor{gnat_ugn/platform_specific_information using-gnatdll}@anchor{1ec}
+@anchor{gnat_ugn/platform_specific_information id33}@anchor{200}@anchor{gnat_ugn/platform_specific_information using-gnatdll}@anchor{1ee}
@subsubsection Using @code{gnatdll}
Direct @code{gnatdll} to search the @code{dir} directory for source and
object files needed to build the DLL.
-(@ref{73,,Search Paths and the Run-Time Library (RTL)}).
+(@ref{74,,Search Paths and the Run-Time Library (RTL)}).
@geindex -k (gnatdll)
is loaded into memory.
@item
-uses @code{dlltool} (see @ref{1ff,,Using dlltool}) to build the
+uses @code{dlltool} (see @ref{201,,Using dlltool}) to build the
export table (@code{api.exp}). The export table contains the relocation
information in a form which can be used during the final link to ensure
that the Windows loader is able to place the DLL anywhere in memory.
$ gnatlink api api.exp -o api.dll -mdll
@end example
@end itemize
-@anchor{gnat_ugn/platform_specific_information using-dlltool}@anchor{1ff}
+@anchor{gnat_ugn/platform_specific_information using-dlltool}@anchor{201}
@subsubheading Using @code{dlltool}
@item @code{-k}
Kill @code{@@@var{nn}} from exported names
-(@ref{1d9,,Windows Calling Conventions}
+(@ref{1db,,Windows Calling Conventions}
for a discussion about @code{Stdcall}-style symbols).
@end table
@end table
@node GNAT and Windows Resources,Using GNAT DLLs from Microsoft Visual Studio Applications,Creating a Spec for Ada DLLs,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information gnat-and-windows-resources}@anchor{200}@anchor{gnat_ugn/platform_specific_information id34}@anchor{201}
+@anchor{gnat_ugn/platform_specific_information gnat-and-windows-resources}@anchor{202}@anchor{gnat_ugn/platform_specific_information id34}@anchor{203}
@subsubsection GNAT and Windows Resources
@end menu
@node Building Resources,Compiling Resources,,GNAT and Windows Resources
-@anchor{gnat_ugn/platform_specific_information building-resources}@anchor{202}@anchor{gnat_ugn/platform_specific_information id35}@anchor{203}
+@anchor{gnat_ugn/platform_specific_information building-resources}@anchor{204}@anchor{gnat_ugn/platform_specific_information id35}@anchor{205}
@subsubsection Building Resources
the Microsoft documentation.
@node Compiling Resources,Using Resources,Building Resources,GNAT and Windows Resources
-@anchor{gnat_ugn/platform_specific_information compiling-resources}@anchor{204}@anchor{gnat_ugn/platform_specific_information id36}@anchor{205}
+@anchor{gnat_ugn/platform_specific_information compiling-resources}@anchor{206}@anchor{gnat_ugn/platform_specific_information id36}@anchor{207}
@subsubsection Compiling Resources
@end quotation
@node Using Resources,,Compiling Resources,GNAT and Windows Resources
-@anchor{gnat_ugn/platform_specific_information id37}@anchor{206}@anchor{gnat_ugn/platform_specific_information using-resources}@anchor{207}
+@anchor{gnat_ugn/platform_specific_information id37}@anchor{208}@anchor{gnat_ugn/platform_specific_information using-resources}@anchor{209}
@subsubsection Using Resources
@end quotation
@node Using GNAT DLLs from Microsoft Visual Studio Applications,Debugging a DLL,GNAT and Windows Resources,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information using-gnat-dll-from-msvs}@anchor{208}@anchor{gnat_ugn/platform_specific_information using-gnat-dlls-from-microsoft-visual-studio-applications}@anchor{209}
+@anchor{gnat_ugn/platform_specific_information using-gnat-dll-from-msvs}@anchor{20a}@anchor{gnat_ugn/platform_specific_information using-gnat-dlls-from-microsoft-visual-studio-applications}@anchor{20b}
@subsubsection Using GNAT DLLs from Microsoft Visual Studio Applications
@item
Produce a @code{.def} file for the symbols you need to interface
with, either by hand or automatically with possibly some manual
-adjustments (see @ref{1ea,,Creating Definition File Automatically}):
+adjustments (see @ref{1ec,,Creating Definition File Automatically}):
@end enumerate
@quotation
Make sure that MSVS command-line tools are accessible on the path.
@item
-Create the Microsoft-style import library (see @ref{1ed,,MSVS-Style Import Library}):
+Create the Microsoft-style import library (see @ref{1ef,,MSVS-Style Import Library}):
@end enumerate
@quotation
@end enumerate
@node Debugging a DLL,Setting Stack Size from gnatlink,Using GNAT DLLs from Microsoft Visual Studio Applications,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information debugging-a-dll}@anchor{20a}@anchor{gnat_ugn/platform_specific_information id38}@anchor{20b}
+@anchor{gnat_ugn/platform_specific_information debugging-a-dll}@anchor{20c}@anchor{gnat_ugn/platform_specific_information id38}@anchor{20d}
@subsubsection Debugging a DLL
@end menu
@node Program and DLL Both Built with GCC/GNAT,Program Built with Foreign Tools and DLL Built with GCC/GNAT,,Debugging a DLL
-@anchor{gnat_ugn/platform_specific_information id39}@anchor{20c}@anchor{gnat_ugn/platform_specific_information program-and-dll-both-built-with-gcc-gnat}@anchor{20d}
+@anchor{gnat_ugn/platform_specific_information id39}@anchor{20e}@anchor{gnat_ugn/platform_specific_information program-and-dll-both-built-with-gcc-gnat}@anchor{20f}
@subsubsection Program and DLL Both Built with GCC/GNAT
@code{ada_main} and in the DLL there’s an entry point named
@code{ada_dll}.
-The DLL (@ref{1e3,,Introduction to Dynamic Link Libraries (DLLs)}) and
+The DLL (@ref{1e5,,Introduction to Dynamic Link Libraries (DLLs)}) and
program must have been built with the debugging information (see the GNAT
@code{-g} switch). Here are the step-by-step instructions for debugging it:
At this stage, a breakpoint is set inside the DLL. From there on
you can use standard @code{GDB} commands to debug the whole program
-(@ref{150,,Running and Debugging Ada Programs}).
+(@ref{152,,Running and Debugging Ada Programs}).
@node Program Built with Foreign Tools and DLL Built with GCC/GNAT,,Program and DLL Both Built with GCC/GNAT,Debugging a DLL
-@anchor{gnat_ugn/platform_specific_information id40}@anchor{20e}@anchor{gnat_ugn/platform_specific_information program-built-with-foreign-tools-and-dll-built-with-gcc-gnat}@anchor{20f}
+@anchor{gnat_ugn/platform_specific_information id40}@anchor{210}@anchor{gnat_ugn/platform_specific_information program-built-with-foreign-tools-and-dll-built-with-gcc-gnat}@anchor{211}
@subsubsection Program Built with Foreign Tools and DLL Built with GCC/GNAT
there’s a DLL named @code{test.dll} containing an Ada entry point named
@code{ada_dll}.
-The DLL (see @ref{1e3,,Introduction to Dynamic Link Libraries (DLLs)}) must have
+The DLL (see @ref{1e5,,Introduction to Dynamic Link Libraries (DLLs)}) must have
been built with debugging information (see the GNAT @code{-g} switch).
@subsubheading Debugging the DLL Directly
This runs the program until it reaches the breakpoint that you’ve
set. From that point, you can use standard @code{GDB} commands to debug
a program as described in
-(@ref{150,,Running and Debugging Ada Programs}).
+(@ref{152,,Running and Debugging Ada Programs}).
@end itemize
You can also debug the DLL by attaching @code{GDB} to a running process.
This last step will resume the process execution and stop at
the breakpoint we have set. From there you can use standard
@code{GDB} commands to debug a program, as described in
-@ref{150,,Running and Debugging Ada Programs}.
+@ref{152,,Running and Debugging Ada Programs}.
@node Setting Stack Size from gnatlink,Setting Heap Size from gnatlink,Debugging a DLL,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information id41}@anchor{210}@anchor{gnat_ugn/platform_specific_information setting-stack-size-from-gnatlink}@anchor{12a}
+@anchor{gnat_ugn/platform_specific_information id41}@anchor{212}@anchor{gnat_ugn/platform_specific_information setting-stack-size-from-gnatlink}@anchor{12b}
@subsubsection Setting Stack Size from @code{gnatlink}
@end itemize
@node Setting Heap Size from gnatlink,,Setting Stack Size from gnatlink,Mixed-Language Programming on Windows
-@anchor{gnat_ugn/platform_specific_information id42}@anchor{211}@anchor{gnat_ugn/platform_specific_information setting-heap-size-from-gnatlink}@anchor{12b}
+@anchor{gnat_ugn/platform_specific_information id42}@anchor{213}@anchor{gnat_ugn/platform_specific_information setting-heap-size-from-gnatlink}@anchor{12c}
@subsubsection Setting Heap Size from @code{gnatlink}
@end itemize
@node Windows Specific Add-Ons,,Mixed-Language Programming on Windows,Microsoft Windows Topics
-@anchor{gnat_ugn/platform_specific_information win32-specific-addons}@anchor{212}@anchor{gnat_ugn/platform_specific_information windows-specific-add-ons}@anchor{213}
+@anchor{gnat_ugn/platform_specific_information win32-specific-addons}@anchor{214}@anchor{gnat_ugn/platform_specific_information windows-specific-add-ons}@anchor{215}
@subsection Windows Specific Add-Ons
@end menu
@node Win32Ada,wPOSIX,,Windows Specific Add-Ons
-@anchor{gnat_ugn/platform_specific_information id43}@anchor{214}@anchor{gnat_ugn/platform_specific_information win32ada}@anchor{215}
+@anchor{gnat_ugn/platform_specific_information id43}@anchor{216}@anchor{gnat_ugn/platform_specific_information win32ada}@anchor{217}
@subsubsection Win32Ada
@end quotation
@node wPOSIX,,Win32Ada,Windows Specific Add-Ons
-@anchor{gnat_ugn/platform_specific_information id44}@anchor{216}@anchor{gnat_ugn/platform_specific_information wposix}@anchor{217}
+@anchor{gnat_ugn/platform_specific_information id44}@anchor{218}@anchor{gnat_ugn/platform_specific_information wposix}@anchor{219}
@subsubsection wPOSIX
@end quotation
@node Mac OS Topics,,Microsoft Windows Topics,Platform-Specific Information
-@anchor{gnat_ugn/platform_specific_information id45}@anchor{218}@anchor{gnat_ugn/platform_specific_information mac-os-topics}@anchor{219}
+@anchor{gnat_ugn/platform_specific_information id45}@anchor{21a}@anchor{gnat_ugn/platform_specific_information mac-os-topics}@anchor{21b}
@section Mac OS Topics
@end menu
@node Codesigning the Debugger,,,Mac OS Topics
-@anchor{gnat_ugn/platform_specific_information codesigning-the-debugger}@anchor{21a}
+@anchor{gnat_ugn/platform_specific_information codesigning-the-debugger}@anchor{21c}
@subsection Codesigning the Debugger
group @code{_developer}.
@node Example of Binder Output File,Elaboration Order Handling in GNAT,Platform-Specific Information,Top
-@anchor{gnat_ugn/example_of_binder_output doc}@anchor{21b}@anchor{gnat_ugn/example_of_binder_output example-of-binder-output-file}@anchor{e}@anchor{gnat_ugn/example_of_binder_output id1}@anchor{21c}
+@anchor{gnat_ugn/example_of_binder_output doc}@anchor{21d}@anchor{gnat_ugn/example_of_binder_output example-of-binder-output-file}@anchor{f}@anchor{gnat_ugn/example_of_binder_output id1}@anchor{21e}
@chapter Example of Binder Output File
@c -- Example: A |withing| unit has a |with| clause, it |withs| a |withed| unit
@node Elaboration Order Handling in GNAT,Inline Assembler,Example of Binder Output File,Top
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat doc}@anchor{21d}@anchor{gnat_ugn/elaboration_order_handling_in_gnat elaboration-order-handling-in-gnat}@anchor{f}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id1}@anchor{21e}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat doc}@anchor{21f}@anchor{gnat_ugn/elaboration_order_handling_in_gnat elaboration-order-handling-in-gnat}@anchor{10}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id1}@anchor{220}
@chapter Elaboration Order Handling in GNAT
@end menu
@node Elaboration Code,Elaboration Order,,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat elaboration-code}@anchor{21f}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id2}@anchor{220}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat elaboration-code}@anchor{221}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id2}@anchor{222}
@section Elaboration Code
@end itemize
@node Elaboration Order,Checking the Elaboration Order,Elaboration Code,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat elaboration-order}@anchor{221}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id3}@anchor{222}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat elaboration-order}@anchor{223}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id3}@anchor{224}
@section Elaboration Order
respect to control and data flow.
@node Checking the Elaboration Order,Controlling the Elaboration Order in Ada,Elaboration Order,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat checking-the-elaboration-order}@anchor{223}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id4}@anchor{224}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat checking-the-elaboration-order}@anchor{225}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id4}@anchor{226}
@section Checking the Elaboration Order
@end itemize
@node Controlling the Elaboration Order in Ada,Controlling the Elaboration Order in GNAT,Checking the Elaboration Order,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat controlling-the-elaboration-order-in-ada}@anchor{225}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id5}@anchor{226}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat controlling-the-elaboration-order-in-ada}@anchor{227}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id5}@anchor{228}
@section Controlling the Elaboration Order in Ada
orders exist) even if maintenance changes the bodies of targets.
@node Controlling the Elaboration Order in GNAT,Mixing Elaboration Models,Controlling the Elaboration Order in Ada,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat controlling-the-elaboration-order-in-gnat}@anchor{227}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id6}@anchor{228}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat controlling-the-elaboration-order-in-gnat}@anchor{229}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id6}@anchor{22a}
@section Controlling the Elaboration Order in GNAT
install run-time checks.
@node Mixing Elaboration Models,ABE Diagnostics,Controlling the Elaboration Order in GNAT,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat id7}@anchor{229}@anchor{gnat_ugn/elaboration_order_handling_in_gnat mixing-elaboration-models}@anchor{22a}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat id7}@anchor{22b}@anchor{gnat_ugn/elaboration_order_handling_in_gnat mixing-elaboration-models}@anchor{22c}
@section Mixing Elaboration Models
You can suppress these warnings by specifying binder switch @code{-ws}.
@node ABE Diagnostics,SPARK Diagnostics,Mixing Elaboration Models,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat abe-diagnostics}@anchor{22b}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id8}@anchor{22c}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat abe-diagnostics}@anchor{22d}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id8}@anchor{22e}
@section ABE Diagnostics
elaborated at that point.
@node SPARK Diagnostics,Elaboration Circularities,ABE Diagnostics,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat id9}@anchor{22d}@anchor{gnat_ugn/elaboration_order_handling_in_gnat spark-diagnostics}@anchor{22e}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat id9}@anchor{22f}@anchor{gnat_ugn/elaboration_order_handling_in_gnat spark-diagnostics}@anchor{230}
@section SPARK Diagnostics
@end quotation
@node Elaboration Circularities,Resolving Elaboration Circularities,SPARK Diagnostics,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat elaboration-circularities}@anchor{22f}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id10}@anchor{230}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat elaboration-circularities}@anchor{231}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id10}@anchor{232}
@section Elaboration Circularities
@end itemize
@node Resolving Elaboration Circularities,Elaboration-related Compiler Switches,Elaboration Circularities,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat id11}@anchor{231}@anchor{gnat_ugn/elaboration_order_handling_in_gnat resolving-elaboration-circularities}@anchor{232}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat id11}@anchor{233}@anchor{gnat_ugn/elaboration_order_handling_in_gnat resolving-elaboration-circularities}@anchor{234}
@section Resolving Elaboration Circularities
@end itemize
@node Elaboration-related Compiler Switches,Summary of Procedures for Elaboration Control,Resolving Elaboration Circularities,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat elaboration-related-compiler-switches}@anchor{233}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id12}@anchor{234}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat elaboration-related-compiler-switches}@anchor{235}@anchor{gnat_ugn/elaboration_order_handling_in_gnat id12}@anchor{236}
@section Elaboration-related Compiler Switches
@end table
@node Summary of Procedures for Elaboration Control,Inspecting the Chosen Elaboration Order,Elaboration-related Compiler Switches,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat id13}@anchor{235}@anchor{gnat_ugn/elaboration_order_handling_in_gnat summary-of-procedures-for-elaboration-control}@anchor{236}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat id13}@anchor{237}@anchor{gnat_ugn/elaboration_order_handling_in_gnat summary-of-procedures-for-elaboration-control}@anchor{238}
@section Summary of Procedures for Elaboration Control
@end itemize
@node Inspecting the Chosen Elaboration Order,,Summary of Procedures for Elaboration Control,Elaboration Order Handling in GNAT
-@anchor{gnat_ugn/elaboration_order_handling_in_gnat id14}@anchor{237}@anchor{gnat_ugn/elaboration_order_handling_in_gnat inspecting-the-chosen-elaboration-order}@anchor{238}
+@anchor{gnat_ugn/elaboration_order_handling_in_gnat id14}@anchor{239}@anchor{gnat_ugn/elaboration_order_handling_in_gnat inspecting-the-chosen-elaboration-order}@anchor{23a}
@section Inspecting the Chosen Elaboration Order
@end quotation
@node Inline Assembler,GNU Free Documentation License,Elaboration Order Handling in GNAT,Top
-@anchor{gnat_ugn/inline_assembler doc}@anchor{239}@anchor{gnat_ugn/inline_assembler id1}@anchor{23a}@anchor{gnat_ugn/inline_assembler inline-assembler}@anchor{10}
+@anchor{gnat_ugn/inline_assembler doc}@anchor{23b}@anchor{gnat_ugn/inline_assembler id1}@anchor{23c}@anchor{gnat_ugn/inline_assembler inline-assembler}@anchor{11}
@chapter Inline Assembler
@end menu
@node Basic Assembler Syntax,A Simple Example of Inline Assembler,,Inline Assembler
-@anchor{gnat_ugn/inline_assembler basic-assembler-syntax}@anchor{23b}@anchor{gnat_ugn/inline_assembler id2}@anchor{23c}
+@anchor{gnat_ugn/inline_assembler basic-assembler-syntax}@anchor{23d}@anchor{gnat_ugn/inline_assembler id2}@anchor{23e}
@section Basic Assembler Syntax
@node A Simple Example of Inline Assembler,Output Variables in Inline Assembler,Basic Assembler Syntax,Inline Assembler
-@anchor{gnat_ugn/inline_assembler a-simple-example-of-inline-assembler}@anchor{23d}@anchor{gnat_ugn/inline_assembler id3}@anchor{23e}
+@anchor{gnat_ugn/inline_assembler a-simple-example-of-inline-assembler}@anchor{23f}@anchor{gnat_ugn/inline_assembler id3}@anchor{240}
@section A Simple Example of Inline Assembler
@code{nothing.out}.
@node Output Variables in Inline Assembler,Input Variables in Inline Assembler,A Simple Example of Inline Assembler,Inline Assembler
-@anchor{gnat_ugn/inline_assembler id4}@anchor{23f}@anchor{gnat_ugn/inline_assembler output-variables-in-inline-assembler}@anchor{240}
+@anchor{gnat_ugn/inline_assembler id4}@anchor{241}@anchor{gnat_ugn/inline_assembler output-variables-in-inline-assembler}@anchor{242}
@section Output Variables in Inline Assembler
@end quotation
@node Input Variables in Inline Assembler,Inlining Inline Assembler Code,Output Variables in Inline Assembler,Inline Assembler
-@anchor{gnat_ugn/inline_assembler id5}@anchor{241}@anchor{gnat_ugn/inline_assembler input-variables-in-inline-assembler}@anchor{242}
+@anchor{gnat_ugn/inline_assembler id5}@anchor{243}@anchor{gnat_ugn/inline_assembler input-variables-in-inline-assembler}@anchor{244}
@section Input Variables in Inline Assembler
@end quotation
@node Inlining Inline Assembler Code,Other Asm Functionality,Input Variables in Inline Assembler,Inline Assembler
-@anchor{gnat_ugn/inline_assembler id6}@anchor{243}@anchor{gnat_ugn/inline_assembler inlining-inline-assembler-code}@anchor{244}
+@anchor{gnat_ugn/inline_assembler id6}@anchor{245}@anchor{gnat_ugn/inline_assembler inlining-inline-assembler-code}@anchor{246}
@section Inlining Inline Assembler Code
thus saving the overhead of stack frame setup and an out-of-line call.
@node Other Asm Functionality,,Inlining Inline Assembler Code,Inline Assembler
-@anchor{gnat_ugn/inline_assembler id7}@anchor{245}@anchor{gnat_ugn/inline_assembler other-asm-functionality}@anchor{246}
+@anchor{gnat_ugn/inline_assembler id7}@anchor{247}@anchor{gnat_ugn/inline_assembler other-asm-functionality}@anchor{248}
@section Other @code{Asm} Functionality
@end menu
@node The Clobber Parameter,The Volatile Parameter,,Other Asm Functionality
-@anchor{gnat_ugn/inline_assembler id8}@anchor{247}@anchor{gnat_ugn/inline_assembler the-clobber-parameter}@anchor{248}
+@anchor{gnat_ugn/inline_assembler id8}@anchor{249}@anchor{gnat_ugn/inline_assembler the-clobber-parameter}@anchor{24a}
@subsection The @code{Clobber} Parameter
@end itemize
@node The Volatile Parameter,,The Clobber Parameter,Other Asm Functionality
-@anchor{gnat_ugn/inline_assembler id9}@anchor{249}@anchor{gnat_ugn/inline_assembler the-volatile-parameter}@anchor{24a}
+@anchor{gnat_ugn/inline_assembler id9}@anchor{24b}@anchor{gnat_ugn/inline_assembler the-volatile-parameter}@anchor{24c}
@subsection The @code{Volatile} Parameter
problems.
@node GNU Free Documentation License,Index,Inline Assembler,Top
-@anchor{share/gnu_free_documentation_license doc}@anchor{24b}@anchor{share/gnu_free_documentation_license gnu-fdl}@anchor{1}@anchor{share/gnu_free_documentation_license gnu-free-documentation-license}@anchor{24c}
+@anchor{share/gnu_free_documentation_license doc}@anchor{24d}@anchor{share/gnu_free_documentation_license gnu-fdl}@anchor{1}@anchor{share/gnu_free_documentation_license gnu-free-documentation-license}@anchor{24e}
@chapter GNU Free Documentation License
@printindex ge
+@anchor{d2}@w{ }
@anchor{gnat_ugn/gnat_utility_programs switches-related-to-project-files}@w{ }
-@anchor{d1}@w{ }
@c %**end of body
@bye