From bc55d7d2b609c7900b3a61e6db6dcac54f31e113 Mon Sep 17 00:00:00 2001 From: Nistha Bhawsinka Date: Fri, 23 Dec 2022 18:43:05 +0100 Subject: [PATCH] doc: add documentation for lapack library linking support - Fixes #14579 - Reference external-libs/lapack.html in readme.html Signed-off-by: Nistha Bhawsinka --- doc/external-libs/lapack.html | 108 ++++++++++++++++++++++++++++++++++ doc/readme.html | 5 +- 2 files changed, 110 insertions(+), 3 deletions(-) create mode 100644 doc/external-libs/lapack.html diff --git a/doc/external-libs/lapack.html b/doc/external-libs/lapack.html new file mode 100644 index 0000000000..09e098dfe8 --- /dev/null +++ b/doc/external-libs/lapack.html @@ -0,0 +1,108 @@ + + + + + The deal.II Readme on interfacing to BLAS/LAPACK + + + + + + +

Installation of BLAS/LAPACK

+ +

+ LAPACK + is a library of Fortran subroutines for solving the most + commonly occurring problems in numerical linear algebra. + LAPACK reference implementation is available on + GitHub, + corresponding releases are available on + netlib. + It is worth noting that there are further implementations of BLAS/LAPACK + libraries, such as OpenBLAS and + Intel MKL, +

+ +

+ LAPACK and + BLAS are packaged and + distributed by distros such as Debian, Ubuntu, Pop!OS, CentOS and others. + + It is recommended to install these packages using apt or yum package + managers. They can be installed on Debian or Ubuntu systems using + the following commands. +

+        sudo apt update && sudo apt upgrade
+        sudo apt install libblas3 libblas-dev
+        sudo apt install liblapack3 liblapack-dev
+      
+

+ +

+ Below is a short summary of instructions on how to compile and install + LAPACK by hand (for the case you wish to do so). +

+ +

How to compile and install LAPACK by hand

+ +

+ First clone the LAPACK + repository. And configure cmake to build lapack as a shared library. + The following commands will result in a set of .so files or shared library + files installed in the path specified with CMAKE_INSTALL_LIBDIR flag : + +

+        cd lapack
+        mkdir build
+        cd build
+        cmake -DBUILD_SHARED_LIBS=ON -DCMAKE_INSTALL_LIBDIR=$HOME/.local/lapack ../
+        make install
+      
+ + After successful execution of above set of commands, a list of .so files + such as libblas.so, libblas.so.3, liblapack.so, liblapack.so.3 are + generated. +

+ +

Interfacing deal.II + to LAPACK

+ +

+ Support for LAPACK will be + enabled automatically if a system wide installation of + LAPACK can be found. + To use a self compiled version, specify +

+    -DLAPACK_DIR=/path/to/lapack-installation
+      
+ when invoking cmake, for example, + +
+        git clone https://github.com/dealii/dealii.git
+        cd dealii
+        mkdir build
+        cd build
+        cmake -DDEAL_II_WITH_LAPACK=ON -DLAPACK_DIR=$HOME/.local/lapack/ ../
+        make
+      
+ +

+

+ You can override the autodetection by manually setting +

+    -DDEAL_II_WITH_LAPACK=OFF|ON
+      
+

+ +
+
+ + Valid HTML 4.01! + + Valid CSS! +
+ + + diff --git a/doc/readme.html b/doc/readme.html index 90f0c8c065..fa99ac04f1 100644 --- a/doc/readme.html +++ b/doc/readme.html @@ -449,9 +449,8 @@ BLAS (the Basic Linear Algebra Subroutines) and LAPACK ( Linear Algebra Package) are two packages that support low-level linear algebra operations on vectors and dense matrices. Both libraries should be packaged by almost all Linux distributions and found automatically whenever available. - (You might have to install development versions of the libraries for deal.II being able to use them). For details on how to set up deal.II with a non standard BLAS/LAPACK implementation, see the - advanced - setup section in the CMake ReadME. + (You might have to install development versions of the libraries for deal.II being able to use them). For details on how to set up deal.II with a non standard BLAS/LAPACK implementation, + see this page.

-- 2.39.5