[Scons-users] Dependences build fail in Windows using gfortran

Mats Wichmann mats at wichmann.us
Tue May 7 13:04:57 EDT 2019


On 5/6/19 9:45 AM, Bill Deegan wrote:
> Is this likely caused by missing information about the .smod files?
> 
> I've put a note on the issue you filed.
> Please do not file an issue until the community has verified it's not
> already filed and the bug is not user error.
> 
> We prefer to do that discovery process in the users mailing list.
> 
> -Bill
> SCons Project Co-Manager

Just for others following along, I did drop some quick research on the
missing .smod issue here:

https://github.com/SCons/scons/issues/3366

This was the note I added, it's pretty clear there is at least some
issue, but no clue which changes would resolve which problems.  For the
record Fortran was my first language.  Fortran II on a repurposed IBM
1620, on punchcards - the age of the machine is why it was an older
Fortran than the then-current version (Fortran II dates to 1958). I've
only grudgingly touched the language since, and consider myself almost
completely ignorant now. So I'm not really in any position to work on it.

===

I can see that the scons Fortran tool indeed has no knowledge of the
submodule files. Support for this aspect of the 2008 standard seems to
be quite recent - in the GNU Compiler Collection I see it requires 6.0
as a minimum version, as noted here:
https://gcc.gnu.org/wiki/Fortran2008Status

This ISO Technical Report provides details on the feature:
https://wg5-fortran.org/N1601-N1650/N1602.pdf

The Fortran tool looks like it would need work in both the emitter and
scanner. It may be as simple as just editing the regex, or not - note
that GNU Fortran at least has some exceptions:

    Submodules are supported. It should be noted that MODULEs do not
produce the smod file needed by the descendent SUBMODULEs unless they
contain at least one MODULE PROCEDURE interface. The reason for this is
that SUBMODULEs are useless without MODULE PROCEDUREs. See
http://j3-fortran.org/doc/meeting/207/15-209.txt for a discussion and a
draft interpretation. Adopting this interpretation has the advantage
that code that does not use submodules does not generate smod files.


More information about the Scons-users mailing list