@@ -0,0 +1,33 @@
1+{ stdenv
2+, fetchurl
3+, cmake
4+, mpi
5+}:
6+
7+stdenv.mkDerivation rec {
8+ name = "parmetis-${version}";
9+ version = "4.0.3";
10+
11+ src = fetchurl {
12+ url = "http://glaros.dtc.umn.edu/gkhome/fetch/sw/parmetis/parmetis-${version}.tar.gz";
13+ sha256 = "0pvfpvb36djvqlcc3lq7si0c5xpb2cqndjg8wvzg35ygnwqs5ngj";
14+ };
15+
16+ buildInputs = [ cmake mpi ];
17+
18+ # metis and GKlib are packaged with distribution
19+ # AUR https://aur.archlinux.org/packages/parmetis/ has reported that
20+ # it easier to build with the included packages as opposed to using the metis
21+ # package. Compilation time is short.
22+ configurePhase = ''
23+ make config metis_path=$PWD/metis gklib_path=$PWD/metis/GKlib prefix=$out
24+ '';
25+
26+ meta = with stdenv.lib; {
27+ description = "ParMETIS is an MPI-based parallel library that implements a variety of algorithms for partitioning unstructured graphs, meshes, and for computing fill-reducing orderings of sparse matrices";
28+ homepage = http://glaros.dtc.umn.edu/gkhome/metis/parmetis/overview;
29+ platforms = platforms.all;
30+ license = licenses.cc-by-nc-sa-20;
31+ maintainers = [ maintainers.costrouc ];
32+ };
33+}