-
Notifications
You must be signed in to change notification settings - Fork 1
Description
Shared library version and name
The current status of the ABI specification defines the following major and minor ABI versions to encode backward-compatibility contracts:
MPI_ABI_VERSION (major) |
1 |
MPI_ABI_SUBVERSION (minor) |
0 |
We should use these numbers do define the shared library version. Shared library versions typically start at version 0, and that's the number we currently generate. However, AFAICT, that's just conventional. Should we instead start at version 1 to match MPI_ABI_VERSION
, thus producing an SONAME of libmpi_abi.so.1
on Linux and a install name of @rpath/libmpi_abi.1.dylib
?
Alternatively, MPI could start with MPI_ABI_VERSION=0
, although that's admittedly awkward. Likewise, having libmpi_abi.so.X
with X
not matching MPI_ABI_VERSION
is also awkward.
Use of libtool
On a related note, the MPI ABI major and minor numbers would most likely be used to define the current/release/age triplet of libtool's -version-info c:r:a
. Would the following mapping be appropriate?
I assume here we chose the major library version starting at 1, and not 0 as it is conventional, as per the previous discussion.
libtool | MPI ABI |
---|---|
current |
MPI_ABI_VERSION + MPI_ABI_SUBVERSION |
revision |
0 |
age |
MPI_ABI_SUBVERSION |
Which would map to the following shared library file names
Platform | Shared library name & symlink | Shared library full file name |
---|---|---|
Linux | libmpi_abi.so.${MPI_ABI_VERSION} |
libmpi_abi.so.${MPI_ABI_VERSION}.${MPI_ABI_SUBVERSION} |
Darwin | libmpi_abi.${MPI_ABI_VERSION}.dylib |
libmpi_abi.${MPI_ABI_VERSION}.${MPI_ABI_SUBVERSION}.dylib |
EDIT: As per the current ABI proposal, libtool's revision
number will always stay zero (is this corrent?). The full shared library filename may have an extra .0
appended on Linux.