summaryrefslogtreecommitdiffstats
path: root/pkgs/development/libraries/science/math/magma/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/libraries/science/math/magma/default.nix')
-rw-r--r--pkgs/development/libraries/science/math/magma/default.nix19
1 files changed, 13 insertions, 6 deletions
diff --git a/pkgs/development/libraries/science/math/magma/default.nix b/pkgs/development/libraries/science/math/magma/default.nix
index d036e39d01ae..c428fbab588b 100644
--- a/pkgs/development/libraries/science/math/magma/default.nix
+++ b/pkgs/development/libraries/science/math/magma/default.nix
@@ -1,24 +1,31 @@
-{ stdenv, fetchurl, cmake, gfortran, cudatoolkit, libpthreadstubs, liblapack }:
+{ stdenv, fetchurl, cmake, gfortran, cudatoolkit, libpthreadstubs, liblapack
+, mklSupport ? false, mkl ? null
+}:
+
+assert !mklSupport || mkl != null;
with stdenv.lib;
-let version = "2.0.2";
+let version = "2.5.0";
in stdenv.mkDerivation {
pname = "magma";
inherit version;
src = fetchurl {
url = "https://icl.cs.utk.edu/projectsfiles/magma/downloads/magma-${version}.tar.gz";
- sha256 = "0w3z6k1npfh0d3r8kpw873f1m7lny29sz2bvvfxzk596d4h083lk";
+ sha256 = "0czspk93cv1fy37zyrrc9k306q4yzfxkhy1y4lj937dx8rz5rm2g";
name = "magma-${version}.tar.gz";
};
- buildInputs = [ gfortran cudatoolkit libpthreadstubs liblapack cmake ];
+ buildInputs = [ gfortran cudatoolkit libpthreadstubs cmake ]
+ ++ (if mklSupport then [ mkl ] else [ liblapack ]);
doCheck = false;
- #checkTarget = "tests";
+
+ MKLROOT = optionalString mklSupport "${mkl}";
enableParallelBuilding=true;
+ buildFlags = [ "magma" "magma_sparse" ];
# MAGMA's default CMake setup does not care about installation. So we copy files directly.
installPhase = ''
@@ -42,6 +49,6 @@ in stdenv.mkDerivation {
license = licenses.bsd3;
homepage = http://icl.cs.utk.edu/magma/index.html;
platforms = platforms.unix;
- maintainers = with maintainers; [ ianwookim ];
+ maintainers = with maintainers; [ tbenst ];
};
}