------- Comment #1 from burnus at gcc dot gnu dot org 2009-06-29 12:41 ------- > The automatism works fine for .f90 files, so I suppose it is supposed to > work for .f95, too? > > I guess a fix is simple (making that file suffix known). I am rather wondering > why our install of (as far as possible) vanilla upstream gcc does not contain > that configuration, is this something a distribution is supposed to hack in?
In vanilla GCC 4.3 there is at: gcc/fortran/lang-specs.h: {".F90", "@f95-cpp-input", 0, 0, 0}, {".F95", "@f95-cpp-input", 0, 0, 0}, {".F03", "@f95-cpp-input", 0, 0, 0}, {"@f95-cpp-input", "cc1 -E -lang-fortran -traditional-cpp -D_LANGUAGE_FORTRAN %(cpp_options) \ %{E|M|MM:%(cpp_debug_options)}\ %{!M:%{!MM:%{!E: -o %|.f95 |\n\ f951 %|.f95 %{!ffixed-form:-ffree-form} %(cc1_options) %{J*} %{I*}\ -fpreprocessed %{!nostdinc:-fintrinsic-modules-path finclude%s} %{!fsyntax-only:%(invoke_as)}}}}", 0, 0, 0}, {".f90", "@f95", 0, 0, 0}, {".f95", "@f95", 0, 0, 0}, {".f03", "@f95", 0, 0, 0}, {"@f95", "%{!E:f951 %i %(cc1_options) %{J*} %{I*}\ %{!nostdinc:-fintrinsic-modules-path finclude%s} %{!fsyntax-only:%(invoke_as)}}", 0, 0, 0}, Thus .f90 and .f95 but also .F90 and .F95 are handled on equal footing. There is no (obvious) reason why it works with .f90 but not with .f95. Seemingly, there are some parsing problems with that file since the error output looks like an excerpt from that file. It is extremely unlikely that such a change would go unnoticed. The GCC test suite contains .f90, .f03 and .f08 and .F90 files. (Admittedly, no .f95/.F95 file.) The testsuite is run on a large range of systems and before the committal of any patch. I would recommend to contact your Linux vendor about this problem. * * * You could try one of the files at http://users.physik.fu-berlin.de/~tburnus/gcc-trunk/ (Maybe avoid the (trunk) builds of last one or two weeks - at least if you have a GLIBC < 2.7 as seemingly those builds now require such a "new" glibc.) * * * Note: .f90 essentially means free format, there is no real reason to use .f95, .f03, .f08. (Well, there is one legitimate case: To have a different -std= option for, e.g., .f95 than for .f90, but that's really a special case.) -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40584