Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

cmpdylib(1) [osx man page]

CMPDYLIB(1)						      General Commands Manual						       CMPDYLIB(1)

NAME
cmpdylib - compare two dynamic shared libraries for compatibility SYNOPSIS
cmpdylib oldLibrary newLibrary DESCRIPTION
cmpdylib compares two versions of a dynamic shared library to see if they are compatible with each other. If the two versions are incompat- ible, the reason is printed to stdout, and the exit status is nonzero. If they are compatible, nothing is printed, and the exit status is zero. To see if the two versions are compatible, cmpdylib first verifies that newLibrary was built for all of the architectures that oldLibrary was built for. If so, for each architecture, it checks to see if the global symbols defined in oldLibrary are still defined in newLibrary. It then looks for new symbols, symbols defined in newLibrary that are not defined in oldLibrary. If it finds new symbols, it compares the compatibility version numbers of the two libraries. If the compatibility version number of newLibrary is greater than oldLibrary, the libraries are still compatible. If the compatibility version number is the same or less, the libraries are incompatible. OPTIONS
oldLibrary The older version of the library. newLibrary The newer version of the library. EXAMPLES
This example shows the result of performing cmpdylib on two incompatible versions of the Foundation library. As stated, the versions are incompatible because the newer version was not built for the ppc architecture. cmpdylib /System/Library/Frameworks/Foundation.framework/Foundation Foundation_proj/Foundation cmpdylib: file: Foundation_proj/Foundation does not contain architecture: ppc cmpdylib: new dynamic shared library: Foundation_proj/Foundation does not contain architecture ppc DIAGNOSTICS
The exit status is zero if the library versions are compatible and nonzero if they are incompatible. BUGS
There are lots of other things that could be checked for that are not (such as the Objective C API). Apple Computer, Inc. November 3, 1997 CMPDYLIB(1)

Check Out this Related Man Page

XkbLibraryVersion(3)						   XKB FUNCTIONS					      XkbLibraryVersion(3)

NAME
XkbLibraryVersion - Determines the compatibility of a library at runtime. SYNOPSIS
Bool XkbLibraryVersion (int *lib_major_in_out, int *lib_minor_in_out); ARGUMENTS
lib_major_in_out Specifies and returns the major Xkb library version. lib_minor_in_out Specifies and returns the minor Xkb library version. DESCRIPTION
If an application is dynamically linked, both the X server and the client-side X library must contain the Xkb extension in order for the client to use the Xkb extension capabilities. Therefore a dynamically linked application must check both the library and the server for compatibility before using Xkb function calls. A properly written program must check for compatibility between the version of the Xkb library that is dynamically loaded and the one used when the application was built. It must then check the server version for compatibility with the version of Xkb in the library. If your application is statically linked, you must still check for server compatibility and may check library compatibility. (It is possi- ble to compile against one set of header files and link against a different, incompatible, version of the library, although this should not normally occur.) Pass the symbolic value XkbMajorVersion in lib_major_in_out and XkbMinorVersion in lib_minor_in_out. These arguments represent the version of the library used at compile time. The XkbLibraryVersion function backfills the major and minor version numbers of the library used at run time in lib_major_in_out and lib_minor_in_out. If the versions of the compile time and run time libraries are compatible, XkbLi- braryVersion returns True, otherwise, it returns False. In addition, in order to use the Xkb extension, you must ensure that the extension is present in the server and that the server supports the version of the extension expected by the client. Use XkbQueryExtension to do this, as described in the next section. RETURN VALUES
True The XkbLibraryVersion returns True if the versions of the compile time and run time libraries are compatible. False The XkbLibraryVersion returns False if the versions of the compile time and run time libraries are not compatible. SEE ALSO
XkbMajorVersion(3), XkbMinorVersion(3), XkbQueryExtension(3) X Version 11 libX11 1.3.2 XkbLibraryVersion(3)
Man Page