summary refs log tree commit diff
path: root/pkgs/development/libraries/qrupdate
diff options
context:
space:
mode:
authorMatthew Bauer <mjbauer95@gmail.com>2020-03-31 10:47:18 -0400
committerMatthew Bauer <mjbauer95@gmail.com>2020-04-17 16:24:09 -0500
commit1c8aba83340be3713f68410d1d273a8b15e7e007 (patch)
treefdc752744f384be57b6ff3c65495018432bff0ab /pkgs/development/libraries/qrupdate
parent43873351ffed36b52170571839e26b57c9f15920 (diff)
downloadnixpkgs-1c8aba83340be3713f68410d1d273a8b15e7e007.tar
nixpkgs-1c8aba83340be3713f68410d1d273a8b15e7e007.tar.gz
nixpkgs-1c8aba83340be3713f68410d1d273a8b15e7e007.tar.bz2
nixpkgs-1c8aba83340be3713f68410d1d273a8b15e7e007.tar.lz
nixpkgs-1c8aba83340be3713f68410d1d273a8b15e7e007.tar.xz
nixpkgs-1c8aba83340be3713f68410d1d273a8b15e7e007.tar.zst
nixpkgs-1c8aba83340be3713f68410d1d273a8b15e7e007.zip
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
Diffstat (limited to 'pkgs/development/libraries/qrupdate')
-rw-r--r--pkgs/development/libraries/qrupdate/default.nix11
1 files changed, 6 insertions, 5 deletions
diff --git a/pkgs/development/libraries/qrupdate/default.nix b/pkgs/development/libraries/qrupdate/default.nix
index a31cc4e8ed4..f6c16583ad7 100644
--- a/pkgs/development/libraries/qrupdate/default.nix
+++ b/pkgs/development/libraries/qrupdate/default.nix
@@ -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";