Commit 84cdef04 authored by Praetorius, Simon's avatar Praetorius, Simon

CMakeLists corrected

parent f148869d
......@@ -116,9 +116,14 @@ if(CMAKE_BUILD_TYPE STREQUAL "")
endif()
if (AMDIS_NEED_CXX11)
list(APPEND AMDIS_COMPILEFLAGS "-DHAS_CXX11=1" "-std=c++11")
else ()
list(APPEND AMDIS_COMPILEFLAGS "-DHAS_CXX11=0")
# list(APPEND AMDIS_COMPILEFLAGS "-DHAS_CXX11=1")
if (${CMAKE_VERSION} VERSION_GREATER "3.0")
set(CMAKE_CXX_STANDARD_REQUIRED "11")
# else()
# list(APPEND AMDIS_COMPILEFLAGS "-std=c++11")
endif()
# else ()
# list(APPEND AMDIS_COMPILEFLAGS "-DHAS_CXX11=0")
endif (AMDIS_NEED_CXX11)
#load mpi-compiler for use with parmetis and parallel_domain
......
......@@ -426,8 +426,10 @@ endif(ENABLE_BDDCML)
if(ENABLE_EXTENSIONS)
option(ENABLE_BASE_PROBLEMS "Use base_problems" false)
find_path(EXTENSIONS_DIR NAMES ${SOURCE_DIR}/../../extensions/Helpers.h DOC "Path to AMDiS extensions.")
option(ENABLE_BASE_PROBLEMS "Use base_problems" true)
find_path(EXTENSIONS_DIR NAMES Helpers.h
HINTS ${CMAKE_CURRENT_SOURCE_DIR}/../extensions
DOC "Path to AMDiS extensions.")
if (EXTENSIONS_DIR)
if (NOT EXISTS ${EXTENSIONS_DIR}/Helpers.h OR NOT EXISTS ${EXTENSIONS_DIR}/base_problems/BaseProblem.h)
message(FATAL_ERROR "Wrong extensions directory! Directory must contain the 'Helpers.h' and the subdirectory 'base_problems'")
......@@ -624,10 +626,14 @@ endif(WIN32)
if (ENABLE_CXX11)
list(APPEND COMPILEFLAGS "-DHAS_CXX11=1")
set_property(TARGET "amdis" PROPERTY CXX_STANDARD 11)
set_property(TARGET "compositeFEM" PROPERTY CXX_STANDARD 11)
set_property(TARGET "reinit" PROPERTY CXX_STANDARD 11)
set_property(TARGET "muparser" PROPERTY CXX_STANDARD 11)
if (${CMAKE_VERSION} VERSION_GREATER "3.0")
set_property(TARGET "amdis" PROPERTY CXX_STANDARD_REQUIRED 11)
set_property(TARGET "compositeFEM" PROPERTY CXX_STANDARD_REQUIRED 11)
set_property(TARGET "reinit" PROPERTY CXX_STANDARD_REQUIRED 11)
set_property(TARGET "muparser" PROPERTY CXX_STANDARD_REQUIRED 11)
else()
list(APPEND COMPILEFLAGS "-std=c++11")
endif()
else ()
list(APPEND COMPILEFLAGS "-DHAS_CXX11=0")
endif (ENABLE_CXX11)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment