mpi: use mpi attribute consistently as the default MPI implementations

Use the attribute mpi to provide a system wide default MPI
implementation. The default is openmpi (as before).
This now allows for overriding the MPI implentation by using
the overlay mechanism. Build all packages with mpich instead
of the default openmpi can now be achived like this:
self: super:
 {
   mpi = super.mpich;
 }

All derivations that have been using "mpi ? null" to provide optional
building with MPI have been change in the following way to allow for
optional builds with MPI:
{ ...
, mpi
, useMpi ? false
}
This commit is contained in:
Markus Kowalewski
2021-01-10 13:40:19 +01:00
parent f6a583eeec
commit 6dba41fbcb
27 changed files with 90 additions and 102 deletions

View File

@@ -11,7 +11,7 @@
# Common deps
, git, pybind11, which, binutils, glibcLocales, cython, perl
# Common libraries
, jemalloc, openmpi, gast, grpc, sqlite, boringssl, jsoncpp
, jemalloc, mpi, gast, grpc, sqlite, boringssl, jsoncpp
, curl, snappy, flatbuffers-core, lmdb-core, icu, double-conversion, libpng, libjpeg_turbo, giflib
# Upsteam by default includes cuda support since tensorflow 1.15. We could do
# that in nix as well. It would make some things easier and less confusing, but
@@ -129,7 +129,7 @@ let
buildInputs = [
jemalloc
openmpi
mpi
glibcLocales
git