# genDElement - An abstract data element library # Copyright (C) 2013 Frederic Duboeuf # # See the LICENSE file for license information. # Please report all bugs and problems to . cmake_minimum_required(VERSION 3.10 FATAL_ERROR) # if CMAKE_BUILD_TYPE is specified use it; otherwise set the default # build type to "RelWithDebInfo" ("-O2 -g" with gcc) prior to calling # project() if(DEFINED CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE ${CMAKE_BUILD_TYPE} CACHE STRING "Choose build type") else(DEFINED CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "Choose build type") endif(DEFINED CMAKE_BUILD_TYPE) project(genDElement CXX) include_directories(. ../genFem) if(NOT DEFINED GMSH_PATH) set(GMSH_PATH "./gmsh" CACHE STRING "Gmsh Path") add_subdirectory(${GMSH_PATH} "${CMAKE_CURRENT_BINARY_DIR}/gmsh") list(APPEND EXTERNAL_LIBRARIES -lgsl) include_directories(${GMSH_PATH}/Common ${GMSH_PATH}/Numeric ${GMSH_PATH}/Geo ${GMSH_PATH}/Mesh ${GMSH_PATH}/Solver ${GMSH_PATH}/Post ${GMSH_PATH}/Plugin ${GMSH_PATH}/Graphics ${GMSH_PATH}/contrib/DiscreteIntegration ${GMSH_EXTERNAL_INCLUDE_DIRS} ${CMAKE_CURRENT_BINARY_DIR}/gmsh/Common ${EXTERNAL_INCLUDES} ${GMSH_PATH}/contrib/gmm ${GMSH_PATH}/contrib/MathEx ) endif(NOT DEFINED GMSH_PATH) set(SRC genDataManager.cpp genDataGroup.cpp genDataBuilder.cpp) set(LINK_LIBRARIES genFem_shared shared ${GMSH_EXTERNAL_LIBRARIES}) add_library(genDElement_shared SHARED ${SRC}) target_link_libraries(genDElement_shared ${LINK_LIBRARIES}) if(CADXFEM_ENABLE_TESTING) add_subdirectory(test) endif(CADXFEM_ENABLE_TESTING)