Liebe Gitlab-Nutzer, lieber Gitlab-Nutzer, es ist nun möglich sich mittels des ZIH-Logins/LDAP an unserem Dienst anzumelden. Ein Anmelden über dieses erzeugt ein neues Konto. Das alte Konto ist über den Reiter "Standard" erreichbar. Die Administratoren

Dear Gitlab user, it is now possible to log in to our service using the ZIH login/LDAP. Logging in via this will create a new account. The old account can be accessed via the "Standard" tab. The administrators

Commit 5d4f9830 authored by Naumann, Andreas's avatar Naumann, Andreas
Browse files

use the cmake-debug build and create umfpack and parmetis libraries, if desired

parent c1930d5c
...@@ -11,21 +11,22 @@ SET(SOURCE_DIR ${AMDiS_SOURCE_DIR}) ...@@ -11,21 +11,22 @@ SET(SOURCE_DIR ${AMDiS_SOURCE_DIR})
#TODO: use the cmake build type #TODO: use the cmake build type
SET(MTL_DIR ${LIB_DIR}/mtl4/ CACHE PATH "mtl4 directory") SET(MTL_DIR ${LIB_DIR}/mtl4/ CACHE PATH "mtl4 directory")
option(ENABLE_DEBUG "debug" false) set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -g -Wall -DDEBUG=0")
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -Wall -DDEBUG=1 -O0")
#define the build type, empty can be everything and nothing
if(CMAKE_BUILD_TYPE STREQUAL "")
set(CMAKE_BUILD_TYPE "Release")
endif()
#option(ENABLE_INTEL "use intel compiler" false) #option(ENABLE_INTEL "use intel compiler" false)
option(ENABLE_OPENMP "use openmp" false) option(ENABLE_OPENMP "use openmp" false)
option(ENABLE_PARMETIS "use partion of unity and enable parmetis" false)
option(ENABLE_PARALLEL_DOMAIN "use parallel domain decomposition" false) option(ENABLE_PARALLEL_DOMAIN "use parallel domain decomposition" false)
SET(PETSC_DIR "" CACHE PATH "Petsc directory for parallel domain decomposition" ) SET(PETSC_DIR "" CACHE PATH "Petsc directory for parallel domain decomposition" )
SET(PETSC_ARCH "" CACHE STRING "Petsc architecture") SET(PETSC_ARCH "" CACHE STRING "Petsc architecture")
option(ENABLE_UMFPACK "use umfpack solver" false) option(ENABLE_UMFPACK "use umfpack solver" false)
option(ENABLE_MKL "use the mkl" false) option(ENABLE_MKL "use the mkl" false)
SET(MKL_DIR "" CACHE PATH "MKL directory") SET(MKL_DIR "" CACHE PATH "MKL directory")
option(ENABLE_DUNE "use dune" false)
SET(DUNE_DIR "" CACHE PATH "Dune directory")
#option(ENABLE_BOOST "use the boost library" false)
option(ENABLE_MARMOT "use marmot" false)
option(ENABLE_GUI "compile the gui" false)
#option(ENABLE_TESTS "compile the tests" false) #option(ENABLE_TESTS "compile the tests" false)
SET(ENABLE_TESTS false) SET(ENABLE_TESTS false)
...@@ -37,20 +38,17 @@ if(ENABLE_INTEL) ...@@ -37,20 +38,17 @@ if(ENABLE_INTEL)
#SET(CMAKE_C_COMPILER "icc") #SET(CMAKE_C_COMPILER "icc")
endif(ENABLE_INTEL) endif(ENABLE_INTEL)
#if(ENABLE_BOOST) find_package(Boost 1.42 REQUIRED)
SET(COMPILEFLAGS "${COMPILEFLAGS} -DHAVE_BOOST=1") if(Boost_FOUND)
find_package(Boost 1.42 REQUIRED) include_directories(${Boost_INCLUDE_DIR})
if(Boost_FOUND) message("boost lib-dirs: ${Boost_LIBRARY_DIRS}")
include_directories(${Boost_INCLUDE_DIR}) message("use the boost dir: ${Boost_INCLUDE_DIR}")
message("boost lib-dirs: ${Boost_LIBRARY_DIRS}") if(WIN32)
message("use the boost dir: ${Boost_INCLUDE_DIR}") message("the windows find_boost does not set the boost library paths, please set it")
if(WIN32) SET(Boost_LIBRARY_DIRS CACHE PATH "The directory containing the boost libraries")
message("the windows find_boost does not set the boost library paths, please set it") endif(WIN32)
SET(Boost_LIBRARY_DIRS CACHE PATH "The directory containing the boost libraries") link_directories(${Boost_LIBRARY_DIRS})
endif(WIN32) endif(Boost_FOUND)
link_directories(${Boost_LIBRARY_DIRS})
endif(Boost_FOUND)
#endif(ENABLE_BOOST)
SET(LIB_DIR ./lib) SET(LIB_DIR ./lib)
SET(SOURCE_DIR ${AMDiS_SOURCE_DIR}) SET(SOURCE_DIR ${AMDiS_SOURCE_DIR})
...@@ -158,21 +156,23 @@ SET(AMDIS_SRC ${SOURCE_DIR}/DOFIndexed.cc ...@@ -158,21 +156,23 @@ SET(AMDIS_SRC ${SOURCE_DIR}/DOFIndexed.cc
${SOURCE_DIR}/time/RosenbrockMethod.cc ${SOURCE_DIR}/time/RosenbrockMethod.cc
) )
if(ENABLE_PARMETIS) if(ENABLE_PARALLEL_DOMAIN)
find_package(MPI REQUIRED) find_package(MPI REQUIRED)
INCLUDE (CMakeForceCompiler) INCLUDE (CMakeForceCompiler)
CMAKE_FORCE_C_COMPILER(mpicc "MPI C compiler") CMAKE_FORCE_C_COMPILER(mpicc "MPI C compiler")
CMAKE_FORCE_CXX_COMPILER(mpiCC "MPI C++ compiler") CMAKE_FORCE_CXX_COMPILER(mpiCC "MPI C++ compiler")
add_custom_target(parmetis-lib ALL
make
WORKING_DIRECTORY ${LIB_DIR}/ParMetis-3.1
)
include_directories( ${LIB_DIR}/ParMetis-3.1) include_directories( ${LIB_DIR}/ParMetis-3.1)
INSTALL(FILES ${LIB_DIR}/ParMetis-3.1/parmetis.h INSTALL(FILES ${LIB_DIR}/ParMetis-3.1/parmetis.h
${LIB_DIR}/ParMetis-3.1/libparmetis.a ${LIB_DIR}/ParMetis-3.1/libparmetis.a
${LIB_DIR}/ParMetis-3.1/libmetis.a ${LIB_DIR}/ParMetis-3.1/libmetis.a
DESTINATION lib/parmetis DESTINATION lib/parmetis
) )
endif(ENABLE_PARMETIS)
if(ENABLE_PARALLEL_DOMAIN)
include_directories(${PETSC_DIR}/include ${PETSC_DIR}/${PETSC_ARCH}/include) include_directories(${PETSC_DIR}/include ${PETSC_DIR}/${PETSC_ARCH}/include)
SET(PARALLEL_DOMAIN_AMDIS_SRC SET(PARALLEL_DOMAIN_AMDIS_SRC
${SOURCE_DIR}/parallel/ParMetisPartitioner.cc ${SOURCE_DIR}/parallel/ParMetisPartitioner.cc
...@@ -181,20 +181,18 @@ if(ENABLE_PARALLEL_DOMAIN) ...@@ -181,20 +181,18 @@ if(ENABLE_PARALLEL_DOMAIN)
${SOURCE_DIR}/parallel/ParallelDebug.cc ${SOURCE_DIR}/parallel/ParallelDebug.cc
${SOURCE_DIR}/parallel/GlobalMatrixSolver.cc ${SOURCE_DIR}/parallel/GlobalMatrixSolver.cc
${SOURCE_DIR}/parallel/MpiHelper.cc ${SOURCE_DIR}/parallel/MpiHelper.cc
${SOURCE_DIR}/parallel/ElementObjectData.cc) ${SOURCE_DIR}/parallel/ElementObjectData.cc
${SOURCE_DIR}/parallel/PetscSolver.cc)
SET(COMPILEFLAGS "${COMPILEFLAGS} -DHAVE_PARALLEL_DOMAIN_AMDIS=1") SET(COMPILEFLAGS "${COMPILEFLAGS} -DHAVE_PARALLEL_DOMAIN_AMDIS=1")
endif(ENABLE_PARALLEL_DOMAIN) endif(ENABLE_PARALLEL_DOMAIN)
if(ENABLE_DEBUG)
SET(COMPILEFLAGS "${COMPILEFLAGS} -g -O0 -DDEBUG=1")
endif(ENABLE_DEBUG)
if(ENABLE_OPENMP) if(ENABLE_OPENMP)
if(ENABLE_INTEL) find_package(OpenMP)
SET(COMPILEFLAGS "${COMPILEFLAGS} -openmp") if(OPENMP_FOUND)
else(ENABLE_INTEL) SET(COMPILEFLAGS "${COMPILEFLAGS} ${OpenMP_CXX_FLAGS}")
SET(COMPILEFLAGS "${COMPILEFLAGS} -fopenmp") else()
endif(ENABLE_INTEL) message(WARNING "your compiler seems support openmp")
endif()
endif(ENABLE_OPENMP) endif(ENABLE_OPENMP)
if(ENABLE_UMFPACK) if(ENABLE_UMFPACK)
...@@ -216,6 +214,18 @@ if(ENABLE_UMFPACK) ...@@ -216,6 +214,18 @@ if(ENABLE_UMFPACK)
INSTALL(FILES ${HEADERS} INSTALL(FILES ${HEADERS}
DESTINATION include/amdis/ufconfig/xerbla) DESTINATION include/amdis/ufconfig/xerbla)
#add some rules to build the umfpack and amd libs
# message("adding command for libumfpack:${CMAKE_CURRENT_SOURCE_DIR}/${LIB_DIR}/UMFPACK/Lib/libumfpack.a ")
add_custom_target(umfpack-lib ALL
make
WORKING_DIRECTORY ${LIB_DIR}/UMFPACK
)
add_custom_target(amd-lib ALL
make
WORKING_DIRECTORY ${LIB_DIR}/AMD
)
INSTALL(FILES ${LIB_DIR}/UMFPACK/Lib/libumfpack.a INSTALL(FILES ${LIB_DIR}/UMFPACK/Lib/libumfpack.a
DESTINATION lib/amdis/umfpack/) DESTINATION lib/amdis/umfpack/)
INSTALL(FILES ${LIB_DIR}/AMD/Lib/libamd.a INSTALL(FILES ${LIB_DIR}/AMD/Lib/libamd.a
...@@ -228,11 +238,6 @@ if(ENABLE_MKL) ...@@ -228,11 +238,6 @@ if(ENABLE_MKL)
SET(COMPILEFLAGS "${COMPILEFLAGS} -DHAVE_MKL=1") SET(COMPILEFLAGS "${COMPILEFLAGS} -DHAVE_MKL=1")
endif(ENABLE_MKL) endif(ENABLE_MKL)
if(ENABLE_DUNE)
include_directories(${DUNE_DIR})
SET(COMPILEFLAGS "${COMPILEFLAGS} -DHAVE_DUNE=1")
endif(ENABLE_DUNE)
SET(COMPOSITE_SOURCE_DIR compositeFEM/src) SET(COMPOSITE_SOURCE_DIR compositeFEM/src)
SET(COMPOSITE_FEM_SRC ${COMPOSITE_SOURCE_DIR}/CFE_Integration.cc ${COMPOSITE_SOURCE_DIR}/CFE_NormAndErrorFcts.cc SET(COMPOSITE_FEM_SRC ${COMPOSITE_SOURCE_DIR}/CFE_Integration.cc ${COMPOSITE_SOURCE_DIR}/CFE_NormAndErrorFcts.cc
${COMPOSITE_SOURCE_DIR}/CompositeFEMMethods.cc ${COMPOSITE_SOURCE_DIR}/LevelSetAdaptMesh.cc ${COMPOSITE_SOURCE_DIR}/CompositeFEMMethods.cc ${COMPOSITE_SOURCE_DIR}/LevelSetAdaptMesh.cc
......
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