Mercurial > octave
changeset 21603:37cbdf7bffa9
Add fftwf_version (bug #45659)
* toplev.cc (F__octave_config_info__): New field, fftwf_version.
* oct-fftw.cc, oct-fftw.h (octave_fftwf_version): New function.
author | mmuetzel <markus.muetzel@gmx.de> |
---|---|
date | Mon, 11 Apr 2016 10:45:17 +0200 |
parents | 47c76e56a1de |
children | d7a268e68e69 |
files | libinterp/corefcn/toplev.cc liboctave/numeric/oct-fftw.cc liboctave/numeric/oct-fftw.h |
diffstat | 3 files changed, 14 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/libinterp/corefcn/toplev.cc Sun Apr 10 20:45:01 2016 -0700 +++ b/libinterp/corefcn/toplev.cc Mon Apr 11 10:45:17 2016 +0200 @@ -1431,6 +1431,7 @@ { "exec_prefix", subst_octave_home (OCTAVE_EXEC_PREFIX) }, { "fcnfiledir", subst_octave_home (OCTAVE_FCNFILEDIR) }, { "fftw_version", octave_fftw_version () }, + { "fftwf_version", octave_fftwf_version () }, { "hg_id", octave_hg_id () }, { "imagedir", subst_octave_home (OCTAVE_IMAGEDIR) }, { "includedir", subst_octave_home (OCTAVE_INCLUDEDIR) }, @@ -1720,6 +1721,8 @@ %! assert (isstruct (x)); %! assert (! isempty (x)); +%!assert (__octave_config_info__ ("fftw_version"), __octave_config_info__ ("fftwf_version")) + %!error __octave_config_info__ (1, 2) */
--- a/liboctave/numeric/oct-fftw.cc Sun Apr 10 20:45:01 2016 -0700 +++ b/liboctave/numeric/oct-fftw.cc Mon Apr 11 10:45:17 2016 +0200 @@ -38,7 +38,6 @@ #include "quit.h" #include "oct-locbuf.h" #include "singleton-cleanup.h" -#include "libinterp/build-info.h" #if defined (HAVE_FFTW3_THREADS) || defined (HAVE_FFTW3F_THREADS) # include "nproc.h" @@ -1143,3 +1142,13 @@ return "none"; #endif } + +std::string +octave_fftwf_version (void) +{ +#if defined (HAVE_FFTW) + return fftwf_version; +#else + return "none"; +#endif +}