Merge pull request #169520 from LibreCybernetics/update-magma

magma: 2.5.4 → 2.6.2
This commit is contained in:
Samuel Ainsworth 2022-04-20 23:51:20 -07:00 committed by GitHub
commit 2d62d0d3c9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -8,7 +8,7 @@ assert let majorIs = lib.versions.major cudatoolkit.version;
in majorIs == "9" || majorIs == "10" || majorIs == "11";
let
version = "2.5.4";
version = "2.6.2";
# We define a specific set of CUDA compute capabilities here,
# because CUDA 11 does not support compute capability 3.0. Also,
@ -45,7 +45,7 @@ in stdenv.mkDerivation {
inherit version;
src = fetchurl {
url = "https://icl.cs.utk.edu/projectsfiles/magma/downloads/magma-${version}.tar.gz";
sha256 = "0rrvd21hczxlm8awc9z54fj7iqpjmsb518fy32s6ghz0g90znd3p";
hash = "sha256-dbVU2rAJA+LRC5cskT5Q5/iMvGLzrkMrWghsfk7aCnE=";
name = "magma-${version}.tar.gz";
};
@ -64,23 +64,6 @@ in stdenv.mkDerivation {
enableParallelBuilding=true;
buildFlags = [ "magma" "magma_sparse" ];
# MAGMA's default CMake setup does not care about installation. So we copy files directly.
installPhase = ''
mkdir -p $out
mkdir -p $out/include
mkdir -p $out/lib
mkdir -p $out/lib/pkgconfig
cp -a ../include/*.h $out/include
#cp -a sparse-iter/include/*.h $out/include
cp -a lib/*.so $out/lib
cat ../lib/pkgconfig/magma.pc.in | \
sed -e s:@INSTALL_PREFIX@:"$out": | \
sed -e s:@CFLAGS@:"-I$out/include": | \
sed -e s:@LIBS@:"-L$out/lib -lmagma -lmagma_sparse": | \
sed -e s:@MAGMA_REQUIRED@:: \
> $out/lib/pkgconfig/magma.pc
'';
meta = with lib; {
description = "Matrix Algebra on GPU and Multicore Architectures";
license = licenses.bsd3;