From 81afd17a0876b9aeb00657742b2335837f2b1448 Mon Sep 17 00:00:00 2001 From: Denis Davydov Date: Wed, 27 Apr 2016 07:19:20 +0200 Subject: [PATCH] add and use DEAL_II_WITH_GSL --- doc/doxygen/options.dox.in | 3 ++- include/deal.II/base/config.h.in | 2 +- include/deal.II/base/function_cspline.h | 3 +++ source/base/function_cspline.cc | 3 +++ tests/base/functions_cspline.cc | 13 +++++++++++++ 5 files changed, 22 insertions(+), 2 deletions(-) diff --git a/doc/doxygen/options.dox.in b/doc/doxygen/options.dox.in index 6f16b23e37..5dd491948a 100644 --- a/doc/doxygen/options.dox.in +++ b/doc/doxygen/options.dox.in @@ -1,4 +1,4 @@ -# This file contains project-specific configurations for the +# This file contains project-specific configurations for the # deal.II documentation. PROJECT_NAME = "The deal.II Library" @@ -167,6 +167,7 @@ PREDEFINED = DOXYGEN=1 \ DEAL_II_WITH_BOOST=1 \ DEAL_II_WITH_CXX11=1 \ DEAL_II_WITH_CXX14=1 \ + DEAL_II_WITH_GSL=1 \ DEAL_II_WITH_HDF5=1 \ DEAL_II_WITH_LAPACK=1 \ DEAL_II_WITH_METIS=1 \ diff --git a/include/deal.II/base/config.h.in b/include/deal.II/base/config.h.in index d6c5f0348e..1f8cb03e52 100644 --- a/include/deal.II/base/config.h.in +++ b/include/deal.II/base/config.h.in @@ -39,6 +39,7 @@ #cmakedefine DEAL_II_WITH_BZIP2 #cmakedefine DEAL_II_WITH_CXX11 #cmakedefine DEAL_II_WITH_CXX14 +#cmakedefine DEAL_II_WITH_GSL #cmakedefine DEAL_II_WITH_HDF5 #cmakedefine DEAL_II_WITH_LAPACK #cmakedefine DEAL_II_WITH_METIS @@ -331,4 +332,3 @@ _Pragma("GCC diagnostic pop") #include #endif - diff --git a/include/deal.II/base/function_cspline.h b/include/deal.II/base/function_cspline.h index fac6269867..361c7f7464 100644 --- a/include/deal.II/base/function_cspline.h +++ b/include/deal.II/base/function_cspline.h @@ -18,6 +18,7 @@ #include +#ifdef DEAL_II_WITH_GSL #include #include #include @@ -111,3 +112,5 @@ DEAL_II_NAMESPACE_CLOSE #endif +#endif + diff --git a/source/base/function_cspline.cc b/source/base/function_cspline.cc index a74e311ee9..af8df06dd3 100644 --- a/source/base/function_cspline.cc +++ b/source/base/function_cspline.cc @@ -16,6 +16,7 @@ #include #include +#ifdef DEAL_II_WITH_GSL #include #include @@ -97,3 +98,5 @@ namespace Functions } DEAL_II_NAMESPACE_CLOSE + +#endif diff --git a/tests/base/functions_cspline.cc b/tests/base/functions_cspline.cc index 56338974ed..45952175aa 100644 --- a/tests/base/functions_cspline.cc +++ b/tests/base/functions_cspline.cc @@ -21,6 +21,7 @@ #include #include +#ifdef DEAL_II_WITH_GSL template void check() { @@ -77,3 +78,15 @@ int main() check<1>(); } +#else + +int main() +{ + std::string logname = "output"; + std::ofstream logfile(logname.c_str()); + deallog.attach(logfile); + deallog.threshold_double(1.e-10); + + deallog << "Ok"<< std::endl; +} +#endif -- 2.39.5