diff --git a/CMakeLists.txt b/CMakeLists.txt new file mode 100644 index 0000000000000000000000000000000000000000..9a62ee5a44203ace81ea6c435cad0ae64179541d --- /dev/null +++ b/CMakeLists.txt @@ -0,0 +1,13 @@ +project("dune-elasticity" CXX) +cmake_minimum_required(VERSION 2.8.6) + +find_package(dune-common) +list(APPEND CMAKE_MODULE_PATH ${dune-common_MODULE_PATH}) +include(DuneMacros) + +dune_project() + +add_subdirectory("dune") +add_subdirectory("m4") + +finalize_dune_project(GENERATE_CONFIG_H_CMAKE) diff --git a/cmake/pkg/dune-elasticity-config.cmake.in b/cmake/pkg/dune-elasticity-config.cmake.in new file mode 100644 index 0000000000000000000000000000000000000000..43ed3a937e99ea9cde7a097d426cc8751d3d5113 --- /dev/null +++ b/cmake/pkg/dune-elasticity-config.cmake.in @@ -0,0 +1,20 @@ +if(NOT @DUNE_MOD_NAME@_FOUND) +#compute installation prefix relative to this file +get_filename_component(_dir "${CMAKE_CURRENT_LIST_FILE}" PATH) +get_filename_component(_prefix "${_dir}/../../.." ABSOLUTE) + +#import the target +#include("${_prefix}/lib/cmake/@DUNE_MOD_NAME@-targets.cmake") + +#report other information +set(@DUNE_MOD_NAME@_PREFIX "${_prefix}") +set(@DUNE_MOD_NAME@_INCLUDE_DIRS "${_prefix}/include") +set(@DUNE_MOD_NAME@_CXX_FLAGS "@CMAKE_CXX_FLAGS@") +set(@DUNE_MOD_NAME@_CXX_FLAGS_DEBUG "@CMAKE_CXX_FLAGS_DEBUG@") +set(@DUNE_MOD_NAME@_CXX_FLAGS_MINSIZEREL "@CMAKE_CXX_FLAGS_MINSIZEREL@") +set(@DUNE_MOD_NAME@_CXX_FLAGS_RELEASE "@CMAKE_CXX_FLAGS_RELEASE@") +set(@DUNE_MOD_NAME@_CXX_FLAGS_RELWITHDEBINFO "@CMAKE_CXX_FLAGS_RELWITHDEBINFO@") +set(@DUNE_MOD_NAME@_DEPENDS "@DUNE_DEPENDS@") +set(@DUNE_MOD_NAME@_SUGGESTS "@DUNE_SUGGESTS@") +set(@DUNE_MOD_NAME@_MODULE_PATH "${_prefix}/@DUNE_INSTALL_MODULEDIR@") +endif(NOT @DUNE_MOD_NAME@_FOUND) \ No newline at end of file diff --git a/dune-elasticity-config.cmake.in b/dune-elasticity-config.cmake.in new file mode 100644 index 0000000000000000000000000000000000000000..43ed3a937e99ea9cde7a097d426cc8751d3d5113 --- /dev/null +++ b/dune-elasticity-config.cmake.in @@ -0,0 +1,20 @@ +if(NOT @DUNE_MOD_NAME@_FOUND) +#compute installation prefix relative to this file +get_filename_component(_dir "${CMAKE_CURRENT_LIST_FILE}" PATH) +get_filename_component(_prefix "${_dir}/../../.." ABSOLUTE) + +#import the target +#include("${_prefix}/lib/cmake/@DUNE_MOD_NAME@-targets.cmake") + +#report other information +set(@DUNE_MOD_NAME@_PREFIX "${_prefix}") +set(@DUNE_MOD_NAME@_INCLUDE_DIRS "${_prefix}/include") +set(@DUNE_MOD_NAME@_CXX_FLAGS "@CMAKE_CXX_FLAGS@") +set(@DUNE_MOD_NAME@_CXX_FLAGS_DEBUG "@CMAKE_CXX_FLAGS_DEBUG@") +set(@DUNE_MOD_NAME@_CXX_FLAGS_MINSIZEREL "@CMAKE_CXX_FLAGS_MINSIZEREL@") +set(@DUNE_MOD_NAME@_CXX_FLAGS_RELEASE "@CMAKE_CXX_FLAGS_RELEASE@") +set(@DUNE_MOD_NAME@_CXX_FLAGS_RELWITHDEBINFO "@CMAKE_CXX_FLAGS_RELWITHDEBINFO@") +set(@DUNE_MOD_NAME@_DEPENDS "@DUNE_DEPENDS@") +set(@DUNE_MOD_NAME@_SUGGESTS "@DUNE_SUGGESTS@") +set(@DUNE_MOD_NAME@_MODULE_PATH "${_prefix}/@DUNE_INSTALL_MODULEDIR@") +endif(NOT @DUNE_MOD_NAME@_FOUND) \ No newline at end of file diff --git a/dune-elasticity-version.cmake.in b/dune-elasticity-version.cmake.in new file mode 100644 index 0000000000000000000000000000000000000000..a1c2199d972b8943a646d4feb40d12e9e239b141 --- /dev/null +++ b/dune-elasticity-version.cmake.in @@ -0,0 +1,8 @@ +set(PACKAGE_VERSION "@DUNE_MOD_VERSION@") + +if(NOT "${PACKAGE_FIND_VERSION}" VERSION_GREATER "@DUNE_MOD_VERSION@") + set (PACKAGE_VERSION_COMPATIBLE 1) # compatible with older + if ("${PACKAGE_FIND_VERSION}" VERSION_EQUAL "@DUNE_MOD_VERSION@") + set(PACKAGE_VERSION_EXACT 1) #exact match for this version + endif() +endif() diff --git a/dune-elasticity.pc.in b/dune-elasticity.pc.in new file mode 100644 index 0000000000000000000000000000000000000000..5cc5b2ff3e9ec3b532532c16da37b19d9b2f9c82 --- /dev/null +++ b/dune-elasticity.pc.in @@ -0,0 +1,15 @@ +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@ +includedir=@includedir@ +CXX=@CXX@ +CC=@CC@ +DEPENDENCIES=@REQUIRES@ + +Name: @PACKAGE_NAME@ +Version: @VERSION@ +Description: Dune (Distributed and Unified Numerics Environment) elasticity module +URL: http://dune-project.org/ +Requires: ${DEPENDENCIES} +Libs: +Cflags: -I${includedir} diff --git a/dune/CMakeLists.txt b/dune/CMakeLists.txt new file mode 100644 index 0000000000000000000000000000000000000000..b9de3879e93d40baa28a5c32eabd2786588f95ac --- /dev/null +++ b/dune/CMakeLists.txt @@ -0,0 +1 @@ +add_subdirectory(elasticity) diff --git a/dune/elasticity/CMakeLists.txt b/dune/elasticity/CMakeLists.txt new file mode 100644 index 0000000000000000000000000000000000000000..0b3da84fa1324d78c58c1e4574d31db7c41fbdb0 --- /dev/null +++ b/dune/elasticity/CMakeLists.txt @@ -0,0 +1,4 @@ +add_subdirectory(assemblers) +add_subdirectory(common) +add_subdirectory(estimators) +add_subdirectory(materials) diff --git a/dune/elasticity/assemblers/CMakeLists.txt b/dune/elasticity/assemblers/CMakeLists.txt new file mode 100644 index 0000000000000000000000000000000000000000..60b0eefc751ca3b848f82315360ae5e2129b14b3 --- /dev/null +++ b/dune/elasticity/assemblers/CMakeLists.txt @@ -0,0 +1,8 @@ +install(FILES + neohookeassembler.cc + neohookeassembler.hh + neohookefunctionalassembler.hh + neohookeoperatorassembler.hh + ogdenassembler.cc + ogdenassembler.hh + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/dune/elasticity/assemblers) diff --git a/dune/elasticity/common/CMakeLists.txt b/dune/elasticity/common/CMakeLists.txt new file mode 100644 index 0000000000000000000000000000000000000000..e090d8c6feb90303482645033675c02f79d6f56f --- /dev/null +++ b/dune/elasticity/common/CMakeLists.txt @@ -0,0 +1,3 @@ +install(FILES + elasticityhelpers.hh + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/dune/elasticity/common) diff --git a/dune/elasticity/estimators/CMakeLists.txt b/dune/elasticity/estimators/CMakeLists.txt new file mode 100644 index 0000000000000000000000000000000000000000..f1a8796ffb43161609206f3ba028ee274061f0e0 --- /dev/null +++ b/dune/elasticity/estimators/CMakeLists.txt @@ -0,0 +1,3 @@ +install(FILES + zienkiewiczzhuestimator.hh + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/dune/elasticity/estimators) diff --git a/dune/elasticity/materials/CMakeLists.txt b/dune/elasticity/materials/CMakeLists.txt new file mode 100644 index 0000000000000000000000000000000000000000..1a1c2183308422e5b8a3937a759f4ac2cea2ea9c --- /dev/null +++ b/dune/elasticity/materials/CMakeLists.txt @@ -0,0 +1,4 @@ +install(FILES + geomexactstvenantkirchhoffmaterial.hh + neohookeanmaterial.hh + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/dune/elasticity/materials) diff --git a/m4/CMakeLists.txt b/m4/CMakeLists.txt new file mode 100644 index 0000000000000000000000000000000000000000..168cd94968bd28917c0f7db479206a89fec1e174 --- /dev/null +++ b/m4/CMakeLists.txt @@ -0,0 +1,4 @@ +install(FILES + dune-elasticity.m4 + DESTINATION share/aclocal) +