https://computation.llnl.gov/projects/sundials/sundials-software (tested with 2.7)
sudo apt-get install cmake
if failed:
sudo apt-get install software-properties-common
sudo add-apt-repository ppa:george-edison55/cmake-3.x
sudo apt-get update
Ref: https://scikits-odes.readthedocs.io/en/latest/installation.html
mkdir build-sundials-2.7.0
cd build-sundials-2.7.0/
cmake -DLAPACK_ENABLE=ON -DCMAKE_INSTALL_PREFIX=<install_path> ../sundials-2.7.0/
make install
OBS: DCMAKE_INSTALL_PREFIX better to ommit
OBS: it may be necessary to add the installation folder to LD_LIBRARY_PATH:
Check:
echo LD_LIBRARY_PATH
Add to .bashrc or .zshrc:
export LD_LIBRARY_PATH=/usr/local/lib
OBS: /usr/local/lib is the default if DCMAKE_INSTALL_PREFIX was omitted.