File tree Expand file tree Collapse file tree 7 files changed +46
-0
lines changed
dependencies/supported_version Expand file tree Collapse file tree 7 files changed +46
-0
lines changed Original file line number Diff line number Diff line change @@ -120,6 +120,7 @@ four_c_configure_dependency(HDF5 DEFAULT ON)
120120four_c_configure_dependency(MPI DEFAULT ON )
121121four_c_configure_dependency(Qhull DEFAULT ON )
122122four_c_configure_dependency(Trilinos DEFAULT ON )
123+ four_c_configure_dependency(deal.II DEFAULT OFF )
123124four_c_configure_dependency(Boost DEFAULT ON )
124125four_c_configure_dependency(ArborX DEFAULT OFF )
125126four_c_configure_dependency(FFTW DEFAULT ON )
Original file line number Diff line number Diff line change 1+ # This file is part of 4C multiphysics licensed under the
2+ # GNU Lesser General Public License v3.0 or later.
3+ #
4+ # See the LICENSE.md file in the top-level for license information.
5+ #
6+ # SPDX-License-Identifier: LGPL-3.0-or-later
7+
8+ # At this point we deliberately turned on the option to use deal.II, so fail if it is not available.
9+ find_package (deal.II REQUIRED)
10+
11+ if (NOT DEAL_II_WITH_TRILINOS)
12+ message (
13+ FATAL_ERROR
14+ "deal.II was not compiled with Trilinos support. Please recompile deal.II with Trilinos support."
15+ )
16+ endif ()
17+
18+ # N.B. We do NOT use dealii::dealii here, since this pulls in a lot of flags that we might not want.
19+ # Instead, deal.II potentially provides two targets: dealii::dealii_release and/or dealii::dealii_debug.
20+ if (TARGET dealii::dealii_release)
21+ message (STATUS "Using target dealii::dealii_release" )
22+ target_link_libraries (four_c_all_enabled_external_dependencies INTERFACE dealii::dealii_release)
23+ elseif (TARGET dealii::dealii_debug)
24+ message (STATUS "Using target dealii::dealii_debug" )
25+ target_link_libraries (four_c_all_enabled_external_dependencies INTERFACE dealii::dealii_debug)
26+ else ()
27+ message (FATAL_ERROR "Could not find target dealii::dealii_release or dealii::dealii_debug." )
28+ endif ()
29+
30+ include (${DEAL_II_GIT_CONFIG} )
31+ set (FOUR_C_deal.II_GIT_HASH "${DEAL_II_GIT_REVISION} " )
32+
33+ configure_file (
34+ "${PROJECT_SOURCE_DIR} /cmake/templates/deal.II.cmake.in"
35+ "${PROJECT_BINARY_DIR} /cmake/templates/deal.II.cmake"
36+ @ONLY
37+ )
Original file line number Diff line number Diff line change @@ -73,6 +73,7 @@ _add_dependency_to_settings(HDF5)
7373_add_dependency_to_settings(MPI)
7474_add_dependency_to_settings(Qhull)
7575_add_dependency_to_settings(Trilinos)
76+ _add_dependency_to_settings(deal.II)
7677_add_dependency_to_settings(Boost)
7778_add_dependency_to_settings(ArborX)
7879_add_dependency_to_settings(FFTW)
Original file line number Diff line number Diff line change @@ -27,6 +27,10 @@ if(FOUR_C_WITH_TRILINOS)
2727 endif ()
2828endif ()
2929
30+ if (FOUR_C_WITH_DEAL_II)
31+ find_package (deal.II REQUIRED CONFIG HINTS ${FOUR_C_DEAL_II_ROOT} )
32+ endif ()
33+
3034if (FOUR_C_WITH_BOOST)
3135 find_package (
3236 Boost
Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ set(FOUR_C_WITH_HDF5 @FOUR_C_WITH_HDF5@)
99set (FOUR_C_WITH_MPI @FOUR_C_WITH_MPI@)
1010set (FOUR_C_WITH_QHULL @FOUR_C_WITH_QHULL@)
1111set (FOUR_C_WITH_TRILINOS @FOUR_C_WITH_TRILINOS@)
12+ set (FOUR_C_WITH_DEAL_II @FOUR_C_WITH_DEAL_II@)
1213set (FOUR_C_WITH_BOOST @FOUR_C_WITH_BOOST@)
1314set (FOUR_C_WITH_ARBORX @FOUR_C_WITH_ARBORX@)
1415set (FOUR_C_WITH_FFTW @FOUR_C_WITH_FFTW@)
Original file line number Diff line number Diff line change 1+ set (FOUR_C_DEAL_II_ROOT "@FOUR_C_DEAL_II_ROOT@" )
Original file line number Diff line number Diff line change 1+ 6890ca740b6e51530ebb7ae7e4932977010ef2be 2025.1 v9.6.2
You can’t perform that action at this time.
0 commit comments