Tag Archives: G95

Recognize platforms in Fortran

Sometimes it is useful for a Fortran 90 program to know on which platform it runs. The main reasons why I wrote the module PLATFORM are to know where the home directory is and where to store the configure files (e.g. namelist-files) on the currently used platform without maintaining different platform-dependent source files.

The module PLATFORM detects:

  • DOS-based Windows platforms, as 95/98(SE)/ME
  • NT-based Windows platforms, as NT/2000/XP/Vista/7
  • Unix(-like) platforms, as Linux, MacOS X, etc.

Continue reading Recognize platforms in Fortran

Compiler-depended subroutines of FLIB for G95 and Gfortran

The PNNL Fortran Library (a.k.a. FLIB) is a set of general purpose non-numeric Fortran 90 routines that can be used to simplify the development of programs with a batch-style input/output interface and text-processing. FLIB is platform independent.

In addition to the mainly non-numeric routines used to build program interfaces, the FLIB software does use four non-standard extensions to the Fortran 90 language standard. These non-standard routines decrease the portability of the software but significantly improve the functionality.

cal_gnu.f90 contains these non-standard routines which are adapted to the open source compiler G95 and Gfortran. Continue reading Compiler-depended subroutines of FLIB for G95 and Gfortran