From cff349282c68e85daa321a9914706a83e17ea639 Mon Sep 17 00:00:00 2001 From: Jonathan Youett <youett@math.fu-berlin.de> Date: Tue, 23 Oct 2018 09:18:54 +0200 Subject: [PATCH] Only add adolc flags when the solver is build --- CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index ed30463..8b70fc5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,6 +17,7 @@ add_subdirectory("src") if(HAVE_AMIRAMESH AND HAVE_IPOPT AND HAVE_PSURFACE AND HAVE_UG) set(programs viscoelast nonlinelast) + foreach(_program ${programs}) add_executable(${_program} ${_program}.cc) add_dune_amiramesh_flags(${_program}) @@ -27,7 +28,7 @@ if(HAVE_AMIRAMESH AND HAVE_IPOPT AND HAVE_PSURFACE AND HAVE_UG) endforeach() endif() -if (ADOLC_FOUND) +if(HAVE_AMIRAMESH AND HAVE_IPOPT AND HAVE_PSURFACE AND HAVE_UG AND ADOLC_FOUND) add_dune_adolc_flags(nonlinelast) endif() -- GitLab