From: Wolfgang Bangerth Date: Fri, 9 Jan 2015 07:26:37 +0000 (-0600) Subject: For programs that use Trilinos, we need to initialize the MPI system even if the... X-Git-Tag: v8.3.0-rc1~561^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F412%2Fhead;p=dealii.git For programs that use Trilinos, we need to initialize the MPI system even if the program does not in fact use MPI. --- diff --git a/examples/step-43/step-43.cc b/examples/step-43/step-43.cc index 2d89d11627..e5be5dfc58 100644 --- a/examples/step-43/step-43.cc +++ b/examples/step-43/step-43.cc @@ -2239,8 +2239,11 @@ start_time_iteration: // @sect3{The main() function} // -// The main function looks almost the same as in all other programs: -int main () +// The main function looks almost the same as in all other programs. The need +// to initialize the MPI subsystem for a program that uses Trilinos -- even +// for programs that do not actually run in parallel -- is explained in +// step-31. +int main (int argc, char *argv[]) { try { @@ -2249,6 +2252,8 @@ int main () deallog.depth_console (0); + Utilities::MPI::MPI_InitFinalize mpi_initialization (argc, argv); + TwoPhaseFlowProblem<2> two_phase_flow_problem(1); two_phase_flow_problem.run (); }