Merge pull request #34065 from markuskowa/openmpi3-pr
openmpi: 1.10.7->3.0.0, add markuskowa as maintainer
This commit is contained in:
commit
35ab6369c6
3 changed files with 42 additions and 24 deletions
|
@ -1,4 +1,4 @@
|
||||||
{stdenv, fetchurl, gfortran, perl, rdma-core
|
{ stdenv, fetchurl, gfortran, perl, libnl, rdma-core, zlib
|
||||||
|
|
||||||
# Enable the Sun Grid Engine bindings
|
# Enable the Sun Grid Engine bindings
|
||||||
, enableSGE ? false
|
, enableSGE ? false
|
||||||
|
@ -7,44 +7,48 @@
|
||||||
, enablePrefix ? false
|
, enablePrefix ? false
|
||||||
}:
|
}:
|
||||||
|
|
||||||
with stdenv.lib;
|
|
||||||
|
|
||||||
let
|
let
|
||||||
majorVersion = "1.10";
|
majorVersion = "3.0";
|
||||||
|
minorVersion = "0";
|
||||||
|
|
||||||
in stdenv.mkDerivation rec {
|
in stdenv.mkDerivation rec {
|
||||||
name = "openmpi-${majorVersion}.7";
|
name = "openmpi-${majorVersion}.${minorVersion}";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "http://www.open-mpi.org/software/ompi/v${majorVersion}/downloads/${name}.tar.bz2";
|
url = "http://www.open-mpi.org/software/ompi/v${majorVersion}/downloads/${name}.tar.bz2";
|
||||||
sha256 = "142s1vny9gllkq336yafxayjgcirj2jv0ddabj879jgya7hyr2d0";
|
sha256 = "1mw2d94k6mp4scg1wnkj50vdh734fy5m2ygyrj65s4mh3prbz6gn";
|
||||||
};
|
};
|
||||||
|
|
||||||
buildInputs = [ gfortran ]
|
postPatch = ''
|
||||||
++ optional (stdenv.isLinux || stdenv.isFreeBSD) rdma-core;
|
patchShebangs ./
|
||||||
|
'';
|
||||||
|
|
||||||
|
buildInputs = with stdenv; [ gfortran zlib ]
|
||||||
|
++ lib.optional isLinux libnl
|
||||||
|
++ lib.optional (isLinux || isFreeBSD) rdma-core;
|
||||||
|
|
||||||
nativeBuildInputs = [ perl ];
|
nativeBuildInputs = [ perl ];
|
||||||
|
|
||||||
configureFlags = []
|
configureFlags = with stdenv; []
|
||||||
++ optional enableSGE "--with-sge"
|
++ lib.optional isLinux "--with-libnl=${libnl.dev}"
|
||||||
++ optional enablePrefix "--enable-mpirun-prefix-by-default"
|
++ lib.optional enableSGE "--with-sge"
|
||||||
|
++ lib.optional enablePrefix "--enable-mpirun-prefix-by-default"
|
||||||
;
|
;
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
enableParallelBuilding = true;
|
||||||
|
|
||||||
preBuild = ''
|
|
||||||
patchShebangs ompi/mpi/fortran/base/gen-mpi-sizeof.pl
|
|
||||||
'';
|
|
||||||
|
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
rm -f $out/lib/*.la
|
rm -f $out/lib/*.la
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = {
|
doCheck = true;
|
||||||
|
|
||||||
|
meta = with stdenv.lib; {
|
||||||
homepage = http://www.open-mpi.org/;
|
homepage = http://www.open-mpi.org/;
|
||||||
description = "Open source MPI-2 implementation";
|
description = "Open source MPI-3 implementation";
|
||||||
longDescription = "The Open MPI Project is an open source MPI-2 implementation that is developed and maintained by a consortium of academic, research, and industry partners. Open MPI is therefore able to combine the expertise, technologies, and resources from all across the High Performance Computing community in order to build the best MPI library available. Open MPI offers advantages for system and software vendors, application developers and computer science researchers.";
|
longDescription = "The Open MPI Project is an open source MPI-3 implementation that is developed and maintained by a consortium of academic, research, and industry partners. Open MPI is therefore able to combine the expertise, technologies, and resources from all across the High Performance Computing community in order to build the best MPI library available. Open MPI offers advantages for system and software vendors, application developers and computer science researchers.";
|
||||||
maintainers = [ ];
|
maintainers = with maintainers; [ markuskowa ];
|
||||||
|
license = licenses.bsd3;
|
||||||
platforms = platforms.unix;
|
platforms = platforms.unix;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ stdenv, fetchurl, python, buildPythonPackage
|
{ stdenv, fetchurl, python, buildPythonPackage
|
||||||
, numpy, hdf5, cython, six, pkgconfig
|
, numpy, hdf5, cython, six, pkgconfig
|
||||||
, mpi4py ? null }:
|
, mpi4py ? null, openssh }:
|
||||||
|
|
||||||
assert hdf5.mpiSupport -> mpi4py != null && hdf5.mpi == mpi4py.mpi;
|
assert hdf5.mpiSupport -> mpi4py != null && hdf5.mpi == mpi4py.mpi;
|
||||||
|
|
||||||
|
@ -24,6 +24,10 @@ in buildPythonPackage rec {
|
||||||
|
|
||||||
postConfigure = ''
|
postConfigure = ''
|
||||||
${python.executable} setup.py configure ${configure_flags}
|
${python.executable} setup.py configure ${configure_flags}
|
||||||
|
|
||||||
|
# Needed to run the tests reliably. See:
|
||||||
|
# https://bitbucket.org/mpi4py/mpi4py/issues/87/multiple-test-errors-with-openmpi-30
|
||||||
|
${optionalString mpiSupport "export OMPI_MCA_rmaps_base_oversubscribe=yes"}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
preBuild = if mpiSupport then "export CC=${mpi}/bin/mpicc" else "";
|
preBuild = if mpiSupport then "export CC=${mpi}/bin/mpicc" else "";
|
||||||
|
@ -33,7 +37,7 @@ in buildPythonPackage rec {
|
||||||
++ optional mpiSupport mpi
|
++ optional mpiSupport mpi
|
||||||
;
|
;
|
||||||
propagatedBuildInputs = [ numpy six]
|
propagatedBuildInputs = [ numpy six]
|
||||||
++ optional mpiSupport mpi4py
|
++ optionals mpiSupport [ mpi4py openssh ]
|
||||||
;
|
;
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ stdenv, fetchPypi, python, buildPythonPackage, mpi }:
|
{ stdenv, fetchPypi, python, buildPythonPackage, mpi, openssh }:
|
||||||
|
|
||||||
buildPythonPackage rec {
|
buildPythonPackage rec {
|
||||||
pname = "mpi4py";
|
pname = "mpi4py";
|
||||||
|
@ -14,6 +14,12 @@ buildPythonPackage rec {
|
||||||
inherit mpi;
|
inherit mpi;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
postPatch = ''
|
||||||
|
substituteInPlace test/test_spawn.py --replace \
|
||||||
|
"unittest.skipMPI('openmpi(<3.0.0)')" \
|
||||||
|
"unittest.skipMPI('openmpi')"
|
||||||
|
'';
|
||||||
|
|
||||||
configurePhase = "";
|
configurePhase = "";
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
|
@ -28,11 +34,15 @@ buildPythonPackage rec {
|
||||||
# sometimes packages specify where files should be installed outside the usual
|
# sometimes packages specify where files should be installed outside the usual
|
||||||
# python lib prefix, we override that back so all infrastructure (setup hooks)
|
# python lib prefix, we override that back so all infrastructure (setup hooks)
|
||||||
# work as expected
|
# work as expected
|
||||||
|
|
||||||
|
# Needed to run the tests reliably. See:
|
||||||
|
# https://bitbucket.org/mpi4py/mpi4py/issues/87/multiple-test-errors-with-openmpi-30
|
||||||
|
export OMPI_MCA_rmaps_base_oversubscribe=yes
|
||||||
'';
|
'';
|
||||||
|
|
||||||
setupPyBuildFlags = ["--mpicc=${mpi}/bin/mpicc"];
|
setupPyBuildFlags = ["--mpicc=${mpi}/bin/mpicc"];
|
||||||
|
|
||||||
buildInputs = [ mpi ];
|
buildInputs = [ mpi openssh ];
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
description =
|
description =
|
||||||
|
|
Loading…
Reference in a new issue