ADA.MKLIB(1) — HP-UX
Series 300 Only
NAME
ada.mklib − make (or reinitialize) an Ada library
SYNOPSIS
ada.mklib [ −f ] [ −F family ] [ −I ] [ −P ] libraryname
DESCRIPTION
Ada.mklib creates the Ada library libraryname in mode 777 (possibly altered by umask(1)). The Ada library created is specified by name during subsequent compilations of Ada source, and is used by the compiler to maintain intermediate forms of Ada compilation units.
Ada.mklib requires write permission in the parent directory. Ada.mklib only creates the last component of the specified path as the Ada library; all parent directories must already exist.
The created library is made a member of an Ada family of libraries. By default, the created library is made a member of the PUBLIC family. Optionally, the created library can be made a member of any existing Ada family.
An Ada family is a group of Ada libraries that are visible to one another. Units in a library in a particular family can be dependent on units in another library in the same family and a program can be composed (bound) using units from any number of libraries in a given family.
Libraries that are members of different families are normally invisible to each other and cannot access each other’s units. There is one exception to this rule; libraries belonging to the INSTALLATION family (a family provided with the Ada compilation system) are accessible to libraries in any other family.
If libraryname exists, ada.mklib can be used to reinitialize it (thus making it an empty library). If the library being reinitialized is a member of any family other than PUBLIC, the family must be specified when reinitializing the library.
If the standard input is a terminal, ada.mklib requests confirmation before reinitializing an existing Ada library. Confirmation is not requested if the −f option is given or if the standard input is not a terminal.
The following options are recognized:
−f Do not ask for confirmation if the library being created already exists; reinitialize the existing Ada library to the empty state.
−F family Make the newly created Ada library a member of the specified family or identify the library to be reinitialized as a member of the specified family.
−I Make the newly created Ada library a member of the INSTALLATION family or identify the library to be reinitialized as a member of the INSTALLATION family. Ada libraries in the INSTALLATION family are visible to Ada libraries in all other families. Units in INSTALLATION family libraries can be accessed by units in any Ada library and an Ada program can be composed (bound) using units from libraries in any given family and units from libraries in the INSTALLATION family.
−P Make the newly created library a member of the PUBLIC family or identify the library to be reinitialized as a member of the PUBLIC family. This is the default family if no family is specified.
Environment Variables
Two environment variables, ADA_PATH and ADA_PREDEF_LIB, associated with all components of the the Ada compilation system. Both must be set properly and exported before any component of the Ada compilation system (including ada.mklib) 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 a library is added, removed, or renamed; however, sometimes multiple Ada libraries must be locked for longer periods during a single operation. If more than one library is locked, ada places an exclusive lock on one library, for updating, and a shared lock on any others to remain open for read-only purposes.
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 locking agent. 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.mklib cannot obtain a lock, 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 not actually locked, you can remove the lock.
Use ada.unlock(1) to unlock an Ada library and the UNLOCK command of ada.fmgr(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.
DIAGNOSTICS
Ada.mklib returns exit status 0 if the Ada library directory was successfully created, otherwise a diagnostic is issued and a non-zero exit status is returned.
WARNINGS
An Ada library is a directory containing files for the use of the Ada compilation system. Users are strongly discouraged from placing any user files or directories in Ada library directories. User files/directories in Ada libraries are subject to damage by or might interfere with proper operation of the Ada compilation system. In particular, ada.mklib does not preserve such user files when reinitializing an existing Ada library, and is unable to reinitialize an existing Ada library (effectively destroying it) if the existing Ada library directory contains any subdirectories.
DEPENDENCIES
Series 300
Unlike other Series 300 compilers, the type of code generated cannot be directly specified to the compiler. The type of code generated is determined by the library into which the code is compiled.
The following options are specific to the Series 300:
+x Create an Ada library that contains 68020 code. Units compiled into this Ada library have code generated suitable for the 68020 processor. This is the default if the host system contains a 68020 processor.
+X Create an Ada library that contains 68010 code. Units compiled into this Ada library have code generated suitable for the 68010 or 68020 processor. This is the default if the host system contains a 68010 processor.
AUTHOR
Ada.mklib was developed by HP and Alsys.
FILES
$ADA_PATH/adahostcap Ada host system capability checker.
$ADA_PATH/ada.lmgr.bin
Ada library manager subprocess.
$ADA_PATH/ada.lmgr.hlp
Ada library manager help command data.
$ADA_PATH/ada.lmgr.btl Ada library manager command tables.
SEE ALSO
ada(1), ada.fmgr(1), ada.format(1), ada.mvlib(1), ada.probe(1), ada.protect(1), ada.rmlib(1), ada.umgr(1), ada.unlock(1). ada.xref(1).
Ada User’s Guide (Series 300), HP Part No. 98860-90000.
INTERNATIONAL SUPPORT
8-bit file names.
Hewlett-Packard Company — May 11, 2021