From cc7571e28668e27c7ac6434951dd126500fd7488 Mon Sep 17 00:00:00 2001 From: tradke Date: Fri, 4 Jan 2002 12:53:24 +0000 Subject: More stuff for backwards compatibility to older PETSc versions. git-svn-id: http://svn.cactuscode.org/arrangements/CactusElliptic/EllPETSc/trunk@63 1d96b42b-98df-4a6a-9d84-1b24288d4588 --- src/petsc_confmetric_solver.c | 4 ++++ src/petsc_flat_solver.c | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/src/petsc_confmetric_solver.c b/src/petsc_confmetric_solver.c index 7ef205e..131b26c 100644 --- a/src/petsc_confmetric_solver.c +++ b/src/petsc_confmetric_solver.c @@ -867,7 +867,11 @@ int petsc_confmetric_solver(cGH *GH, int *MetricPsiI, int MetricPsiISize, } if (trips==0) { +#if PETSC_VERSION_MAJOR < 2 || (PETSC_VERSION_MAJOR == 2 && PETSC_VERSION_MINOR == 0) + OptionsSetValue("-ksp_monitor",""); +#else PetscOptionsSetValue("-ksp_monitor",""); +#endif } if (verbose) diff --git a/src/petsc_flat_solver.c b/src/petsc_flat_solver.c index 5f5172d..e76631a 100644 --- a/src/petsc_flat_solver.c +++ b/src/petsc_flat_solver.c @@ -481,7 +481,11 @@ int petsc_flat(cGH *GH, int FieldIndex, int MIndex, int NIndex, if (trips==0) { +#if PETSC_VERSION_MAJOR < 2 || (PETSC_VERSION_MAJOR == 2 && PETSC_VERSION_MINOR == 0) + OptionsSetValue("-ksp_monitor",""); +#else PetscOptionsSetValue("-ksp_monitor",""); +#endif } if (verbose) -- cgit v1.2.3