1*af0996ceSBarry Smith #include <petsc/private/fortranimpl.h> 2665c2dedSJed Brown #include <petscviewer.h> 35c6c1daeSBarry Smith 45c6c1daeSBarry Smith #if defined(PETSC_HAVE_FORTRAN_CAPS) 55c6c1daeSBarry Smith #define petsc_viewer_stdout__ PETSC_VIEWER_STDOUT_BROKEN 65c6c1daeSBarry Smith #define petscviewerasciiopen_ PETSCVIEWERASCIIOPEN 75c6c1daeSBarry Smith #elif !defined(PETSC_HAVE_FORTRAN_UNDERSCORE) 85c6c1daeSBarry Smith #define petscviewerasciiopen_ petscviewerasciiopen 95c6c1daeSBarry Smith #define petsc_viewer_stdout__ petsc_viewer_stdout_ 105c6c1daeSBarry Smith #endif 115c6c1daeSBarry Smith 125c6c1daeSBarry Smith #if defined(PETSC_HAVE_FORTRAN_UNDERSCORE_UNDERSCORE) 135c6c1daeSBarry Smith #define petsc_viewer_stdout__ petsc_viewer_stdout___ 145c6c1daeSBarry Smith #endif 155c6c1daeSBarry Smith 168cc058d9SJed Brown PETSC_EXTERN void PETSC_STDCALL petscviewerasciiopen_(MPI_Comm *comm,CHAR name PETSC_MIXED_LEN(len),PetscViewer *lab, 175c6c1daeSBarry Smith PetscErrorCode *ierr PETSC_END_LEN(len)) 185c6c1daeSBarry Smith { 195c6c1daeSBarry Smith char *c1; 205c6c1daeSBarry Smith FIXCHAR(name,len,c1); 215c6c1daeSBarry Smith *ierr = PetscViewerASCIIOpen(MPI_Comm_f2c(*(MPI_Fint*)&*comm),c1,lab); 225c6c1daeSBarry Smith FREECHAR(name,c1); 235c6c1daeSBarry Smith } 245c6c1daeSBarry Smith 258cc058d9SJed Brown PETSC_EXTERN PetscViewer PETSC_STDCALL petsc_viewer_stdout__(MPI_Comm *comm) 265c6c1daeSBarry Smith { 275c6c1daeSBarry Smith return PETSC_VIEWER_STDOUT_(MPI_Comm_f2c(*(MPI_Fint*)&*comm)); 285c6c1daeSBarry Smith } 295c6c1daeSBarry Smith 305c6c1daeSBarry Smith 31