# ------------------------------------------------------------------------------ # OOMPH auto-inserted: warn once if user configures inside an existing build. if(EXISTS "${CMAKE_CURRENT_BINARY_DIR}/CMakeCache.txt" AND CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR) message( WARNING "You're re-configuring an existing build tree. For a clean configuration, " "delete the whole build folder and start with a fresh directory.") endif() # ------------------------------------------------------------------------------ list(APPEND CMAKE_MESSAGE_INDENT " ") message(VERBOSE "Entered adaptive_driven_cavity subdirectory") cmake_minimum_required(VERSION 3.22 FATAL_ERROR) project(adaptive_driven_cavity C CXX Fortran) if(NOT oomphlib_FOUND) find_package(oomphlib CONFIG REQUIRED PATHS "../../../../install") endif() include(CTest) oomph_add_executable( NAME adaptive_driven_cavity SOURCES adaptive_driven_cavity.cc LIBRARIES oomph::navier_stokes oomph::meshes oomph::generic) oomph_add_executable( NAME adaptive_driven_cavity_load_balance SOURCES adaptive_driven_cavity_load_balance.cc LIBRARIES oomph::navier_stokes oomph::meshes oomph::generic) # ---------------------------------- TESTING ---------------------------------- oomph_add_test( TEST_NAME mpi.distribution.adaptive_driven_cavity DEPENDS_ON adaptive_driven_cavity adaptive_driven_cavity_load_balance COMMAND ./validate.sh ${OOMPH_ROOT_DIR} ${OOMPH_MPI_RUN_COMMAND} TEST_FILES validate.sh validata adaptive_cavity_1_partition.dat adaptive_cavity_2_partition.dat load_balance.mcr prune_and_balance.mcr) # Tell CTest how many processors the test is likely to use set_tests_properties(mpi.distribution.adaptive_driven_cavity PROPERTIES PROCESSORS ${OOMPH_MPI_NUM_PROC}) message(VERBOSE "Leaving adaptive_driven_cavity subdirectory") # ------------------------------------------------------------------------------