ADA.MAKE(1) — Series 300 Only (Requires Optional Ada Software)
NAME
ada.make − determine compilation order, update Ada libraries
SYNOPSIS
ada.make [ options ] [ library ] [ files ]
Remarks:
This command requires installation of optional ADA software (not included with the standard HP-UX operating system) before it can be used.
DESCRIPTION
Ada.make reads Ada source files and libraries in order to produce a minimal, correctly ordered sequence of commands necessary to compile or recompile a set of Ada compilation units.
The library argument names an Ada library that must have already been created using the ada.mklib(1) command.
Files specifies a set of Ada source files. For an application that consists of a large number of source files, the system-imposed limit on argument list length may be exceeded. For this reason, patterns may be given as file arguments. A pattern may contain the character *, which matches any sequence of zero or more characters. The character * must be escaped from the shell.
If neither library nor files is specified, ada.make operates on the files in the current directory whose names end with .ad?, where ? is any single alphanumeric character (see Source vs. Library Mode, below).
The command sequence generated by ada.make is written to file ada.make.out (or to the file named by the -o option). The commands in this file can be executed by sh(1) using the command "sh ada.make.out".
Options
The following options are recognized:
−a Produce commands to compile units regardless of whether they are out-of-date.
−b Emit a command to bind the unit specified by the option −r unitpattern (only allowed if unitpattern specifies a single unit).
−f file Read library and files arguments from file. A file name of - denotes the standard input.
−i Check the validity of all required units, regardless of where they reside in the family. Output may contain commands to acquire links or compile source files into any library in the family (see Multi-Library Operation, below).
−o outfile Name the output file outfile instead of ada.make.out.
−p Assume that all links in library and all units outside of library are valid (see Multi-Library Operation, below).
−r unitpattern Specify which units are to be brought up to date. Unitpattern may be the name of a single unit, or may contain one or more occurrences of the character *, which matches any sequence of zero or more characters in a unit name.
The character * must be escaped from the shell.
The default unitpattern is *, which selects all units in library and files.
−s searchlibrary
Specify a library to be searched when a required unit is missing (no link to the unit exists in library, and the unit is not contained in files).
This option may be repeated to specify multiple libraries. Ada.make searches the libraries in the order they are given; the first correctly named unit is selected.
−v Enable verbose mode, which writes the ada.make command being processed and the command sent to the subprocess ada.make.bin to standard error.
Source vs. Library Mode
Ada.make can work in source mode, to produce a correct compilation order for a set of source files, in library mode, to identify files that need to be recompiled, or in a combination of these two modes. When operating on an application whose units are contained in multiple libraries, ada.make produces commands to create the required links between libraries.
When library is not specified, ada.make operates in source mode on files. If files are not given, it uses files in the current directory whose names end with .ad?, where ? is any single character. When operating in source mode, the resulting compile commands do not specify a library. The commands can be executed, however, if the environment variable ADAOPTS contains a library name (see ada(1), Environment Variables).
If library is specified, it is read to determine which units are obsolete. For each unit ada.make examines, it uses the source file name that was recorded in the library when the unit was compiled.
When both library and files are specified, units contained in files have precedence over corresponding previously compiled units.
Multi-Library Operation
Ada.make provides three modes of operation for applications that are distributed among multiple libraries. These modes determine whether the validity of units outside library is checked, and whether commands will be emitted that would alter libraries other than library.
The default mode is to check all required units, regardless of what library they reside in. Any obsolete unit, however, is recompiled into library, rather than into the library in which the obsolete unit was found.
The -p ("partial") option directs ada.make to assume that all links in library and all units outside of library are valid. No commands to acquire links are emitted. Compile commands are only emitted for units contained in files and units that were previously compiled in library.
In the preceding two modes of operation, only library is changed -- no other libraries in the family are affected.
When the -i ("in situ") option is used, ada.make checks the validity of all required units and links regardless of what library they reside in. Any compilation or command to acquire a link is performed in the library that contains the obsolete unit or link. In this mode, modifications are not limited to library, but can occur in any library in the family.
Environment Variables
The environment variable ADA_PATH is associated with all components of the Ada compilation system. It must be set properly and exported before any component of the Ada compilation system (including ada.make) can be used (see ada(1), Environment Variables).
Locks
To ensure the integrity of their internal data structures, Ada libraries and families are locked for the duration of operations that are performed on them. Normally Ada families are locked only briefly when libraries within them are manipulated. However, sometimes multiple Ada libraries must be locked for longer periods during a single operation. If more than one library must be locked for a single operation, at most one library is locked for updating and all other locked libraries are locked for read-only.
An Ada family or library locked for updating cannot be accessed in any way by any part of the Ada compilation system except by the part which holds the lock. An Ada family or library locked for reading can be accessed by any part of the Ada compilation system for read-only purposes.
If ada.make cannot obtain a lock after a suitable number of retries, it displays an informational message and terminates.
Under some circumstances, an Ada family or Ada library might be locked, but the locking program(s) might have terminated (for example, due to system crash or network failure). If you determine that the Ada family or Ada library is locked but should not be locked, you can remove the lock.
Use ada.unlock(1) to unlock an Ada library and ada.funlock(1) to unlock an Ada family. However, unlocking should be done with care. If an Ada family or Ada library is actually locked by a tool, unlocking it permits access by other tools that might find the contents invalid or might damage the Ada family or Ada library.
AUTHOR
Ada.make was developed by HP and Alsys.
FILES
$ADA_PATH/ada.make ada.make command
$ADA_PATH/ada.make.bin ada.make subprocess
ada.make.out output file
SEE ALSO
ada(1), ada.fmgr(1), ada.format(1), ada.funlock(1), ada.lmgr(1), ada.lsfam(1), ada.lslib(1), ada.mkfam(1), ada.mklib(1), ada.mvfam(1), ada.mvlib(1), ada.probe(1), ada.protect(1), ada.rmfam(1), ada.rmlib(1), ada.umgr(1), ada.unlock(1), ada.xref(1),
Ada User’s Guide (Series 300),
Ada Tools Manual (Series 300).
Hewlett-Packard Company — HP-UX Release 7.0: Sept 1989