Skip to content

Commit

Permalink
Replace deprecated Fortran 'include mpif.h' with 'USE mpi' (#4031)
Browse files Browse the repository at this point in the history
With MPI 4.1 the use of the mpif.h include file has been deprecated. Codes
should transition to USE mpi or USE mpi_f08.

Signed-off-by: Christoph Niethammer <[email protected]>
  • Loading branch information
cniethammer authored Feb 21, 2024
1 parent d4b43e0 commit f1e8f42
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion HDF5Examples/FORTRAN/H5PAR/ph5_f90_hyperslab_by_col.F90
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
PROGRAM DATASET_BY_COL

USE HDF5 ! This module contains all necessary modules
USE mpi

IMPLICIT NONE

include 'mpif.h'
CHARACTER(LEN=10), PARAMETER :: filename = "sds_col.h5" ! File name
CHARACTER(LEN=8), PARAMETER :: dsetname = "IntArray" ! Dataset name

Expand Down
2 changes: 1 addition & 1 deletion m4/aclocal_fc.f90
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ END PROGRAM FC_AVAIL_KINDS
!---- END ----- Determine the available KINDs for REALs and INTEGERs

PROGRAM FC_MPI_CHECK
INCLUDE 'mpif.h'
USE mpi
INTEGER :: comm, amode, info, fh, ierror
CHARACTER(LEN=1) :: filename
CALL MPI_File_open( comm, filename, amode, info, fh, ierror)
Expand Down
4 changes: 1 addition & 3 deletions release_docs/INSTALL_parallel
Original file line number Diff line number Diff line change
Expand Up @@ -358,11 +358,9 @@ main(int ac, char **av)

PROGRAM MPIOEXAMPLE

! USE MPI
USE mpi

IMPLICIT NONE

INCLUDE 'mpif.h'

CHARACTER(LEN=80), PARAMETER :: filename = "filef.h5" ! File name
INTEGER :: ierror ! Error flag
Expand Down

0 comments on commit f1e8f42

Please sign in to comment.