Bug 2183289

Summary: hdf5: h5pfc Fortran compiler launchers use incorrect module search path
Product: [Fedora] Fedora Reporter: Brad King <brad.king>
Component: hdf5Assignee: Orion Poplawski <orion>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: igor.raits, orion, scitech-bugs, trpost
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: hdf5-1.14.5-9.fc43 hdf5-1.14.5-9.fc42 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2025-02-08 08:07:38 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Brad King 2023-03-30 19:03:45 UTC
In a `fedora:rawhide` container started today:

```
$ dnf install hdf5-openmpi-devel hdf5-mpich-devel hdf5-devel
...
 hdf5                       x86_64 1.12.1-11.fc38
 hdf5-mpich                 x86_64 1.12.1-11.fc38
 hdf5-openmpi               x86_64 1.12.1-11.fc38
...

$ cat test.f90
program test
  use hdf5
end
```

-----------------------------------------------------------------------

With OpenMPI under `module load mpi/openmpi-x86_64`:

```
$ h5pfc -c test.f90
f951: Warning: Nonexistent include directory '/usr/lib64/gfortran/modules/openmpi/openmpi-x86_64' [-Wmissing-include-dirs]
test.f90:2:7:

    2 |   use hdf5
      |       1
Fatal Error: Cannot open module file 'hdf5.mod' for reading at (1): No such file or directory
compilation terminated.
```

The module exists here:

```
$ ls $MPI_FORTRAN_MOD_DIR/hdf5.mod
/usr/lib64/gfortran/modules/openmpi/hdf5.mod
```

One can hack h5pfc to fix it like this:

```
$ sed -i '/^includedir=/ s|/openmpi-x86_64||' /usr/lib64/openmpi/bin/h5pfc

$ h5pfc -c test.f90
# (succeeds)
```

-----------------------------------------------------------------------

With MPICH under `module load mpi/mpich-x86_64`:

```
$ h5pfc -c test.f90
f951: Warning: Nonexistent include directory '/usr/lib64/gfortran/modules/mpich/mpich-x86_64' [-Wmissing-include-dirs]
```

The module exists here:

```
$ ls $MPI_FORTRAN_MOD_DIR/hdf5.mod
/usr/lib64/gfortran/modules/mpich/hdf5.mod
```

One can hack h5pfc to fix it like this:

```
$ sed -i '/^includedir=/ s|/mpich-x86_64||' /usr/lib64/mpich/bin/h5pfc

$ h5pfc -c test.f90
# (succeeds without warning)
```

Comment 1 Fedora Release Engineering 2023-08-16 07:12:42 UTC
This bug appears to have been reported against 'rawhide' during the Fedora Linux 39 development cycle.
Changing version to 39.

Comment 2 Aoife Moloney 2024-11-08 10:50:45 UTC
This message is a reminder that Fedora Linux 39 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora Linux 39 on 2024-11-26.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
'version' of '39'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, change the 'version' 
to a later Fedora Linux version. Note that the version field may be hidden.
Click the "Show advanced fields" button if you do not see it.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora Linux 39 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora Linux, you are encouraged to change the 'version' to a later version
prior to this bug being closed.

Comment 3 Aoife Moloney 2024-11-27 21:10:07 UTC
Fedora Linux 39 entered end-of-life (EOL) status on 2024-11-26.

Fedora Linux 39 is no longer maintained, which means that it
will not receive any further security or bug fix updates. As a result we
are closing this bug.

If you can reproduce this bug against a currently maintained version of Fedora Linux
please feel free to reopen this bug against that version. Note that the version
field may be hidden. Click the "Show advanced fields" button if you do not see
the version field.

If you are unable to reopen this bug, please file a new report against an
active release.

Thank you for reporting this bug and we are sorry it could not be fixed.

Comment 4 Brad King 2024-11-27 21:23:39 UTC
This still occurs on current 'rawhide' with 'hdf5' packages versioned '1.14.5-1.fc42'.

Comment 5 Fedora Update System 2025-02-08 08:03:24 UTC
FEDORA-2025-ec172e1c3b (hdf5-1.14.5-9.fc43) has been submitted as an update to Fedora 43.
https://bodhi.fedoraproject.org/updates/FEDORA-2025-ec172e1c3b

Comment 6 Fedora Update System 2025-02-08 08:04:25 UTC
FEDORA-2025-a2818fa465 (hdf5-1.14.5-9.fc42) has been submitted as an update to Fedora 42.
https://bodhi.fedoraproject.org/updates/FEDORA-2025-a2818fa465

Comment 7 Fedora Update System 2025-02-08 08:07:38 UTC
FEDORA-2025-ec172e1c3b (hdf5-1.14.5-9.fc43) has been pushed to the Fedora 43 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 8 Fedora Update System 2025-02-08 08:07:41 UTC
FEDORA-2025-a2818fa465 (hdf5-1.14.5-9.fc42) has been pushed to the Fedora 42 stable repository.
If problem still persists, please make note of it in this bug report.