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:
Matthew Bauer
2020-04-17 16:24:09 -05:00
parent 43873351ff
commit 1c8aba8334
68 changed files with 272 additions and 311 deletions
@@ -1,5 +1,7 @@
{ stdenv, fetchurl, cmake,
gfortran, openblasCompat}:
gfortran, blas, lapack}:
assert (!blas.is64bit) && (!lapack.is64bit);
stdenv.mkDerivation rec {
version = "5.2.1";
@@ -12,7 +14,7 @@ stdenv.mkDerivation rec {
buildInputs = [ cmake gfortran ];
propagatedBuildInputs = [ openblasCompat ];
propagatedBuildInputs = [ blas ];
cmakeFlags = [
"-DBUILD_SHARED_LIBS=true"
@@ -20,7 +22,6 @@ stdenv.mkDerivation rec {
];
patches = [
./find-openblas-library.patch
./add-superlu-lib-as-dependency-for-the-unit-tests.patch
];
@@ -1,11 +0,0 @@
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -75,6 +75,8 @@ set(CMAKE_C_FLAGS_RELEASE "-O3" CACHE STRING "")
######################################################################
#
#--------------------- BLAS ---------------------
+find_package(OpenBLAS)
+set(TPL_BLAS_LIBRARIES ${OpenBLAS_LIBRARIES})
if(NOT enable_blaslib)
if (TPL_BLAS_LIBRARIES)
set(BLAS_FOUND TRUE)