[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

gfortran: handling binNMU for .mod file format change



Hi, debian-devel and debian-science,
since Fortran90 programs are mostly science related,

Fortran90 -dev package may contain .mod files, which behave like
header files for C/C++ program. However, .mod files are binary files,
and compiler dependent, and what is worse, they are incompatible
between every major release of gfortran(e.g. we cannot use .mod file
created by gfortran4.7 with gfortran4.8, and vice versa).
Recompilation is required (thus binNMU is enough).

This creates a hidden dependency to Debian Fortran90 packages, and
many bugs are reported every time when gfortran default version was
upgraded.

# For the detailed background information, please see #714730.

Now that gfortran-4.8 (4.8.1-6) provides gfortran-mod-10 virtual
package (Thanks to Matthias Klose) which enables us to correctly
handle this hidden dependency, next we need to create a way to
automatically create correct dependencies when packaging.

# If we add a dependency to gfortran-mod-10 for every Fortran90
  package(which contains .mod file) explicitly, we need to change the
  source package manually. This is a regression from the current
  situation since we only need binNMU when mod file format change.

>From my limited understanding of debian packaging, I have to write a
debhelper script (say: dh_fortran_mod) which add the correct virtual
dependencies of Fortran mod file to ${misc:depends}.

Is this the correct way to proceed?

Of course, this does not solve the whole problem. One of the remaining
problems I can think of is:

1. Fortran90 program can only be compiled with only one(i.e. default)
version of gfortran.

There is no standard location of .mod files (nor version dependent
ones).  Having discussion with not only gfortran upstream but also
various commercial Fortran compiler vendors (Intel, PGI, NAG,
etc.)will be necessary.

Currently, most supercomputer center switch compilers by "module load"
mechanism (using Tcl scripts).

However, I strongly believe that we should have a mechanism for
handling .mod files correctly at least in the Debian world (and
hopefully do not break other compilers),

Best regards,
-- 
Ryo IGARASHI, Ph.D.
rigarash@gmail.com


Reply to: