DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

chkshlib(CP)


chkshlib -- compare shared libraries tool

Syntax

chkshlib [-b] [-i] [-n] [-v] file1 [file2 file3 ... ]

Description

The chkshlib(CP) command checks for compatibility between files.

Input files can be combinations of host shared libraries, non-stripped target shared libraries, and non-stripped executable files. A file is compatible with another file if every library symbol in it that should be matched is matched in the second (that is, the symbol exists and has the same address in both files). The path name for the target shared library in both files must be identical (unless the -i option is set).

It is possible for file1 to be compatible with file2 without the reverse also being true.

If one incompatibility is found it is reported to standard output and processing stops (unless the -v option is set).

The options to chkshlib are:


-b
If there are symbols in file1 that are not in the bounds of file2, report warning messages to standard output.

-i
The path names for the target shared library do not need to be identical for two files to be compatible.

-n
There are exactly two input files, which are target shared libraries, where the first references symbols in the second (``includes'' the second).

-v
Cause verbose reporting of all incompatibilities to standard output.

The output of chkshlib depends on the input. If the first input file is an executable file and the other input files, if any, are target shared libraries, the output states whether or not the executable file can execute using each target shared library. If no target shared libraries are supplied, chkshlib does the compatibility check against the target shared libraries specified in the .lib section of the executable file.

If the first input file is an executable file and the other input file(s) is a host shared library, the output states whether or not the executable file could have been produced using each host.

If one input file is a host shared library and another is a target shared library, the output states whether or not the host shared library could produce executable files that will run with the target shared library. If no target shared library is supplied, chkshlib checks the compatibility against the target specified in the .lib section of the library definition file found in the host.

If both input files are target shared libraries or both are host shared libraries, the output states whether or not the first file could replace the second and vice versa.

If both input files are target libraries and the -n option is set, the output states whether the first file references symbols in the second file (``includes'' the second).

Compatibility of all other combinations of host shared libraries, target shared libraries, and executable files has no useful meaning, and these other combinations of files are not accepted as valid input to chkshlib.

The valid combinations of input files are:


Executable [Target shared library(1) ... Target shared library(n)]

Executable [Host shared library(1) ... Host shared library(n)]

Host shared library Target shared library

Host shared library Host shared library

Target shared library Host shared library

Target shared library Target shared library

All other forms of input are rejected.

Exit values

Exit status is:

0 if no incompatibilities are found

1 if an incompatibility is found

2 if a processing error occurs

Warning

You must use the -i option whenever you use the -n option.

Standard binaries distributed with the system are stripped, and chkshlib cannot be used with them.

See also

mkshlib(CP)

Standards conformance

chkshlib(CP) is not part of any currently supported standard; it is an extension of AT&T System V that is maintained by The SCO Group.
© 2005 Commands for Programming (CP)
SCO OpenServer Release 6.0.0 -- 02 June 2005