treewide: use blas and lapack
This makes packages use lapack and blas, which can wrap different BLAS/LAPACK implementations. treewide: cleanup from blas/lapack changes A few issues in the original treewide: - can’t assume blas64 is a bool - unused commented code
This commit is contained in:
@@ -1,7 +1,8 @@
|
||||
{ stdenv
|
||||
, fetchurl
|
||||
, gfortran
|
||||
, openblas
|
||||
, blas
|
||||
, lapack
|
||||
}:
|
||||
stdenv.mkDerivation {
|
||||
name = "qrupdate-1.1.2";
|
||||
@@ -13,11 +14,11 @@ stdenv.mkDerivation {
|
||||
configurePhase =
|
||||
''
|
||||
export PREFIX=$out
|
||||
sed -i -e 's,^BLAS=.*,BLAS=-L${openblas}/lib -lopenblas,' \
|
||||
-e 's,^LAPACK=.*,LAPACK=-L${openblas}/lib -lopenblas,' \
|
||||
sed -i -e 's,^BLAS=.*,BLAS=-L${blas}/lib -lblas,' \
|
||||
-e 's,^LAPACK=.*,LAPACK=-L${lapack}/lib -llapack,' \
|
||||
Makeconf
|
||||
''
|
||||
+ stdenv.lib.optionalString openblas.blas64
|
||||
+ stdenv.lib.optionalString blas.is64bit
|
||||
''
|
||||
sed -i Makeconf -e '/^FFLAGS=.*/ s/$/-fdefault-integer-8/'
|
||||
'';
|
||||
@@ -30,7 +31,7 @@ stdenv.mkDerivation {
|
||||
|
||||
installTargets = stdenv.lib.optionals stdenv.isDarwin [ "install-staticlib" "install-shlib" ];
|
||||
|
||||
buildInputs = [ gfortran openblas ];
|
||||
buildInputs = [ gfortran blas lapack ];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "Library for fast updating of qr and cholesky decompositions";
|
||||
|
||||
Reference in New Issue
Block a user