[packages/sundials] - updated to 2.6.2 (new libsundials_{cvode,cvodes,ida,kinsol} sonames; new libsundials_{arkode,idas}

qboosh qboosh at pld-linux.org
Fri Jan 20 21:10:18 CET 2023


commit bc64d9953cb167f6077dbaad7ed3905467dd36a6
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Fri Jan 20 21:11:04 2023 +0100

    - updated to 2.6.2 (new libsundials_{cvode,cvodes,ida,kinsol} sonames; new libsundials_{arkode,idas} libraries)
    - removed outdated patches; added cmake patch instead to fix new issues after migration to cmake

 sundials-DESTDIR.patch | 270 -------------------------------------------
 sundials-ac.patch      |  12 --
 sundials-cmake.patch   | 306 +++++++++++++++++++++++++++++++++++++++++++++++++
 sundials-format.patch  |  44 -------
 sundials.spec          | 131 ++++++++++++++-------
 5 files changed, 396 insertions(+), 367 deletions(-)
---
diff --git a/sundials.spec b/sundials.spec
index 2ed2065..73a4eb4 100644
--- a/sundials.spec
+++ b/sundials.spec
@@ -1,26 +1,32 @@
 # TODO: MPI support
+#
+# Conditional build:
+%bcond_without	openmp	# OpenMP support
+
 Summary:	SUite of Nonlinear and DIfferential/ALgebraic equation Solvers
 Summary(pl.UTF-8):	Zbiór procedur do rozwiązywania równań nieliniowych i różniczkowych/algebraicznych
 Name:		sundials
-Version:	2.3.0
-Release:	2
+Version:	2.6.2
+Release:	1
 License:	BSD
 Group:		Libraries
-Source0:	https://computation.llnl.gov/casc/sundials/download/code/%{name}-%{version}.tar.gz
-# Source0-md5:	c236f2a7e0e6a03b8fab3d189471b933
-Patch0:		%{name}-DESTDIR.patch
-Patch1:		%{name}-ac.patch
-Patch2:		%{name}-format.patch
-URL:		https://computation.llnl.gov/casc/sundials/
-BuildRequires:	autoconf >= 2.50
+Source0:	https://computing.llnl.gov/sites/default/files/inline-files/%{name}-%{version}.tar.gz
+# Source0-md5:	3deeb0ede9f514184c6bd83ecab77d95
+Patch0:		%{name}-cmake.patch
+URL:		https://computing.llnl.gov/projects/sundials
+BuildRequires:	cmake >= 2.8.1
 BuildRequires:	gcc-fortran
-BuildRequires:	libtool
+BuildRequires:	lapack-devel
+%{?with_openmp:BuildRequires:	libgomp-devel}
 BuildRequires:	rpm-build >= 4.6
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
 SUNDIALS (SUite of Nonlinear and DIfferential/ALgebraic equation
-Solvers) consists of the following four solvers:
+Solvers) consists of the following solvers:
+
+ARKODE: solves ordinary differential equation (ODE) systems based on
+Runge-Kutta methods.
 
 CVODE: solves initial value problems for ordinary differential
 equation (ODE) systems.
@@ -31,6 +37,9 @@ capabilities (forward and adjoint).
 IDA: solves initial value problems for differential-algebraic equation
 (DAE) systems.
 
+IDAS: solves differential-algebraic equation (DAE) systems with
+sensitivity analysis.
+
 KINSOL: solves nonlinear algebraic systems.
 
 %description -l pl.UTF-8
@@ -38,6 +47,9 @@ SUNDIALS (SUite of Nonlinear and DIfferential/ALgebraic equation
 Solvers) to zbiór procedur do rozwiązywania równań nieliniowych i
 różniczkowych/algebraicznych, składający się z czterech części:
 
+ARKODE - rozwiązuje układy równań różniczkowych zwyczajnych (ODE) przy
+użyciu metod Rungego-Kutty.
+
 CVODE - rozwiązuje problemy wartości początkowej dla układów
 równań różniczkowych zwyczajnych (ODE)
 
@@ -47,6 +59,9 @@ funkcjonalność analizy wrażliwości (prostej i sprzężonej).
 IDA - rozwiązuje problemy wartości początkowej dla układów równań
 różniczkowo-algebraicznych (DAE).
 
+IDAS - rozwiązuje układy równań różniczkowo-algebraicznych z analizą
+wrażliwości.
+
 KINSOL - rozwiązuje układy nieliniowych równań algebraicznych.
 
 %package devel
@@ -90,29 +105,27 @@ Dokumentacja API bibliotek SUNDIALS.
 %prep
 %setup -q
 %patch0 -p1
-%patch1 -p1
-%patch2 -p1
 
 %build
-%{__libtoolize}
-%{__mv} ltmain.sh config
-%{__aclocal} -I config
-%{__autoconf}
-%configure \
-	F77="gfortran" \
-	--enable-examples \
-	--disable-mpi \
-	--enable-shared
+install -d build
+cd build
+%cmake .. \
+	-DEXAMPLES_INSTALL_PATH=%{_examplesdir}/%{name}-%{version} \
+	-DFCMIX_ENABLE=ON \
+	-DKLU_ENABLE=ON \
+	-DLAPACK_ENABLE=ON \
+	%{?with_openmp:-DOPENMP_ENABLE=ON} \
+	-DPTHREAD_ENABLE=ON
+
+# SUPERLUMT_ENABLE?
 
 %{__make}
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
 
-%{__make} install \
-	DESTDIR=$RPM_BUILD_ROOT \
-	EXS_INSTDIR=$RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+%{__make} -C build install \
+	DESTDIR=$RPM_BUILD_ROOT
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -123,42 +136,66 @@ rm -rf $RPM_BUILD_ROOT
 %files
 %defattr(644,root,root,755)
 %doc LICENSE README
+%attr(755,root,root) %{_libdir}/libsundials_arkode.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libsundials_arkode.so.1
 %attr(755,root,root) %{_libdir}/libsundials_cvode.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libsundials_cvode.so.0
+%attr(755,root,root) %ghost %{_libdir}/libsundials_cvode.so.1
 %attr(755,root,root) %{_libdir}/libsundials_cvodes.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libsundials_cvodes.so.1
+%attr(755,root,root) %ghost %{_libdir}/libsundials_cvodes.so.2
 %attr(755,root,root) %{_libdir}/libsundials_ida.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libsundials_ida.so.1
+%attr(755,root,root) %ghost %{_libdir}/libsundials_ida.so.2
+%attr(755,root,root) %{_libdir}/libsundials_idas.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libsundials_idas.so.0
 %attr(755,root,root) %{_libdir}/libsundials_kinsol.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libsundials_kinsol.so.0
+%attr(755,root,root) %ghost %{_libdir}/libsundials_kinsol.so.1
+%if %{with openmp}
+%attr(755,root,root) %{_libdir}/libsundials_nvecopenmp.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libsundials_nvecopenmp.so.0
+%endif
+%attr(755,root,root) %{_libdir}/libsundials_nvecpthreads.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libsundials_nvecpthreads.so.0
 %attr(755,root,root) %{_libdir}/libsundials_nvecserial.so.*.*.*
 %attr(755,root,root) %ghost %{_libdir}/libsundials_nvecserial.so.0
+# Fortran - shared
+%if %{with openmp}
+%attr(755,root,root) %{_libdir}/libsundials_fnvecopenmp.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libsundials_fnvecopenmp.so.0
+%endif
+%attr(755,root,root) %{_libdir}/libsundials_fnvecpthreads.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libsundials_fnvecpthreads.so.0
+%attr(755,root,root) %{_libdir}/libsundials_fnvecserial.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libsundials_fnvecserial.so.0
 
 %files devel
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_bindir}/sundials-config
+%attr(755,root,root) %{_libdir}/libsundials_arkode.so
 %attr(755,root,root) %{_libdir}/libsundials_cvode.so
 %attr(755,root,root) %{_libdir}/libsundials_cvodes.so
 %attr(755,root,root) %{_libdir}/libsundials_ida.so
+%attr(755,root,root) %{_libdir}/libsundials_idas.so
 %attr(755,root,root) %{_libdir}/libsundials_kinsol.so
+%if %{with openmp}
+%attr(755,root,root) %{_libdir}/libsundials_nvecopenmp.so
+%endif
+%attr(755,root,root) %{_libdir}/libsundials_nvecpthreads.so
 %attr(755,root,root) %{_libdir}/libsundials_nvecserial.so
-%{_libdir}/libsundials_cvode.la
-%{_libdir}/libsundials_cvodes.la
-%{_libdir}/libsundials_ida.la
-%{_libdir}/libsundials_kinsol.la
-%{_libdir}/libsundials_nvecserial.la
-# Fortran
+# Fortran - shared
+%if %{with openmp}
+%attr(755,root,root) %{_libdir}/libsundials_fnvecopenmp.so
+%endif
+%attr(755,root,root) %{_libdir}/libsundials_fnvecpthreads.so
+%attr(755,root,root) %{_libdir}/libsundials_fnvecserial.so
+# Fortran - static only
+%{_libdir}/libsundials_farkode.a
 %{_libdir}/libsundials_fcvode.a
-%{_libdir}/libsundials_fcvode.la
 %{_libdir}/libsundials_fida.a
-%{_libdir}/libsundials_fida.la
 %{_libdir}/libsundials_fkinsol.a
-%{_libdir}/libsundials_fkinsol.la
 %{_libdir}/libsundials_fnvecserial.a
-%{_libdir}/libsundials_fnvecserial.la
+%{_includedir}/arkode
 %{_includedir}/cvode
 %{_includedir}/cvodes
 %{_includedir}/ida
+%{_includedir}/idas
 %{_includedir}/kinsol
 %{_includedir}/nvector
 %{_includedir}/sundials
@@ -166,11 +203,23 @@ rm -rf $RPM_BUILD_ROOT
 
 %files static
 %defattr(644,root,root,755)
+%{_libdir}/libsundials_arkode.a
 %{_libdir}/libsundials_cvode.a
 %{_libdir}/libsundials_cvodes.a
 %{_libdir}/libsundials_ida.a
+%{_libdir}/libsundials_idas.a
 %{_libdir}/libsundials_kinsol.a
+%if %{with openmp}
+%{_libdir}/libsundials_nvecopenmp.a
+%endif
+%{_libdir}/libsundials_nvecpthreads.a
 %{_libdir}/libsundials_nvecserial.a
+# Fortran
+%if %{with openmp}
+%{_libdir}/libsundials_fnvecopenmp.a
+%endif
+%{_libdir}/libsundials_fnvecpthreads.a
+%{_libdir}/libsundials_fnvecserial.a
 
 %files apidocs
 %defattr(644,root,root,755)
diff --git a/sundials-DESTDIR.patch b/sundials-DESTDIR.patch
deleted file mode 100644
index 49d034a..0000000
--- a/sundials-DESTDIR.patch
+++ /dev/null
@@ -1,270 +0,0 @@
-diff -ur sundials-2.3.0/src/cvode/fcmix/Makefile.in sundials-2.3.0-DESTDIR/src/cvode/fcmix/Makefile.in
---- sundials-2.3.0/src/cvode/fcmix/Makefile.in	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0-DESTDIR/src/cvode/fcmix/Makefile.in	2009-03-02 17:26:53.000000000 +0100
-@@ -57,8 +57,8 @@
- 	$(LIBTOOL) --mode=link $(CC) $(CFLAGS) -o $(FCVODE_LIB) $(FCVODE_LIB_FILES) -rpath $(libdir) $(LDFLAGS) $(LIBS) -static -version-info $(LIB_REVISION)
- 
- install: $(FCVODE_LIB)
--	$(mkinstalldirs) $(libdir)
--	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(FCVODE_LIB) $(libdir)
-+	$(mkinstalldirs) $(DESTDIR)$(libdir)
-+	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(FCVODE_LIB) $(DESTDIR)$(libdir)
- 
- uninstall:
- 	$(LIBTOOL) --mode=uninstall rm -f $(libdir)/$(FCVODE_LIB)
-diff -ur sundials-2.3.0/src/cvode/Makefile.in sundials-2.3.0-DESTDIR/src/cvode/Makefile.in
---- sundials-2.3.0/src/cvode/Makefile.in	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0-DESTDIR/src/cvode/Makefile.in	2009-03-02 17:27:22.000000000 +0100
-@@ -69,20 +69,20 @@
- 	$(LIBTOOL) --mode=link $(CC) $(CFLAGS) -o $(CVODE_LIB) $(CVODE_LIB_FILES) $(SHARED_LIB_FILES) -rpath $(libdir) $(LDFLAGS) $(LIBS) -version-info $(LIB_REVISION)
- 
- install: $(CVODE_LIB)
--	$(mkinstalldirs) $(includedir)/cvode
--	$(mkinstalldirs) $(libdir)
--	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(CVODE_LIB) $(libdir)
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode.h         $(includedir)/cvode/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_dense.h   $(includedir)/cvode/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_band.h    $(includedir)/cvode/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_diag.h    $(includedir)/cvode/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_spils.h   $(includedir)/cvode/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_spbcgs.h  $(includedir)/cvode/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_spgmr.h   $(includedir)/cvode/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_sptfqmr.h $(includedir)/cvode/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_bandpre.h $(includedir)/cvode/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_bbdpre.h  $(includedir)/cvode/
--	$(INSTALL_HEADER) $(top_srcdir)/src/cvode/cvode_impl.h        $(includedir)/cvode/
-+	$(mkinstalldirs) $(DESTDIR)$(includedir)/cvode
-+	$(mkinstalldirs) $(DESTDIR)$(libdir)
-+	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(CVODE_LIB) $(DESTDIR)$(libdir)
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode.h         $(DESTDIR)$(includedir)/cvode/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_dense.h   $(DESTDIR)$(includedir)/cvode/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_band.h    $(DESTDIR)$(includedir)/cvode/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_diag.h    $(DESTDIR)$(includedir)/cvode/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_spils.h   $(DESTDIR)$(includedir)/cvode/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_spbcgs.h  $(DESTDIR)$(includedir)/cvode/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_spgmr.h   $(DESTDIR)$(includedir)/cvode/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_sptfqmr.h $(DESTDIR)$(includedir)/cvode/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_bandpre.h $(DESTDIR)$(includedir)/cvode/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvode/cvode_bbdpre.h  $(DESTDIR)$(includedir)/cvode/
-+	$(INSTALL_HEADER) $(top_srcdir)/src/cvode/cvode_impl.h        $(DESTDIR)$(includedir)/cvode/
- 
- uninstall:
- 	$(LIBTOOL) --mode=uninstall rm -f $(libdir)/$(CVODE_LIB)
-diff -ur sundials-2.3.0/src/cvodes/Makefile.in sundials-2.3.0-DESTDIR/src/cvodes/Makefile.in
---- sundials-2.3.0/src/cvodes/Makefile.in	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0-DESTDIR/src/cvodes/Makefile.in	2009-03-02 17:27:47.000000000 +0100
-@@ -69,20 +69,20 @@
- 	$(LIBTOOL) --mode=link $(CC) $(CFLAGS) -o $(CVODES_LIB) $(CVODES_LIB_FILES) $(SHARED_LIB_FILES) -rpath $(libdir) $(LDFLAGS) $(LIBS) -version-info $(LIB_REVISION)
- 
- install: $(CVODES_LIB)
--	$(mkinstalldirs) $(includedir)/cvodes
--	$(mkinstalldirs) $(libdir)
--	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(CVODES_LIB) $(libdir)
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes.h         $(includedir)/cvodes/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_dense.h   $(includedir)/cvodes/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_band.h    $(includedir)/cvodes/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_diag.h    $(includedir)/cvodes/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_spils.h   $(includedir)/cvodes/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_spbcgs.h  $(includedir)/cvodes/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_spgmr.h   $(includedir)/cvodes/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_sptfqmr.h $(includedir)/cvodes/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_bandpre.h $(includedir)/cvodes/
--	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_bbdpre.h  $(includedir)/cvodes/
--	$(INSTALL_HEADER) $(top_srcdir)/src/cvodes/cvodes_impl.h        $(includedir)/cvodes/
-+	$(mkinstalldirs) $(DESTDIR)$(includedir)/cvodes
-+	$(mkinstalldirs) $(DESTDIR)$(libdir)
-+	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(CVODES_LIB) $(DESTDIR)$(libdir)
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes.h         $(DESTDIR)$(includedir)/cvodes/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_dense.h   $(DESTDIR)$(includedir)/cvodes/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_band.h    $(DESTDIR)$(includedir)/cvodes/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_diag.h    $(DESTDIR)$(includedir)/cvodes/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_spils.h   $(DESTDIR)$(includedir)/cvodes/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_spbcgs.h  $(DESTDIR)$(includedir)/cvodes/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_spgmr.h   $(DESTDIR)$(includedir)/cvodes/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_sptfqmr.h $(DESTDIR)$(includedir)/cvodes/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_bandpre.h $(DESTDIR)$(includedir)/cvodes/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/cvodes/cvodes_bbdpre.h  $(DESTDIR)$(includedir)/cvodes/
-+	$(INSTALL_HEADER) $(top_srcdir)/src/cvodes/cvodes_impl.h        $(DESTDIR)$(includedir)/cvodes/
- 
- uninstall:
- 	$(LIBTOOL) --mode=uninstall rm -f $(libdir)/$(CVODES_LIB)
-diff -ur sundials-2.3.0/src/ida/fcmix/Makefile.in sundials-2.3.0-DESTDIR/src/ida/fcmix/Makefile.in
---- sundials-2.3.0/src/ida/fcmix/Makefile.in	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0-DESTDIR/src/ida/fcmix/Makefile.in	2009-03-02 17:27:57.000000000 +0100
-@@ -57,8 +57,8 @@
- 	$(LIBTOOL) --mode=link $(CC) $(CFLAGS) -o $(FIDA_LIB) $(FIDA_LIB_FILES) -rpath $(libdir) $(LDFLAGS) $(LIBS) -static -version-info $(LIB_REVISION)
- 
- install: $(FIDA_LIB)
--	$(mkinstalldirs) $(libdir)
--	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(FIDA_LIB) $(libdir)
-+	$(mkinstalldirs) $(DESTDIR)$(libdir)
-+	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(FIDA_LIB) $(DESTDIR)$(libdir)
- 
- uninstall:
- 	$(LIBTOOL) --mode=uninstall rm -f $(libdir)/$(FIDA_LIB)
-diff -ur sundials-2.3.0/src/ida/Makefile.in sundials-2.3.0-DESTDIR/src/ida/Makefile.in
---- sundials-2.3.0/src/ida/Makefile.in	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0-DESTDIR/src/ida/Makefile.in	2009-03-02 17:28:16.000000000 +0100
-@@ -69,18 +69,18 @@
- 	$(LIBTOOL) --mode=link $(CC) $(CFLAGS) -o $(IDA_LIB) $(IDA_LIB_FILES) $(SHARED_LIB_FILES) -rpath $(libdir) $(LDFLAGS) $(LIBS) -version-info $(LIB_REVISION)
- 
- install: $(IDA_LIB)
--	$(mkinstalldirs) $(includedir)/ida
--	$(mkinstalldirs) $(libdir)
--	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(IDA_LIB) $(libdir)
--	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida.h         $(includedir)/ida/
--	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_dense.h   $(includedir)/ida/
--	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_band.h    $(includedir)/ida/
--	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_spbcgs.h  $(includedir)/ida/
--	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_spgmr.h   $(includedir)/ida/
--	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_sptfqmr.h $(includedir)/ida/
--	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_bbdpre.h  $(includedir)/ida/
--	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_spils.h   $(includedir)/ida/
--	$(INSTALL_HEADER) $(top_srcdir)/src/ida/ida_impl.h        $(includedir)/ida/
-+	$(mkinstalldirs) $(DESTDIR)$(includedir)/ida
-+	$(mkinstalldirs) $(DESTDIR)$(libdir)
-+	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(IDA_LIB) $(DESTDIR)$(libdir)
-+	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida.h         $(DESTDIR)$(includedir)/ida/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_dense.h   $(DESTDIR)$(includedir)/ida/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_band.h    $(DESTDIR)$(includedir)/ida/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_spbcgs.h  $(DESTDIR)$(includedir)/ida/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_spgmr.h   $(DESTDIR)$(includedir)/ida/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_sptfqmr.h $(DESTDIR)$(includedir)/ida/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_bbdpre.h  $(DESTDIR)$(includedir)/ida/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/ida/ida_spils.h   $(DESTDIR)$(includedir)/ida/
-+	$(INSTALL_HEADER) $(top_srcdir)/src/ida/ida_impl.h        $(DESTDIR)$(includedir)/ida/
- 
- uninstall:
- 	$(LIBTOOL) --mode=uninstall rm -f $(libdir)/$(IDA_LIB)
-diff -ur sundials-2.3.0/src/kinsol/fcmix/Makefile.in sundials-2.3.0-DESTDIR/src/kinsol/fcmix/Makefile.in
---- sundials-2.3.0/src/kinsol/fcmix/Makefile.in	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0-DESTDIR/src/kinsol/fcmix/Makefile.in	2009-03-02 17:28:26.000000000 +0100
-@@ -57,8 +57,8 @@
- 	$(LIBTOOL) --mode=link $(CC) $(CFLAGS) -o $(FKINSOL_LIB) $(FKINSOL_LIB_FILES) -rpath $(libdir) $(LDFLAGS) $(LIBS) -static -version-info $(LIB_REVISION)
- 
- install: $(FKINSOL_LIB)
--	$(mkinstalldirs) $(libdir)
--	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(FKINSOL_LIB) $(libdir)
-+	$(mkinstalldirs) $(DESTDIR)$(libdir)
-+	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(FKINSOL_LIB) $(DESTDIR)$(libdir)
- 
- uninstall:
- 	$(LIBTOOL) --mode=uninstall rm -f $(libdir)/$(FKINSOL_LIB)
-diff -ur sundials-2.3.0/src/kinsol/Makefile.in sundials-2.3.0-DESTDIR/src/kinsol/Makefile.in
---- sundials-2.3.0/src/kinsol/Makefile.in	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0-DESTDIR/src/kinsol/Makefile.in	2009-03-02 17:28:44.000000000 +0100
-@@ -69,18 +69,18 @@
- 	$(LIBTOOL) --mode=link $(CC) $(CFLAGS) -o $(KINSOL_LIB) $(KINSOL_LIB_FILES) $(SHARED_LIB_FILES) -rpath $(libdir) $(LDFLAGS) $(LIBS) -version-info $(LIB_REVISION)
- 
- install: $(KINSOL_LIB)
--	$(mkinstalldirs) $(includedir)/kinsol
--	$(mkinstalldirs) $(libdir)
--	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(KINSOL_LIB) $(libdir)
--	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol.h         $(includedir)/kinsol/
--	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_dense.h   $(includedir)/kinsol/
--	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_band.h    $(includedir)/kinsol/
--	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_spgmr.h   $(includedir)/kinsol/
--	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_spbcgs.h  $(includedir)/kinsol/
--	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_sptfqmr.h $(includedir)/kinsol/
--	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_bbdpre.h  $(includedir)/kinsol/
--	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_spils.h   $(includedir)/kinsol/
--	$(INSTALL_HEADER) $(top_srcdir)/src/kinsol/kinsol_impl.h        $(includedir)/kinsol/
-+	$(mkinstalldirs) $(DESTDIR)$(includedir)/kinsol
-+	$(mkinstalldirs) $(DESTDIR)$(libdir)
-+	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(KINSOL_LIB) $(DESTDIR)$(libdir)
-+	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol.h         $(DESTDIR)$(includedir)/kinsol/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_dense.h   $(DESTDIR)$(includedir)/kinsol/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_band.h    $(DESTDIR)$(includedir)/kinsol/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_spgmr.h   $(DESTDIR)$(includedir)/kinsol/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_spbcgs.h  $(DESTDIR)$(includedir)/kinsol/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_sptfqmr.h $(DESTDIR)$(includedir)/kinsol/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_bbdpre.h  $(DESTDIR)$(includedir)/kinsol/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/kinsol/kinsol_spils.h   $(DESTDIR)$(includedir)/kinsol/
-+	$(INSTALL_HEADER) $(top_srcdir)/src/kinsol/kinsol_impl.h        $(DESTDIR)$(includedir)/kinsol/
- 
- uninstall:
- 	$(LIBTOOL) --mode=uninstall rm -f $(libdir)/$(KINSOL_LIB)
-diff -ur sundials-2.3.0/src/nvec_par/Makefile.in sundials-2.3.0-DESTDIR/src/nvec_par/Makefile.in
---- sundials-2.3.0/src/nvec_par/Makefile.in	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0-DESTDIR/src/nvec_par/Makefile.in	2009-03-02 17:29:08.000000000 +0100
-@@ -74,13 +74,13 @@
- 	 fi
- 
- install: $(NVECPAR_LIB) $(FNVECPAR_LIB)
--	$(mkinstalldirs) $(includedir)/nvector
--	$(mkinstalldirs) $(libdir)
--	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(NVECPAR_LIB) $(libdir)
--	$(INSTALL_HEADER) $(top_srcdir)/include/nvector/nvector_parallel.h $(includedir)/nvector/
-+	$(mkinstalldirs) $(DESTDIR)$(includedir)/nvector
-+	$(mkinstalldirs) $(DESTDIR)$(libdir)
-+	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(NVECPAR_LIB) $(DESTDIR)$(libdir)
-+	$(INSTALL_HEADER) $(top_srcdir)/include/nvector/nvector_parallel.h $(DESTDIR)$(includedir)/nvector/
- 	@if test "X${FCMIX_ENABLED}" = "Xyes"; then                                    \
--	   echo "${LIBTOOL} --mode=install ${INSTALL_LIB} ${FNVECPAR_LIB} ${libdir}" ; \
--	   ${LIBTOOL} --mode=install ${INSTALL_LIB} ${FNVECPAR_LIB} ${libdir} ;        \
-+	   echo "${LIBTOOL} --mode=install ${INSTALL_LIB} ${FNVECPAR_LIB} $(DESTDIR)${libdir}" ; \
-+	   ${LIBTOOL} --mode=install ${INSTALL_LIB} ${FNVECPAR_LIB} $(DESTDIR)${libdir} ;        \
- 	 fi
- 
- uninstall:
-diff -ur sundials-2.3.0/src/nvec_ser/Makefile.in sundials-2.3.0-DESTDIR/src/nvec_ser/Makefile.in
---- sundials-2.3.0/src/nvec_ser/Makefile.in	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0-DESTDIR/src/nvec_ser/Makefile.in	2009-03-02 17:29:23.000000000 +0100
-@@ -71,13 +71,13 @@
- 	fi
- 
- install: $(NVECSER_LIB) $(FNVECSER_LIB)
--	$(mkinstalldirs) $(includedir)/nvector
--	$(mkinstalldirs) $(libdir)
--	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(NVECSER_LIB) $(libdir)
--	$(INSTALL_HEADER) $(top_srcdir)/include/nvector/nvector_serial.h $(includedir)/nvector/
-+	$(mkinstalldirs) $(DESTDIR)$(includedir)/nvector
-+	$(mkinstalldirs) $(DESTDIR)$(libdir)
-+	$(LIBTOOL) --mode=install $(INSTALL_LIB) $(NVECSER_LIB) $(DESTDIR)$(libdir)
-+	$(INSTALL_HEADER) $(top_srcdir)/include/nvector/nvector_serial.h $(DESTDIR)$(includedir)/nvector/
- 	@if test "X${FCMIX_ENABLED}" = "Xyes"; then                                    \
--	   echo "${LIBTOOL} --mode=install ${INSTALL_LIB} ${FNVECSER_LIB} ${libdir}" ; \
--	   ${LIBTOOL} --mode=install ${INSTALL_LIB} ${FNVECSER_LIB} ${libdir} ;        \
-+	   echo "${LIBTOOL} --mode=install ${INSTALL_LIB} ${FNVECSER_LIB} $(DESTDIR)${libdir}" ; \
-+	   ${LIBTOOL} --mode=install ${INSTALL_LIB} ${FNVECSER_LIB} $(DESTDIR)${libdir} ;        \
- 	 fi
- 
- uninstall:
-diff -ur sundials-2.3.0/src/sundials/Makefile.in sundials-2.3.0-DESTDIR/src/sundials/Makefile.in
---- sundials-2.3.0/src/sundials/Makefile.in	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0-DESTDIR/src/sundials/Makefile.in	2009-03-02 17:29:49.000000000 +0100
-@@ -52,20 +52,20 @@
- all: $(SHARED_LIB_FILES)
- 
- install: $(SHARED_LIB_FILES)
--	$(mkinstalldirs)  $(includedir)/sundials
--	$(mkinstalldirs)  $(bindir)
--	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_band.h       $(includedir)/sundials/
--	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_dense.h      $(includedir)/sundials/
--	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_iterative.h  $(includedir)/sundials/
--	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_math.h       $(includedir)/sundials/
--	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_types.h      $(includedir)/sundials/
--	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_nvector.h    $(includedir)/sundials/
--	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_smalldense.h $(includedir)/sundials/
--	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_spgmr.h      $(includedir)/sundials/
--	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_spbcgs.h     $(includedir)/sundials/
--	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_sptfqmr.h    $(includedir)/sundials/
--	$(INSTALL_HEADER) $(top_builddir)/src/sundials/sundials_config.h       $(includedir)/sundials/
--	$(INSTALL_PROG)   $(top_builddir)/sundials-config                      $(bindir)/
-+	$(mkinstalldirs)  $(DESTDIR)$(includedir)/sundials
-+	$(mkinstalldirs)  $(DESTDIR)$(bindir)
-+	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_band.h       $(DESTDIR)$(includedir)/sundials/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_dense.h      $(DESTDIR)$(includedir)/sundials/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_iterative.h  $(DESTDIR)$(includedir)/sundials/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_math.h       $(DESTDIR)$(includedir)/sundials/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_types.h      $(DESTDIR)$(includedir)/sundials/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_nvector.h    $(DESTDIR)$(includedir)/sundials/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_smalldense.h $(DESTDIR)$(includedir)/sundials/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_spgmr.h      $(DESTDIR)$(includedir)/sundials/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_spbcgs.h     $(DESTDIR)$(includedir)/sundials/
-+	$(INSTALL_HEADER) $(top_srcdir)/include/sundials/sundials_sptfqmr.h    $(DESTDIR)$(includedir)/sundials/
-+	$(INSTALL_HEADER) $(top_builddir)/src/sundials/sundials_config.h       $(DESTDIR)$(includedir)/sundials/
-+	$(INSTALL_PROG)   $(top_builddir)/sundials-config                      $(DESTDIR)$(bindir)/
- 
- uninstall:
- 	rm -f $(includedir)/sundials/sundials_band.h
diff --git a/sundials-ac.patch b/sundials-ac.patch
deleted file mode 100644
index dcee414..0000000
--- a/sundials-ac.patch
+++ /dev/null
@@ -1,12 +0,0 @@
---- sundials-2.3.0/config/cust_general.m4.orig	2006-11-07 00:18:35.000000000 +0100
-+++ sundials-2.3.0/config/cust_general.m4	2023-01-17 06:27:45.147214910 +0100
-@@ -78,7 +78,8 @@ AS_IF([_AC_EVAL_STDERR($ac_linkonly) &&
- 	 AC_TRY_COMMAND([test -s conftest$ac_exeext])],
-       [$2],
-       [_AC_MSG_LOG_CONFTEST_GENERAL
--m4_ifvaln([$3], [$3])dnl])[]dnl
-+m4_ifvaln([$3], [$3])dnl
-+])
- rm -f conftest.err conftest.$ac_objext \
-       conftest$ac_exeext m4_ifval([$1], [conftest.$ac_ext])[]dnl
- ])# _AC_LINKONLY_IFELSE
diff --git a/sundials-cmake.patch b/sundials-cmake.patch
new file mode 100644
index 0000000..ef68040
--- /dev/null
+++ b/sundials-cmake.patch
@@ -0,0 +1,306 @@
+--- sundials-2.6.2/src/arkode/CMakeLists.txt.orig	2015-07-31 02:07:37.000000000 +0200
++++ sundials-2.6.2/src/arkode/CMakeLists.txt	2023-01-19 17:32:41.649626680 +0100
+@@ -127,7 +127,7 @@ IF(BUILD_STATIC_LIBS)
+     PROPERTIES OUTPUT_NAME sundials_arkode CLEAN_DIRECT_OUTPUT 1)
+ 
+   # Install the ARKODE library
+-  INSTALL(TARGETS sundials_arkode_static DESTINATION lib)
++  INSTALL(TARGETS sundials_arkode_static DESTINATION lib${LIB_SUFFIX})
+ 
+ ENDIF(BUILD_STATIC_LIBS)
+ 
+@@ -138,6 +138,8 @@ IF(BUILD_SHARED_LIBS)
+   ADD_LIBRARY(sundials_arkode_shared SHARED 
+     ${arkode_SOURCES}  ${arkode_BL_SOURCES}  ${shared_SOURCES})
+ 
++  TARGET_LINK_LIBRARIES(sundials_arkode_shared lapack m)
++
+   # Set the library name and make sure it is not deleted
+   SET_TARGET_PROPERTIES(sundials_arkode_shared
+     PROPERTIES OUTPUT_NAME sundials_arkode CLEAN_DIRECT_OUTPUT 1)
+@@ -147,7 +149,7 @@ IF(BUILD_SHARED_LIBS)
+     PROPERTIES VERSION ${arkodelib_VERSION} SOVERSION ${arkodelib_SOVERSION})
+ 
+   # Install the ARKODE library
+-  INSTALL(TARGETS sundials_arkode_shared DESTINATION lib)
++  INSTALL(TARGETS sundials_arkode_shared DESTINATION lib${LIB_SUFFIX})
+ 
+ ENDIF(BUILD_SHARED_LIBS)
+ 
+--- sundials-2.6.2/src/cvode/CMakeLists.txt.orig	2015-07-31 02:08:00.000000000 +0200
++++ sundials-2.6.2/src/cvode/CMakeLists.txt	2023-01-19 17:34:07.565827899 +0100
+@@ -118,7 +118,7 @@ IF(BUILD_STATIC_LIBS)
+     PROPERTIES OUTPUT_NAME sundials_cvode CLEAN_DIRECT_OUTPUT 1)
+ 
+   # Install the CVODE library
+-  INSTALL(TARGETS sundials_cvode_static DESTINATION lib)
++  INSTALL(TARGETS sundials_cvode_static DESTINATION lib${LIB_SUFFIX})
+ 
+ ENDIF(BUILD_STATIC_LIBS)
+ 
+@@ -129,6 +129,8 @@ IF(BUILD_SHARED_LIBS)
+   ADD_LIBRARY(sundials_cvode_shared SHARED 
+     ${cvode_SOURCES}  ${cvode_BL_SOURCES}  ${shared_SOURCES})
+ 
++  TARGET_LINK_LIBRARIES(sundials_cvode_shared lapack m)
++
+   # Set the library name and make sure it is not deleted
+   SET_TARGET_PROPERTIES(sundials_cvode_shared
+     PROPERTIES OUTPUT_NAME sundials_cvode CLEAN_DIRECT_OUTPUT 1)
+@@ -138,7 +140,7 @@ IF(BUILD_SHARED_LIBS)
+     PROPERTIES VERSION ${cvodelib_VERSION} SOVERSION ${cvodelib_SOVERSION})
+ 
+   # Install the CVODE library
+-  INSTALL(TARGETS sundials_cvode_shared DESTINATION lib)
++  INSTALL(TARGETS sundials_cvode_shared DESTINATION lib${LIB_SUFFIX})
+ 
+ ENDIF(BUILD_SHARED_LIBS)
+ 
+--- sundials-2.6.2/src/nvec_ser/CMakeLists.txt.orig	2015-07-31 02:07:26.000000000 +0200
++++ sundials-2.6.2/src/nvec_ser/CMakeLists.txt	2023-01-20 06:13:11.683593284 +0100
+@@ -44,7 +44,7 @@ IF(BUILD_STATIC_LIBS)
+   ADD_LIBRARY(sundials_nvecserial_static STATIC ${nvecserial_SOURCES} ${shared_SOURCES})
+   SET_TARGET_PROPERTIES(sundials_nvecserial_static
+     PROPERTIES OUTPUT_NAME sundials_nvecserial CLEAN_DIRECT_OUTPUT 1)
+-  INSTALL(TARGETS sundials_nvecserial_static DESTINATION lib)
++  INSTALL(TARGETS sundials_nvecserial_static DESTINATION lib${LIB_SUFFIX})
+ ENDIF(BUILD_STATIC_LIBS)
+ 
+ # Rules for building and installing the shared library:
+@@ -54,11 +54,12 @@ ENDIF(BUILD_STATIC_LIBS)
+ #  - Install the NVECSERIAL library
+ IF(BUILD_SHARED_LIBS)
+   ADD_LIBRARY(sundials_nvecserial_shared SHARED ${nvecserial_SOURCES} ${shared_SOURCES})
++  TARGET_LINK_LIBRARIES(sundials_nvecserial_shared m)
+   SET_TARGET_PROPERTIES(sundials_nvecserial_shared
+     PROPERTIES OUTPUT_NAME sundials_nvecserial CLEAN_DIRECT_OUTPUT 1)
+   SET_TARGET_PROPERTIES(sundials_nvecserial_shared
+     PROPERTIES VERSION ${nveclib_VERSION} SOVERSION ${nveclib_SOVERSION})
+-  INSTALL(TARGETS sundials_nvecserial_shared DESTINATION lib)
++  INSTALL(TARGETS sundials_nvecserial_shared DESTINATION lib${LIB_SUFFIX})
+ ENDIF(BUILD_SHARED_LIBS)
+ 
+ # Install the NVECSERIAL header files
+@@ -71,15 +72,16 @@ IF(FCMIX_ENABLE AND F77_FOUND)
+     ADD_LIBRARY(sundials_fnvecserial_static STATIC ${fnvecserial_SOURCES})
+     SET_TARGET_PROPERTIES(sundials_fnvecserial_static
+       PROPERTIES OUTPUT_NAME sundials_fnvecserial CLEAN_DIRECT_OUTPUT 1)
+-    INSTALL(TARGETS sundials_fnvecserial_static DESTINATION lib)
++    INSTALL(TARGETS sundials_fnvecserial_static DESTINATION lib${LIB_SUFFIX})
+   ENDIF(BUILD_STATIC_LIBS)
+   IF(BUILD_SHARED_LIBS)
+     ADD_LIBRARY(sundials_fnvecserial_shared ${fnvecserial_SOURCES})
++    TARGET_LINK_LIBRARIES(sundials_fnvecserial_shared sundials_nvecserial_shared)
+     SET_TARGET_PROPERTIES(sundials_fnvecserial_shared
+       PROPERTIES OUTPUT_NAME sundials_fnvecserial CLEAN_DIRECT_OUTPUT 1)
+     SET_TARGET_PROPERTIES(sundials_fnvecserial_shared 
+       PROPERTIES VERSION ${nveclib_VERSION} SOVERSION ${nveclib_SOVERSION})
+-    INSTALL(TARGETS sundials_fnvecserial_shared DESTINATION lib)
++    INSTALL(TARGETS sundials_fnvecserial_shared DESTINATION lib${LIB_SUFFIX})
+   ENDIF(BUILD_SHARED_LIBS)
+ ENDIF(FCMIX_ENABLE AND F77_FOUND)
+ 
+--- sundials-2.6.2/src/nvec_openmp/CMakeLists.txt.orig	2015-07-31 02:07:26.000000000 +0200
++++ sundials-2.6.2/src/nvec_openmp/CMakeLists.txt	2023-01-20 06:13:23.611528600 +0100
+@@ -51,7 +51,7 @@ IF(BUILD_STATIC_LIBS)
+   ADD_LIBRARY(sundials_nvecopenmp_static STATIC ${nvecopenmp_SOURCES} ${shared_SOURCES})
+   SET_TARGET_PROPERTIES(sundials_nvecopenmp_static
+     PROPERTIES OUTPUT_NAME sundials_nvecopenmp CLEAN_DIRECT_OUTPUT 1)
+-  INSTALL(TARGETS sundials_nvecopenmp_static DESTINATION lib)
++  INSTALL(TARGETS sundials_nvecopenmp_static DESTINATION lib${LIB_SUFFIX})
+ ENDIF(BUILD_STATIC_LIBS)
+ 
+ # Rules for building and installing the shared library:
+@@ -61,11 +61,12 @@ ENDIF(BUILD_STATIC_LIBS)
+ #  - Install the NVECOPENMP library
+ IF(BUILD_SHARED_LIBS)
+   ADD_LIBRARY(sundials_nvecopenmp_shared SHARED ${nvecopenmp_SOURCES} ${shared_SOURCES})
++  TARGET_LINK_LIBRARIES(sundials_nvecopenmp_shared m)
+   SET_TARGET_PROPERTIES(sundials_nvecopenmp_shared
+     PROPERTIES OUTPUT_NAME sundials_nvecopenmp CLEAN_DIRECT_OUTPUT 1)
+   SET_TARGET_PROPERTIES(sundials_nvecopenmp_shared
+     PROPERTIES VERSION ${nveclib_VERSION} SOVERSION ${nveclib_SOVERSION})
+-  INSTALL(TARGETS sundials_nvecopenmp_shared DESTINATION lib)
++  INSTALL(TARGETS sundials_nvecopenmp_shared DESTINATION lib${LIB_SUFFIX})
+ ENDIF(BUILD_SHARED_LIBS)
+ 
+ # Install the NVECOPENMP header files
+@@ -78,15 +79,16 @@ IF(FCMIX_ENABLE AND F77_FOUND)
+     ADD_LIBRARY(sundials_fnvecopenmp_static STATIC ${fnvecopenmp_SOURCES})
+     SET_TARGET_PROPERTIES(sundials_fnvecopenmp_static
+       PROPERTIES OUTPUT_NAME sundials_fnvecopenmp CLEAN_DIRECT_OUTPUT 1)
+-    INSTALL(TARGETS sundials_fnvecopenmp_static DESTINATION lib)
++    INSTALL(TARGETS sundials_fnvecopenmp_static DESTINATION lib${LIB_SUFFIX})
+   ENDIF(BUILD_STATIC_LIBS)
+   IF(BUILD_SHARED_LIBS)
+     ADD_LIBRARY(sundials_fnvecopenmp_shared ${fnvecopenmp_SOURCES})
++    TARGET_LINK_LIBRARIES(sundials_fnvecopenmp_shared sundials_nvecopenmp_shared)
+     SET_TARGET_PROPERTIES(sundials_fnvecopenmp_shared
+       PROPERTIES OUTPUT_NAME sundials_fnvecopenmp CLEAN_DIRECT_OUTPUT 1)
+     SET_TARGET_PROPERTIES(sundials_fnvecopenmp_shared 
+       PROPERTIES VERSION ${nveclib_VERSION} SOVERSION ${nveclib_SOVERSION})
+-    INSTALL(TARGETS sundials_fnvecopenmp_shared DESTINATION lib)
++    INSTALL(TARGETS sundials_fnvecopenmp_shared DESTINATION lib${LIB_SUFFIX})
+   ENDIF(BUILD_SHARED_LIBS)
+ ENDIF(FCMIX_ENABLE AND F77_FOUND)
+ 
+--- sundials-2.6.2/src/nvec_pthreads/CMakeLists.txt.orig	2015-07-31 02:07:26.000000000 +0200
++++ sundials-2.6.2/src/nvec_pthreads/CMakeLists.txt	2023-01-20 06:13:36.412659311 +0100
+@@ -44,7 +44,7 @@ IF(BUILD_STATIC_LIBS)
+   ADD_LIBRARY(sundials_nvecpthreads_static STATIC ${nvecpthreads_SOURCES} ${shared_SOURCES})
+   SET_TARGET_PROPERTIES(sundials_nvecpthreads_static
+     PROPERTIES OUTPUT_NAME sundials_nvecpthreads CLEAN_DIRECT_OUTPUT 1)
+-  INSTALL(TARGETS sundials_nvecpthreads_static DESTINATION lib)
++  INSTALL(TARGETS sundials_nvecpthreads_static DESTINATION lib${LIB_SUFFIX})
+ ENDIF(BUILD_STATIC_LIBS)
+ 
+ # Rules for building and installing the shared library:
+@@ -54,11 +54,12 @@ ENDIF(BUILD_STATIC_LIBS)
+ #  - Install the NVECPTHREADS library
+ IF(BUILD_SHARED_LIBS)
+   ADD_LIBRARY(sundials_nvecpthreads_shared SHARED ${nvecpthreads_SOURCES} ${shared_SOURCES})
++  TARGET_LINK_LIBRARIES(sundials_nvecpthreads_shared m)
+   SET_TARGET_PROPERTIES(sundials_nvecpthreads_shared
+     PROPERTIES OUTPUT_NAME sundials_nvecpthreads CLEAN_DIRECT_OUTPUT 1)
+   SET_TARGET_PROPERTIES(sundials_nvecpthreads_shared
+     PROPERTIES VERSION ${nveclib_VERSION} SOVERSION ${nveclib_SOVERSION})
+-  INSTALL(TARGETS sundials_nvecpthreads_shared DESTINATION lib)
++  INSTALL(TARGETS sundials_nvecpthreads_shared DESTINATION lib${LIB_SUFFIX})
+ ENDIF(BUILD_SHARED_LIBS)
+ 
+ # Install the NVECPTHREADS header files
+@@ -71,15 +72,16 @@ IF(FCMIX_ENABLE AND F77_FOUND)
+     ADD_LIBRARY(sundials_fnvecpthreads_static STATIC ${fnvecpthreads_SOURCES})
+     SET_TARGET_PROPERTIES(sundials_fnvecpthreads_static
+       PROPERTIES OUTPUT_NAME sundials_fnvecpthreads CLEAN_DIRECT_OUTPUT 1)
+-    INSTALL(TARGETS sundials_fnvecpthreads_static DESTINATION lib)
++    INSTALL(TARGETS sundials_fnvecpthreads_static DESTINATION lib${LIB_SUFFIX})
+   ENDIF(BUILD_STATIC_LIBS)
+   IF(BUILD_SHARED_LIBS)
+     ADD_LIBRARY(sundials_fnvecpthreads_shared ${fnvecpthreads_SOURCES})
++    TARGET_LINK_LIBRARIES(sundials_fnvecpthreads_shared sundials_nvecpthreads_shared)
+     SET_TARGET_PROPERTIES(sundials_fnvecpthreads_shared
+       PROPERTIES OUTPUT_NAME sundials_fnvecpthreads CLEAN_DIRECT_OUTPUT 1)
+     SET_TARGET_PROPERTIES(sundials_fnvecpthreads_shared 
+       PROPERTIES VERSION ${nveclib_VERSION} SOVERSION ${nveclib_SOVERSION})
+-    INSTALL(TARGETS sundials_fnvecpthreads_shared DESTINATION lib)
++    INSTALL(TARGETS sundials_fnvecpthreads_shared DESTINATION lib${LIB_SUFFIX})
+   ENDIF(BUILD_SHARED_LIBS)
+ ENDIF(FCMIX_ENABLE AND F77_FOUND)
+ 
+--- sundials-2.6.2/src/cvodes/CMakeLists.txt.orig	2015-07-31 02:08:15.000000000 +0200
++++ sundials-2.6.2/src/cvodes/CMakeLists.txt	2023-01-20 06:14:20.281121648 +0100
+@@ -121,7 +121,7 @@ IF(BUILD_STATIC_LIBS)
+     PROPERTIES OUTPUT_NAME sundials_cvodes CLEAN_DIRECT_OUTPUT 1)
+ 
+   # Install the CVODES library
+-  INSTALL(TARGETS sundials_cvodes_static DESTINATION lib)
++  INSTALL(TARGETS sundials_cvodes_static DESTINATION lib${LIB_SUFFIX})
+ 
+ ENDIF(BUILD_STATIC_LIBS)
+ 
+@@ -132,6 +132,8 @@ IF(BUILD_SHARED_LIBS)
+   ADD_LIBRARY(sundials_cvodes_shared SHARED 
+     ${cvodes_SOURCES}  ${cvodes_BL_SOURCES}  ${shared_SOURCES})
+ 
++  TARGET_LINK_LIBRARIES(sundials_cvodes_shared lapack m)
++
+   # Set the library name and make sure it is not deleted
+   SET_TARGET_PROPERTIES(sundials_cvodes_shared
+     PROPERTIES OUTPUT_NAME sundials_cvodes CLEAN_DIRECT_OUTPUT 1)
+@@ -141,7 +143,7 @@ IF(BUILD_SHARED_LIBS)
+     PROPERTIES VERSION ${cvodeslib_VERSION} SOVERSION ${cvodeslib_SOVERSION})
+ 
+   # Install the CVODES library
+-  INSTALL(TARGETS sundials_cvodes_shared DESTINATION lib)
++  INSTALL(TARGETS sundials_cvodes_shared DESTINATION lib${LIB_SUFFIX})
+ 
+ ENDIF(BUILD_SHARED_LIBS)
+ 
+--- sundials-2.6.2/src/ida/CMakeLists.txt.orig	2015-07-31 02:08:39.000000000 +0200
++++ sundials-2.6.2/src/ida/CMakeLists.txt	2023-01-20 06:15:08.862858469 +0100
+@@ -114,7 +114,7 @@ IF(BUILD_STATIC_LIBS)
+     PROPERTIES OUTPUT_NAME sundials_ida CLEAN_DIRECT_OUTPUT 1)
+ 
+   # Install the IDA library
+-  INSTALL(TARGETS sundials_ida_static DESTINATION lib)
++  INSTALL(TARGETS sundials_ida_static DESTINATION lib${LIB_SUFFIX})
+ 
+ ENDIF(BUILD_STATIC_LIBS)
+ 
+@@ -125,6 +125,8 @@ IF(BUILD_SHARED_LIBS)
+   ADD_LIBRARY(sundials_ida_shared SHARED
+     ${ida_SOURCES}  ${ida_BL_SOURCES} ${shared_SOURCES})
+ 
++  TARGET_LINK_LIBRARIES(sundials_ida_shared lapack m)
++
+   # Set the library name and make sure it is not deleted
+   SET_TARGET_PROPERTIES(sundials_ida_shared
+     PROPERTIES OUTPUT_NAME sundials_ida CLEAN_DIRECT_OUTPUT 1)
+@@ -134,7 +136,7 @@ IF(BUILD_SHARED_LIBS)
+     PROPERTIES VERSION ${idalib_VERSION} SOVERSION ${idalib_SOVERSION})
+ 
+   # Install the IDA library
+-  INSTALL(TARGETS sundials_ida_shared DESTINATION lib)
++  INSTALL(TARGETS sundials_ida_shared DESTINATION lib${LIB_SUFFIX})
+ 
+ ENDIF(BUILD_SHARED_LIBS)
+ 
+--- sundials-2.6.2/src/idas/CMakeLists.txt.orig	2015-07-31 02:08:55.000000000 +0200
++++ sundials-2.6.2/src/idas/CMakeLists.txt	2023-01-20 06:15:52.131274057 +0100
+@@ -126,7 +126,7 @@ IF(BUILD_STATIC_LIBS)
+     PROPERTIES OUTPUT_NAME sundials_idas CLEAN_DIRECT_OUTPUT 1)
+ 
+   # Install the IDA library
+-  INSTALL(TARGETS sundials_idas_static DESTINATION lib)
++  INSTALL(TARGETS sundials_idas_static DESTINATION lib${LIB_SUFFIX})
+ 
+ ENDIF(BUILD_STATIC_LIBS)
+ 
+@@ -137,6 +137,8 @@ IF(BUILD_SHARED_LIBS)
+   ADD_LIBRARY(sundials_idas_shared SHARED 
+     ${idas_SOURCES}  ${idas_BL_SOURCES} ${idas_SLU_SOURCES} ${shared_SOURCES})
+ 
++  TARGET_LINK_LIBRARIES(sundials_idas_shared lapack m)
++
+   # Set the library name and make sure it is not deleted
+   SET_TARGET_PROPERTIES(sundials_idas_shared
+     PROPERTIES OUTPUT_NAME sundials_idas CLEAN_DIRECT_OUTPUT 1)
+@@ -146,7 +148,7 @@ IF(BUILD_SHARED_LIBS)
+     PROPERTIES VERSION ${idaslib_VERSION} SOVERSION ${idaslib_SOVERSION})
+ 
+   # Install the IDAS library
+-  INSTALL(TARGETS sundials_idas_shared DESTINATION lib)
++  INSTALL(TARGETS sundials_idas_shared DESTINATION lib${LIB_SUFFIX})
+ 
+ ENDIF(BUILD_SHARED_LIBS)
+ 
+--- sundials-2.6.2/src/kinsol/CMakeLists.txt.orig	2015-07-31 02:09:13.000000000 +0200
++++ sundials-2.6.2/src/kinsol/CMakeLists.txt	2023-01-20 06:16:20.537336832 +0100
+@@ -127,7 +127,7 @@ IF(BUILD_STATIC_LIBS)
+     PROPERTIES OUTPUT_NAME sundials_kinsol CLEAN_DIRECT_OUTPUT 1)
+ 
+   # Install the KINSOL library
+-  INSTALL(TARGETS sundials_kinsol_static DESTINATION lib)
++  INSTALL(TARGETS sundials_kinsol_static DESTINATION lib${LIB_SUFFIX})
+ 
+ ENDIF(BUILD_STATIC_LIBS)
+ 
+@@ -138,6 +138,8 @@ IF(BUILD_SHARED_LIBS)
+   ADD_LIBRARY(sundials_kinsol_shared SHARED
+     ${kinsol_SOURCES} ${kinsol_BL_SOURCES} ${kinsol_SLU_SOURCES} ${shared_SOURCES})
+ 
++  TARGET_LINK_LIBRARIES(sundials_kinsol_shared lapack m)
++
+   # Set the library name and make sure it is not deleted
+   SET_TARGET_PROPERTIES(sundials_kinsol_shared
+     PROPERTIES OUTPUT_NAME sundials_kinsol CLEAN_DIRECT_OUTPUT 1)
+@@ -147,7 +149,7 @@ IF(BUILD_SHARED_LIBS)
+     PROPERTIES VERSION ${kinsollib_VERSION} SOVERSION ${kinsollib_SOVERSION})
+ 
+   # Install the KINSOL library
+-  INSTALL(TARGETS sundials_kinsol_shared DESTINATION lib)
++  INSTALL(TARGETS sundials_kinsol_shared DESTINATION lib${LIB_SUFFIX})
+ 
+ ENDIF(BUILD_SHARED_LIBS)
+ 
diff --git a/sundials-format.patch b/sundials-format.patch
deleted file mode 100644
index 00644b2..0000000
--- a/sundials-format.patch
+++ /dev/null
@@ -1,44 +0,0 @@
---- sundials-2.3.0/src/cvode/cvode.c.orig	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0/src/cvode/cvode.c	2023-01-17 17:08:18.237375520 +0100
-@@ -4034,7 +4034,7 @@ void CVProcessError(CVodeMem cv_mem,
- 
- #ifndef NO_FPRINTF_OUTPUT
-     fprintf(stderr, "\n[%s ERROR]  %s\n  ", module, fname);
--    fprintf(stderr, msgfmt);
-+    vfprintf(stderr, msgfmt, ap);
-     fprintf(stderr, "\n\n");
- #endif
- 
---- sundials-2.3.0/src/cvodes/cvodes.c.orig	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0/src/cvodes/cvodes.c	2023-01-17 17:08:55.410518470 +0100
-@@ -7185,7 +7185,7 @@ void CVProcessError(CVodeMem cv_mem,
- 
- #ifndef NO_FPRINTF_OUTPUT
-     fprintf(stderr, "\n[%s ERROR]  %s\n  ", module, fname);
--    fprintf(stderr, msgfmt);
-+    vfprintf(stderr, msgfmt, ap);
-     fprintf(stderr, "\n\n");
- #endif
- 
---- sundials-2.3.0/src/ida/ida.c.orig	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0/src/ida/ida.c	2023-01-17 17:09:29.833645317 +0100
-@@ -3152,7 +3152,7 @@ void IDAProcessError(IDAMem IDA_mem,
- 
- #ifndef NO_FPRINTF_OUTPUT
-     fprintf(stderr, "\n[%s ERROR]  %s\n  ", module, fname);
--    fprintf(stderr, msgfmt);
-+    vfprintf(stderr, msgfmt, ap);
-     fprintf(stderr, "\n\n");
- #endif
- 
---- sundials-2.3.0/src/kinsol/kinsol.c.orig	2006-11-07 00:18:34.000000000 +0100
-+++ sundials-2.3.0/src/kinsol/kinsol.c	2023-01-17 17:09:50.793551767 +0100
-@@ -1858,7 +1858,7 @@ void KINProcessError(KINMem kin_mem,
- 
- #ifndef NO_FPRINTF_OUTPUT
-     fprintf(stderr, "\n[%s ERROR]  %s\n  ", module, fname);
--    fprintf(stderr, msgfmt);
-+    vfprintf(stderr, msgfmt, ap);
-     fprintf(stderr, "\n\n");
- #endif
- 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/sundials.git/commitdiff/bc64d9953cb167f6077dbaad7ed3905467dd36a6




More information about the pld-cvs-commit mailing list