2011-08-16 18:17:36 +00:00
|
|
|
{ stdenv, fetchurl, python, perl, gfortran }:
|
2010-01-27 22:13:19 +00:00
|
|
|
|
2011-08-16 18:17:36 +00:00
|
|
|
let version = "1.4"; in
|
2010-01-27 22:13:19 +00:00
|
|
|
stdenv.mkDerivation {
|
|
|
|
name = "mpich2-${version}";
|
2008-02-21 16:17:43 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2010-01-27 22:13:19 +00:00
|
|
|
url = "http://www.mcs.anl.gov/research/projects/mpich2/downloads/tarballs/${version}/mpich2-${version}.tar.gz";
|
2011-08-16 18:17:36 +00:00
|
|
|
sha256 = "0bvvk4n9g4rmrncrgs9jnkcfh142i65wli5qp1akn9kwab1q80z6";
|
2008-02-21 16:17:43 +00:00
|
|
|
};
|
|
|
|
|
2011-08-16 18:17:36 +00:00
|
|
|
configureFlags = "--enable-shared --enable-sharedlib";
|
|
|
|
|
|
|
|
buildInputs = [ python perl gfortran ];
|
2011-08-16 21:13:20 +00:00
|
|
|
propagatedBuildInputs = stdenv.lib.optional (stdenv ? glibc) [ stdenv.glibc ];
|
2010-01-27 22:13:19 +00:00
|
|
|
|
|
|
|
patchPhase =
|
|
|
|
'' for i in $(find -type f -not -name Makefile.\*)
|
|
|
|
do
|
|
|
|
if grep -q /usr/bin/env "$i"
|
|
|
|
then
|
|
|
|
interpreter="$(cat $i | grep /usr/bin/env | sed -'es|^.*/usr/bin/env \([^ ]\+\).*$|\1|g')"
|
|
|
|
echo "file \`$i' -> interpreter \`$interpreter'"
|
|
|
|
path="$(type -P $interpreter)"
|
|
|
|
echo "\`/usr/bin/env $interpreter' -> \`$path' in \`$i'..."
|
|
|
|
sed -i "$i" -e "s|/usr/bin/env $interpreter|$path|g"
|
|
|
|
fi
|
|
|
|
done
|
|
|
|
true
|
|
|
|
'';
|
2008-02-21 16:17:43 +00:00
|
|
|
|
|
|
|
meta = {
|
2010-01-27 22:13:19 +00:00
|
|
|
description = "MPICH2, an implementation of the Message Passing Interface (MPI) standard";
|
|
|
|
|
2009-03-03 13:27:40 +00:00
|
|
|
longDescription = ''
|
|
|
|
MPICH2 is a free high-performance and portable implementation of
|
|
|
|
the Message Passing Interface (MPI) standard, both version 1 and
|
|
|
|
version 2.
|
|
|
|
'';
|
2008-02-21 16:17:43 +00:00
|
|
|
homepage = http://www.mcs.anl.gov/mpi/mpich2/;
|
|
|
|
license = "free, see http://www.mcs.anl.gov/research/projects/mpich2/downloads/index.php?s=license";
|
2010-01-27 22:13:19 +00:00
|
|
|
|
|
|
|
maintainers = [ stdenv.lib.maintainers.ludo ];
|
|
|
|
platforms = stdenv.lib.platforms.unix;
|
2008-02-21 16:17:43 +00:00
|
|
|
};
|
|
|
|
}
|