It appears that while the directories follow a M-A structure,
libopenmpi-dev is not labelled Multi-Arch, so i'm regrading this as
wishlist.

It would still be good for the alternatives link to be M-A aware, so I
will enable that. (and also in mpich).

The syntax in lapack, etc. is <link>-$DEB_HOST_MULTIARCH, so I will
follow that convention.

Its currently not possible to make openmpi/mpich fully M-A aware,
because the alternatves switch needs to control not only the library
(and pkgconfig files, and includes), but also some "wrapper" scripts,
mpicc, etc. that are typically used to compiler MPI programs.

These currently reside in /usr/bin ; it would be possible to move them
to eg. /usr/lib/$DEB_HOST_MULTIARCH/openmpi/bin but they would be
expected to be on the default path by the MPI standard. Also, ideally
mpicc, etc. would be in opempi-bin, the package with openmpi
executables, but using the same alternatives switch in two packages
would be difficult (impossible?) and error-prone; using two switches so
libmpi.so points to one implementation while mpicc could use another
would be buggy.

So:

Can anyone think of a better solution than using alternatives to do
/usr/bin/mpicc -> /usr/lib/$DEB_HOST_MULTIARCH/openmpi/bin ? this is
simply ugly to me, though it would enable M-A for libopenmpi-dev and
proper cross-compilation,etc use cases.


09/01/2018 10:53, Wouter Verhelst wrote:

> The same is true for libdrmaa.so.* (provided by slurm-drmaa1 and
> gridengine-drmaa-1.0).
>
> I think it makes sense to have a detailed discussion about these
> things...?
>
> On Mon, Jan 08, 2018 at 12:01:53PM +0000, Alastair McKinstry wrote:
>> Package: openmpi
>> Severity: important
>>
>> openmpi installs links via alternatives for libmpi.so, as does mpich and lam.
>> Unfortunately its implementation is not multi-arch safe: there can be 
>> multiple multiarch implementations of libmpi.so present, but only one 
>> libmpi.so in /etc/alternatives.
>>
>> The best practice (see lapack, etc.) is /etc/alternatives/libmpi.so.${ARCH}.
>>
>> This needs to be fixed in both openmpi and mpich.
>>
>> lam needs to be updated to be multi-arch aware too, as it uses 
>> /etc/alternatives/libmpi.so -> a non-m-a aware location.
>>                                                                              
>>                                                                              
>>                                     

-- 
Alastair McKinstry, <alast...@sceal.ie>, <mckins...@debian.org>, 
https://diaspora.sceal.ie/u/amckinstry
Commander Vimes didn’t like the phrase “The innocent have nothing to fear,”
 believing the innocent had everything to fear, mostly from the guilty but in 
the longer term
 even more from those who say things like “The innocent have nothing to fear.”
 - T. Pratchett, Snuff

Reply via email to