diff --git a/host-configs/apple/macOS_base.cmake b/host-configs/apple/macOS_base.cmake index e300aca41a7..45911758b50 100644 --- a/host-configs/apple/macOS_base.cmake +++ b/host-configs/apple/macOS_base.cmake @@ -27,7 +27,9 @@ set( LAPACK_LIBRARIES ${HOMEBREW_DIR}/opt/lapack/lib/liblapack.dylib CACHE PATH set(ENABLE_DOXYGEN OFF CACHE BOOL "" FORCE) set(ENABLE_MATHPRESSO OFF CACHE BOOL "" FORCE ) -#set(GEOS_BUILD_OBJ_LIBS ON CACHE BOOL "" FORCE) + +set(GEOS_BUILD_SHARED_LIBS ON CACHE BOOL "" FORCE) +set(GEOS_BUILD_SHARED_CORE_LIB OFF CACHE BOOL "" FORCE) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 8f58f0db475..eb34514c777 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -144,7 +144,7 @@ endif() blt_add_executable( NAME geosx SOURCES main/main.cpp DEPENDS_ON ${extraComponentsLinkList} - ${externalComponentsLinkList} fmt::fmt-header-only HDF5::HDF5 ) + ${externalComponentsLinkList} ) # blt_print_target_properties(TARGET geosx # CHILDREN TRUE diff --git a/src/cmake/GeosxOptions.cmake b/src/cmake/GeosxOptions.cmake index 22badab8849..b3b15983dcf 100644 --- a/src/cmake/GeosxOptions.cmake +++ b/src/cmake/GeosxOptions.cmake @@ -91,6 +91,8 @@ option( GEOS_BUILD_OBJ_LIBS "Builds coreComponent modules as object libraries" O option( GEOS_BUILD_SHARED_CORE_LIB "Builds geosx_core as a shared library " ON ) +option( GEOS_BUILD_SHARED_LIBS "Builds geosx_core as a shared library " OFF ) + set( GEOS_PARALLEL_COMPILE_JOBS "" CACHE STRING "Maximum number of concurrent compilation jobs" ) if( GEOS_PARALLEL_COMPILE_JOBS ) set_property( GLOBAL APPEND PROPERTY JOB_POOLS compile_job_pool=${GEOS_PARALLEL_COMPILE_JOBS} ) diff --git a/src/coreComponents/codingUtilities/CMakeLists.txt b/src/coreComponents/codingUtilities/CMakeLists.txt index a85e4046907..af760d67884 100644 --- a/src/coreComponents/codingUtilities/CMakeLists.txt +++ b/src/coreComponents/codingUtilities/CMakeLists.txt @@ -26,6 +26,7 @@ blt_add_library( NAME codingUtilities HEADERS ${codingUtilities_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) # Avoid compiling with nvcc which sometimes crashes on fast_float diff --git a/src/coreComponents/common/CMakeLists.txt b/src/coreComponents/common/CMakeLists.txt index 2a5f70ff960..7fbece44c48 100644 --- a/src/coreComponents/common/CMakeLists.txt +++ b/src/coreComponents/common/CMakeLists.txt @@ -109,6 +109,7 @@ blt_add_library( NAME common HEADERS ${common_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) target_include_directories( common PUBLIC ${CMAKE_BINARY_DIR}/include ) diff --git a/src/coreComponents/constitutive/CMakeLists.txt b/src/coreComponents/constitutive/CMakeLists.txt index ceb6c71f50f..8296a95d96a 100644 --- a/src/coreComponents/constitutive/CMakeLists.txt +++ b/src/coreComponents/constitutive/CMakeLists.txt @@ -39,8 +39,8 @@ set( constitutive_headers fluid/multifluid/MultiFluidConstants.hpp fluid/multifluid/MultiFluidUtils.hpp fluid/multifluid/MultiFluidFields.hpp - fluid/multifluid/PVTDriver.hpp - fluid/multifluid/PVTDriverRunTest.hpp + # fluid/multifluid/PVTDriver.hpp + # fluid/multifluid/PVTDriverRunTest.hpp fluid/multifluid/blackOil/BlackOilFluidBase.hpp fluid/multifluid/blackOil/BlackOilFluid.hpp fluid/multifluid/blackOil/DeadOilFluid.hpp @@ -89,8 +89,8 @@ set( constitutive_headers fluid/multifluid/reactive/ReactiveBrineFluid.hpp fluid/multifluid/reactive/ReactiveMultiFluid.hpp fluid/multifluid/reactive/ReactiveMultiFluidFields.hpp - fluid/multifluid/reactive/ReactiveFluidDriver.hpp - fluid/multifluid/reactive/ReactiveFluidSelector.hpp + # fluid/multifluid/reactive/ReactiveFluidDriver.hpp + # fluid/multifluid/reactive/ReactiveFluidSelector.hpp fluid/multifluid/reactive/chemicalReactions/EquilibriumReactions.hpp fluid/multifluid/reactive/chemicalReactions/KineticReactions.hpp fluid/multifluid/reactive/chemicalReactions/ReactionsBase.hpp @@ -116,8 +116,8 @@ set( constitutive_headers permeability/ProppantPermeability.hpp permeability/SlipDependentPermeability.hpp permeability/WillisRichardsPermeability.hpp - relativePermeability/RelpermDriver.hpp - relativePermeability/RelpermDriverRunTest.hpp + # relativePermeability/RelpermDriver.hpp + # relativePermeability/RelpermDriverRunTest.hpp relativePermeability/BrooksCoreyBakerRelativePermeability.hpp relativePermeability/BrooksCoreyStone2RelativePermeability.hpp relativePermeability/BrooksCoreyRelativePermeability.hpp @@ -161,7 +161,7 @@ set( constitutive_headers solid/SolidModelDiscretizationOpsTransverseIsotropic.hpp solid/SolidModelDiscretizationOpsOrthotropic.hpp solid/CeramicDamage.hpp - solid/TriaxialDriver.hpp + # solid/TriaxialDriver.hpp solid/porosity/PorosityFields.hpp solid/porosity/BiotPorosity.hpp solid/porosity/PorosityBase.hpp @@ -203,17 +203,17 @@ set( constitutive_sources dispersion/DispersionBase.cpp dispersion/LinearIsotropicDispersion.cpp fluid/multifluid/MultiFluidBase.cpp - fluid/multifluid/PVTDriver.cpp + # fluid/multifluid/PVTDriver.cpp fluid/multifluid/blackOil/BlackOilFluidBase.cpp fluid/multifluid/blackOil/BlackOilFluid.cpp fluid/multifluid/blackOil/DeadOilFluid.cpp - fluid/multifluid/blackOil/PVTDriverRunTestDeadOilFluid.cpp + # fluid/multifluid/blackOil/PVTDriverRunTestDeadOilFluid.cpp fluid/multifluid/blackOil/PVTOData.cpp fluid/multifluid/CO2Brine/CO2BrineFluid.cpp - fluid/multifluid/CO2Brine/PVTDriverRunTestCO2BrinePhillipsFluid.cpp - fluid/multifluid/CO2Brine/PVTDriverRunTestCO2BrinePhillipsThermalFluid.cpp - fluid/multifluid/CO2Brine/PVTDriverRunTestCO2BrineEzrokhiFluid.cpp - fluid/multifluid/CO2Brine/PVTDriverRunTestCO2BrineEzrokhiThermalFluid.cpp + # fluid/multifluid/CO2Brine/PVTDriverRunTestCO2BrinePhillipsFluid.cpp + # fluid/multifluid/CO2Brine/PVTDriverRunTestCO2BrinePhillipsThermalFluid.cpp + # fluid/multifluid/CO2Brine/PVTDriverRunTestCO2BrineEzrokhiFluid.cpp + # fluid/multifluid/CO2Brine/PVTDriverRunTestCO2BrineEzrokhiThermalFluid.cpp fluid/multifluid/CO2Brine/functions/PhillipsBrineDensity.cpp fluid/multifluid/CO2Brine/functions/PhillipsBrineViscosity.cpp fluid/multifluid/CO2Brine/functions/EzrokhiBrineDensity.cpp @@ -235,11 +235,11 @@ set( constitutive_sources fluid/multifluid/compositional/models/NegativeTwoPhaseFlashModel.cpp fluid/multifluid/compositional/CompositionalMultiphaseFluid.cpp fluid/multifluid/compositional/CompositionalMultiphaseFluidUpdates.cpp - fluid/multifluid/compositional/PVTDriverRunTestCompositionalTwoPhaseConstantViscosity.cpp - fluid/multifluid/compositional/PVTDriverRunTestCompositionalTwoPhaseLohrenzBrayClarkViscosity.cpp + # fluid/multifluid/compositional/PVTDriverRunTestCompositionalTwoPhaseConstantViscosity.cpp + # fluid/multifluid/compositional/PVTDriverRunTestCompositionalTwoPhaseLohrenzBrayClarkViscosity.cpp fluid/multifluid/reactive/ReactiveBrineFluid.cpp fluid/multifluid/reactive/ReactiveMultiFluid.cpp - fluid/multifluid/reactive/ReactiveFluidDriver.cpp + # fluid/multifluid/reactive/ReactiveFluidDriver.cpp fluid/multifluid/reactive/chemicalReactions/EquilibriumReactions.cpp fluid/multifluid/reactive/chemicalReactions/KineticReactions.cpp fluid/multifluid/reactive/chemicalReactions/ReactionsBase.cpp @@ -268,14 +268,14 @@ set( constitutive_sources relativePermeability/TableRelativePermeabilityHysteresis.cpp relativePermeability/VanGenuchtenBakerRelativePermeability.cpp relativePermeability/VanGenuchtenStone2RelativePermeability.cpp - relativePermeability/RelpermDriver.cpp - relativePermeability/RelpermDriverBrooksCoreyBakerRunTest.cpp - relativePermeability/RelpermDriverBrooksCoreyStone2RunTest.cpp - relativePermeability/RelpermDriverBrooksCoreyRunTest.cpp - relativePermeability/RelpermDriverVanGenuchtenBakerRunTest.cpp - relativePermeability/RelpermDriverVanGenuchtenStone2RunTest.cpp - relativePermeability/RelpermDriverTableRelativeRunTest.cpp - relativePermeability/RelpermDriverTableRelativeHysteresisRunTest.cpp + # relativePermeability/RelpermDriver.cpp + # relativePermeability/RelpermDriverBrooksCoreyBakerRunTest.cpp + # relativePermeability/RelpermDriverBrooksCoreyStone2RunTest.cpp + # relativePermeability/RelpermDriverBrooksCoreyRunTest.cpp + # relativePermeability/RelpermDriverVanGenuchtenBakerRunTest.cpp + # relativePermeability/RelpermDriverVanGenuchtenStone2RunTest.cpp + # relativePermeability/RelpermDriverTableRelativeRunTest.cpp + # relativePermeability/RelpermDriverTableRelativeHysteresisRunTest.cpp solid/CompressibleSolid.cpp solid/CoupledSolidBase.cpp solid/ProppantSolid.cpp @@ -296,7 +296,7 @@ set( constitutive_sources solid/SolidBase.cpp solid/SolidInternalEnergy.cpp solid/CeramicDamage.cpp - solid/TriaxialDriver.cpp + # solid/TriaxialDriver.cpp solid/porosity/BiotPorosity.cpp solid/porosity/PorosityBase.cpp solid/porosity/PressurePorosity.cpp @@ -318,7 +318,8 @@ if( ENABLE_PVTPackage ) set( constitutive_sources ${constitutive_sources} fluid/multifluid/compositional/CompositionalMultiphaseFluidPVTPackage.cpp - fluid/multifluid/compositional/PVTDriverRunTestCompositionalMultiphaseFluid.cpp ) + # fluid/multifluid/compositional/PVTDriverRunTestCompositionalMultiphaseFluid.cpp + ) add_subdirectory( PVTPackage ) @@ -330,6 +331,7 @@ blt_add_library( NAME constitutive HEADERS ${constitutive_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) target_include_directories( constitutive PUBLIC ${CMAKE_SOURCE_DIR}/coreComponents ) diff --git a/src/coreComponents/dataRepository/CMakeLists.txt b/src/coreComponents/dataRepository/CMakeLists.txt index bfaecd6d778..596c62edecd 100644 --- a/src/coreComponents/dataRepository/CMakeLists.txt +++ b/src/coreComponents/dataRepository/CMakeLists.txt @@ -55,7 +55,9 @@ blt_add_library( NAME dataRepository SOURCES ${dataRepository_sources} HEADERS ${dataRepository_headers} DEPENDS_ON ${dependencyList} - OBJECT ${GEOS_BUILD_OBJ_LIBS} ) + OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} + ) target_include_directories( dataRepository PUBLIC ${CMAKE_SOURCE_DIR}/coreComponents ) diff --git a/src/coreComponents/denseLinearAlgebra/CMakeLists.txt b/src/coreComponents/denseLinearAlgebra/CMakeLists.txt index 791767bc5c6..de751dff89a 100644 --- a/src/coreComponents/denseLinearAlgebra/CMakeLists.txt +++ b/src/coreComponents/denseLinearAlgebra/CMakeLists.txt @@ -14,7 +14,9 @@ blt_add_library( NAME denseLinearAlgebra SOURCES ${denseLinearAlgebra_sources} HEADERS ${denseLinearAlgebra_headers} DEPENDS_ON ${dependencyList} - OBJECT ${GEOS_BUILD_OBJ_LIBS} ) + OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} + ) target_include_directories( denseLinearAlgebra PUBLIC ${CMAKE_CURRENT_LIST_DIR} ) diff --git a/src/coreComponents/discretizationMethods/CMakeLists.txt b/src/coreComponents/discretizationMethods/CMakeLists.txt index 220d535ab28..90818239cc7 100644 --- a/src/coreComponents/discretizationMethods/CMakeLists.txt +++ b/src/coreComponents/discretizationMethods/CMakeLists.txt @@ -18,6 +18,7 @@ blt_add_library( NAME discretizationMethods HEADERS ${mainInterface_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) target_include_directories( discretizationMethods PUBLIC ${CMAKE_SOURCE_DIR}/coreComponents ) diff --git a/src/coreComponents/events/CMakeLists.txt b/src/coreComponents/events/CMakeLists.txt index 070be631638..bcee887022f 100644 --- a/src/coreComponents/events/CMakeLists.txt +++ b/src/coreComponents/events/CMakeLists.txt @@ -24,13 +24,14 @@ set( events_sources tasks/TasksManager.cpp ) -set( dependencyList ${parallelDeps} fileIO ) +set( dependencyList ${parallelDeps} mesh ) blt_add_library( NAME events SOURCES ${events_sources} HEADERS ${events_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) target_include_directories( events PUBLIC ${CMAKE_SOURCE_DIR}/coreComponents ) diff --git a/src/coreComponents/fieldSpecification/CMakeLists.txt b/src/coreComponents/fieldSpecification/CMakeLists.txt index 7337cb2a73b..cb7d0cd8d18 100644 --- a/src/coreComponents/fieldSpecification/CMakeLists.txt +++ b/src/coreComponents/fieldSpecification/CMakeLists.txt @@ -33,6 +33,7 @@ blt_add_library( NAME fieldSpecification HEADERS ${fieldSpecification_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) target_include_directories( fieldSpecification PUBLIC ${CMAKE_SOURCE_DIR}/coreComponents ) diff --git a/src/coreComponents/fileIO/CMakeLists.txt b/src/coreComponents/fileIO/CMakeLists.txt index 1570ec71185..ef15f430d7c 100644 --- a/src/coreComponents/fileIO/CMakeLists.txt +++ b/src/coreComponents/fileIO/CMakeLists.txt @@ -28,7 +28,7 @@ set( fileIO_sources timeHistory/PackCollection.cpp timeHistory/HDFHistoryIO.cpp ) -set( dependencyList ${parallelDeps} mesh HDF5::HDF5 ) +set( dependencyList ${parallelDeps} events mesh HDF5::HDF5 ) if( ENABLE_PYGEOSX ) list( APPEND fileIO_headers python/PyHistoryCollectionType.hpp @@ -83,7 +83,9 @@ blt_add_library( NAME fileIO SOURCES ${fileIO_sources} HEADERS ${fileIO_headers} DEPENDS_ON ${dependencyList} - OBJECT ${GEOS_BUILD_OBJ_LIBS} ) + OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} + ) target_include_directories( fileIO PUBLIC ${CMAKE_SOURCE_DIR}/coreComponents ) diff --git a/src/coreComponents/finiteElement/CMakeLists.txt b/src/coreComponents/finiteElement/CMakeLists.txt index a1e5b0b4ad4..cca1d9cb351 100644 --- a/src/coreComponents/finiteElement/CMakeLists.txt +++ b/src/coreComponents/finiteElement/CMakeLists.txt @@ -47,6 +47,7 @@ blt_add_library( NAME finiteElement HEADERS ${finiteElement_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) target_include_directories( finiteElement PUBLIC ${CMAKE_SOURCE_DIR}/coreComponents ) diff --git a/src/coreComponents/finiteVolume/CMakeLists.txt b/src/coreComponents/finiteVolume/CMakeLists.txt index 5ca625a8504..23aa1adaf63 100644 --- a/src/coreComponents/finiteVolume/CMakeLists.txt +++ b/src/coreComponents/finiteVolume/CMakeLists.txt @@ -47,6 +47,7 @@ blt_add_library( NAME finiteVolume HEADERS ${finiteVolume_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) target_include_directories( finiteVolume PUBLIC ${CMAKE_SOURCE_DIR}/coreComponents ) diff --git a/src/coreComponents/functions/CMakeLists.txt b/src/coreComponents/functions/CMakeLists.txt index b77254f8f28..a3d016fc44c 100644 --- a/src/coreComponents/functions/CMakeLists.txt +++ b/src/coreComponents/functions/CMakeLists.txt @@ -38,6 +38,7 @@ blt_add_library( NAME functions HEADERS ${functions_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) target_include_directories( functions PUBLIC ${CMAKE_SOURCE_DIR}/coreComponents ) diff --git a/src/coreComponents/linearAlgebra/CMakeLists.txt b/src/coreComponents/linearAlgebra/CMakeLists.txt index 07c823d8300..7283f50e4f4 100644 --- a/src/coreComponents/linearAlgebra/CMakeLists.txt +++ b/src/coreComponents/linearAlgebra/CMakeLists.txt @@ -154,6 +154,7 @@ blt_add_library( NAME linearAlgebra HEADERS ${linearAlgebra_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) target_include_directories( linearAlgebra PUBLIC ${CMAKE_CURRENT_LIST_DIR} ) diff --git a/src/coreComponents/mainInterface/CMakeLists.txt b/src/coreComponents/mainInterface/CMakeLists.txt index 6ffb065c37b..289490a8a81 100644 --- a/src/coreComponents/mainInterface/CMakeLists.txt +++ b/src/coreComponents/mainInterface/CMakeLists.txt @@ -25,6 +25,7 @@ blt_add_library( NAME mainInterface HEADERS ${mainInterface_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) add_dependencies( mainInterface generate_version ) diff --git a/src/coreComponents/mesh/CMakeLists.txt b/src/coreComponents/mesh/CMakeLists.txt index 281097ec970..333ef65a556 100644 --- a/src/coreComponents/mesh/CMakeLists.txt +++ b/src/coreComponents/mesh/CMakeLists.txt @@ -184,7 +184,9 @@ blt_add_library( NAME mesh SOURCES ${mesh_sources} HEADERS ${mesh_headers} DEPENDS_ON ${dependencyList} - OBJECT ${GEOS_BUILD_OBJ_LIBS} ) + OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} + ) target_include_directories( mesh PUBLIC ${CMAKE_SOURCE_DIR}/coreComponents ) diff --git a/src/coreComponents/physicsSolvers/CMakeLists.txt b/src/coreComponents/physicsSolvers/CMakeLists.txt index e41e5ffaf73..bb387031db9 100644 --- a/src/coreComponents/physicsSolvers/CMakeLists.txt +++ b/src/coreComponents/physicsSolvers/CMakeLists.txt @@ -51,7 +51,7 @@ if( GEOS_ENABLE_WAVEPROPAGATION ) add_subdirectory( wavePropagation ) endif() -set( dependencyList ${parallelDeps} discretizationMethods events ) +set( dependencyList ${parallelDeps} fileIO discretizationMethods events ) if( ENABLE_PYGEOSX ) list( APPEND physicsSolvers_headers python/PySolver.hpp @@ -65,7 +65,9 @@ blt_add_library( NAME physicsSolvers SOURCES ${physicsSolvers_sources} HEADERS ${physicsSolvers_headers} DEPENDS_ON ${dependencyList} ${externalComponentDeps} - OBJECT ${GEOS_BUILD_OBJ_LIBS} ) + OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} + ) target_include_directories( physicsSolvers PUBLIC ${CMAKE_SOURCE_DIR}/coreComponents ) if( externalComponentDeps ) diff --git a/src/coreComponents/physicsSolvers/FieldStatisticsBase.hpp b/src/coreComponents/physicsSolvers/FieldStatisticsBase.hpp index 5edf76ab710..96bfbb29556 100644 --- a/src/coreComponents/physicsSolvers/FieldStatisticsBase.hpp +++ b/src/coreComponents/physicsSolvers/FieldStatisticsBase.hpp @@ -22,7 +22,6 @@ #include "events/tasks/TaskBase.hpp" #include "physicsSolvers/PhysicsSolverManager.hpp" -#include "mainInterface/ProblemManager.hpp" #include "mesh/MeshLevel.hpp" #include "fileIO/Outputs/OutputBase.hpp" @@ -84,8 +83,8 @@ class FieldStatisticsBase : public TaskBase void postInputInitialization() override { - ProblemManager & problemManager = this->getGroupByPath< ProblemManager >( "/Problem" ); - PhysicsSolverManager & physicsSolverManager = problemManager.getPhysicsSolverManager(); + Group & problemManager = this->getGroupByPath( "/Problem" ); + Group & physicsSolverManager = problemManager.getGroup("Solvers"); m_solver = physicsSolverManager.getGroupPointer< SOLVER >( m_solverName ); GEOS_THROW_IF( m_solver == nullptr, diff --git a/src/coreComponents/physicsSolvers/fluidFlow/StencilDataCollection.cpp b/src/coreComponents/physicsSolvers/fluidFlow/StencilDataCollection.cpp index 9a4a4dc06aa..e939067dc0e 100644 --- a/src/coreComponents/physicsSolvers/fluidFlow/StencilDataCollection.cpp +++ b/src/coreComponents/physicsSolvers/fluidFlow/StencilDataCollection.cpp @@ -24,7 +24,6 @@ #include "constitutive/permeability/PermeabilityBase.hpp" #include "constitutive/permeability/PermeabilityFields.hpp" #include "physicsSolvers/fluidFlow/StencilAccessors.hpp" -#include "mainInterface/ProblemManager.hpp" #include "physicsSolvers/PhysicsSolverManager.hpp" #include "common/format/table/TableFormatter.hpp" @@ -61,10 +60,10 @@ StencilDataCollection::StencilDataCollection( const string & name, void StencilDataCollection::postInputInitialization() { - ProblemManager & problemManager = this->getGroupByPath< ProblemManager >( "/Problem" ); + Group & problemManager = this->getGroupByPath( "/Problem" ); { // find targeted solver - PhysicsSolverManager & physicsSolverManager = problemManager.getPhysicsSolverManager(); + Group & physicsSolverManager = problemManager.getGroup("Solvers"); m_solver = physicsSolverManager.getGroupPointer< FlowSolverBase >( m_solverName ); GEOS_THROW_IF( m_solver == nullptr, @@ -75,7 +74,8 @@ void StencilDataCollection::postInputInitialization() } { // find mesh & discretization - DomainPartition & domain = problemManager.getDomainPartition(); +// DomainPartition & domain = problemManager.getDomainPartition(); + DomainPartition & domain = problemManager.getGroup< DomainPartition >( "domain" ); MeshBody const & meshBody = domain.getMeshBody( m_meshName ); m_meshLevel = &meshBody.getBaseDiscretization(); diff --git a/src/coreComponents/physicsSolvers/multiphysics/PoromechanicsInitialization.cpp b/src/coreComponents/physicsSolvers/multiphysics/PoromechanicsInitialization.cpp index 9505e80bfb3..ec74dd5a511 100644 --- a/src/coreComponents/physicsSolvers/multiphysics/PoromechanicsInitialization.cpp +++ b/src/coreComponents/physicsSolvers/multiphysics/PoromechanicsInitialization.cpp @@ -25,7 +25,6 @@ #include "physicsSolvers/multiphysics/SinglePhasePoromechanicsConformingFractures.hpp" #include "physicsSolvers/multiphysics/SinglePhasePoromechanicsEmbeddedFractures.hpp" #include "physicsSolvers/multiphysics/HydrofractureSolver.hpp" -#include "mainInterface/ProblemManager.hpp" #include "physicsSolvers/fluidFlow/SinglePhaseBase.hpp" #include "physicsSolvers/multiphysics/SinglePhaseReservoirAndWells.hpp" #include "physicsSolvers/multiphysics/CompositionalMultiphaseReservoirAndWells.hpp" @@ -68,8 +67,8 @@ void PoromechanicsInitialization< POROMECHANICS_SOLVER >:: postInputInitialization() { - ProblemManager & problemManager = this->getGroupByPath< ProblemManager >( "/Problem" ); - PhysicsSolverManager & physicsSolverManager = problemManager.getPhysicsSolverManager(); + Group & problemManager = this->getGroupByPath( "/Problem" ); + Group & physicsSolverManager = problemManager.getGroup("Solvers"); GEOS_THROW_IF( !physicsSolverManager.hasGroup( m_poromechanicsSolverName ), GEOS_FMT( "{}: {} solver named {} not found", @@ -82,7 +81,7 @@ postInputInitialization() if( !m_solidMechanicsStatisticsName.empty()) { - TasksManager & tasksManager = problemManager.getTasksManager(); + TasksManager & tasksManager = problemManager.getGroup("Tasks"); GEOS_THROW_IF( !tasksManager.hasGroup( m_solidMechanicsStatisticsName ), GEOS_FMT( "{}: statistics task named {} not found", diff --git a/src/coreComponents/physicsSolvers/solidMechanics/SolidMechanicsStateReset.cpp b/src/coreComponents/physicsSolvers/solidMechanics/SolidMechanicsStateReset.cpp index ceca67b46c2..9f9ee6b36b0 100644 --- a/src/coreComponents/physicsSolvers/solidMechanics/SolidMechanicsStateReset.cpp +++ b/src/coreComponents/physicsSolvers/solidMechanics/SolidMechanicsStateReset.cpp @@ -21,7 +21,6 @@ #include "physicsSolvers/PhysicsSolverManager.hpp" #include "physicsSolvers/solidMechanics/SolidMechanicsLagrangianFEM.hpp" -#include "mainInterface/ProblemManager.hpp" #include "mesh/DomainPartition.hpp" namespace geos @@ -59,8 +58,8 @@ SolidMechanicsStateReset::~SolidMechanicsStateReset() void SolidMechanicsStateReset::postInputInitialization() { - ProblemManager & problemManager = this->getGroupByPath< ProblemManager >( "/Problem" ); - PhysicsSolverManager & physicsSolverManager = problemManager.getPhysicsSolverManager(); + Group & problemManager = this->getGroupByPath( "/Problem" ); + Group & physicsSolverManager = problemManager.getGroup("Solvers"); GEOS_THROW_IF( !physicsSolverManager.hasGroup( m_solidSolverName ), GEOS_FMT( "Task {}: physics solver named {} not found", diff --git a/src/coreComponents/schema/CMakeLists.txt b/src/coreComponents/schema/CMakeLists.txt index ecae0b5dd75..a32f052ee98 100644 --- a/src/coreComponents/schema/CMakeLists.txt +++ b/src/coreComponents/schema/CMakeLists.txt @@ -19,6 +19,7 @@ blt_add_library( NAME schema HEADERS ${schema_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) diff --git a/src/coreComponents/unitTests/testingUtilities/CMakeLists.txt b/src/coreComponents/unitTests/testingUtilities/CMakeLists.txt index 990398794f8..4f0f9d4096d 100644 --- a/src/coreComponents/unitTests/testingUtilities/CMakeLists.txt +++ b/src/coreComponents/unitTests/testingUtilities/CMakeLists.txt @@ -28,6 +28,7 @@ blt_add_library( NAME testingUtilities HEADERS ${testingUtilities_headers} DEPENDS_ON ${dependencyList} OBJECT ${GEOS_BUILD_OBJ_LIBS} + SHARED ${GEOS_BUILD_SHARED_LIBS} ) target_include_directories( testingUtilities PUBLIC ${CMAKE_SOURCE_DIR}/coreComponents )