Mercurial > octave
comparison m4/acinclude.m4 @ 26900:ebe7e12765ba
fix sundials configure warnings (bug #55911)
* acinclude.m4 (OCTAVE_CHECK_SUNDIALS_SUNLINSOL_KLU,
OCTAVE_CHECK_SUNDIALS_SUNLINSOL_DENSE): Define variable for warning
string with the same name as is used in the call to
OCTAVE_CONFIGURE_WARNING.
(OCTAVE_CHECK_SUNDIALS_SUNLINSOL_DENSE): Remove stray #endif in test program.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Wed, 13 Mar 2019 19:14:22 +0000 |
parents | d94876e7a0aa |
children | 73b141d5a888 |
comparison
equal
deleted
inserted
replaced
26899:236d8f52cbb3 | 26900:ebe7e12765ba |
---|---|
2217 AC_DEFUN([OCTAVE_CHECK_SUNDIALS_SIZEOF_REALTYPE], [ | 2217 AC_DEFUN([OCTAVE_CHECK_SUNDIALS_SIZEOF_REALTYPE], [ |
2218 AC_CACHE_CHECK([whether SUNDIALS IDA is configured with double precision realtype], | 2218 AC_CACHE_CHECK([whether SUNDIALS IDA is configured with double precision realtype], |
2219 [octave_cv_sundials_realtype_is_double], | 2219 [octave_cv_sundials_realtype_is_double], |
2220 [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ | 2220 [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
2221 #if defined (HAVE_IDA_IDA_H) | 2221 #if defined (HAVE_IDA_IDA_H) |
2222 #include <ida/ida.h> | 2222 # include <ida/ida.h> |
2223 #endif | 2223 #endif |
2224 #include <assert.h> | 2224 #include <assert.h> |
2225 ]], [[ | 2225 ]], [[ |
2226 static_assert (sizeof (realtype) == sizeof (double), | 2226 static_assert (sizeof (realtype) == sizeof (double), |
2227 "SUNDIALS is not configured for double precision"); | 2227 "SUNDIALS is not configured for double precision"); |
2269 ]) | 2269 ]) |
2270 if test $octave_cv_sundials_sunlinsol_klu = yes; then | 2270 if test $octave_cv_sundials_sunlinsol_klu = yes; then |
2271 AC_DEFINE(HAVE_SUNDIALS_SUNLINSOL_KLU, 1, | 2271 AC_DEFINE(HAVE_SUNDIALS_SUNLINSOL_KLU, 1, |
2272 [Define to 1 if SUNDIALS IDA is configured with SUNLINSOL_KLU enabled.]) | 2272 [Define to 1 if SUNDIALS IDA is configured with SUNLINSOL_KLU enabled.]) |
2273 else | 2273 else |
2274 warn_sundials_idaklu="SUNDIALS IDA library not configured with SUNLINSOL_KLU, ode15i and ode15s will not support the sparse Jacobian feature" | 2274 warn_sundials_sunlinsol_klu="SUNDIALS IDA library not configured with SUNLINSOL_KLU, ode15i and ode15s will not support the sparse Jacobian feature" |
2275 OCTAVE_CONFIGURE_WARNING([warn_sundials_sunlinsol_klu]) | 2275 OCTAVE_CONFIGURE_WARNING([warn_sundials_sunlinsol_klu]) |
2276 fi | 2276 fi |
2277 ]) | 2277 ]) |
2278 dnl | 2278 dnl |
2279 dnl Check whether SUNDIALS IDA library has the SUNLINSOL_DENSE linear solver. | 2279 dnl Check whether SUNDIALS IDA library has the SUNLINSOL_DENSE linear solver. |
2283 AC_CHECK_HEADERS([sunlinsol/sunlinsol_dense.h]) | 2283 AC_CHECK_HEADERS([sunlinsol/sunlinsol_dense.h]) |
2284 AC_CACHE_CHECK([whether SUNDIALS IDA includes the SUNLINSOL_DENSE linear solver], | 2284 AC_CACHE_CHECK([whether SUNDIALS IDA includes the SUNLINSOL_DENSE linear solver], |
2285 [octave_cv_sundials_sunlinsol_dense], | 2285 [octave_cv_sundials_sunlinsol_dense], |
2286 [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ | 2286 [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
2287 #if defined (HAVE_IDA_IDA_H) | 2287 #if defined (HAVE_IDA_IDA_H) |
2288 #include <ida/ida.h> | 2288 # include <ida/ida.h> |
2289 #endif | 2289 #endif |
2290 #if defined (HAVE_SUNLINSOL_SUNLINSOL_DENSE_H) | 2290 #if defined (HAVE_SUNLINSOL_SUNLINSOL_DENSE_H) |
2291 #include <sunlinsol/sunlinsol_dense.h> | 2291 # include <sunlinsol/sunlinsol_dense.h> |
2292 #endif | 2292 #endif |
2293 #endif | |
2294 ]], [[ | 2293 ]], [[ |
2295 void *mem = 0; | 2294 void *mem = 0; |
2296 long int num = 0; | 2295 long int num = 0; |
2297 IDADense (mem, num); | 2296 IDADense (mem, num); |
2298 ]])], | 2297 ]])], |
2301 ]) | 2300 ]) |
2302 if test $octave_cv_sundials_sunlinsol_dense = yes; then | 2301 if test $octave_cv_sundials_sunlinsol_dense = yes; then |
2303 AC_DEFINE(HAVE_SUNDIALS_SUNLINSOL_DENSE, 1, | 2302 AC_DEFINE(HAVE_SUNDIALS_SUNLINSOL_DENSE, 1, |
2304 [Define to 1 if SUNDIALS IDA includes the SUNLINSOL_DENSE linear solver.]) | 2303 [Define to 1 if SUNDIALS IDA includes the SUNLINSOL_DENSE linear solver.]) |
2305 else | 2304 else |
2306 warn_sundials_ida_dense="SUNDIALS IDA library does not include the SUNLINSOL_DENSE linear solver, ode15i and ode15s will be disabled" | 2305 warn_sundials_sunlinsol_dense="SUNDIALS IDA library does not include the SUNLINSOL_DENSE linear solver, ode15i and ode15s will be disabled" |
2307 OCTAVE_CONFIGURE_WARNING([warn_sundials_sunlinsol_dense]) | 2306 OCTAVE_CONFIGURE_WARNING([warn_sundials_sunlinsol_dense]) |
2308 fi | 2307 fi |
2309 ]) | 2308 ]) |
2310 dnl | 2309 dnl |
2311 dnl Add warning to final summary. | 2310 dnl Add warning to final summary. |