Compiling g77 program with gfortran

The good old g77 Fortran compiler is no longer being maintained. In Windows, that is no big deal for your g77 programs, since Windows puts great effort in being backwards compatible. Just continue using the g77 compiler you have.

However, for Linux things are different. Linux considers backward compatible to be the filthiest term that exists. The reason is the underlying design philosophy of Linux: "If it works, change it." "Backwards compatible" is the diametric opposite of that philosophy.

You remember all those errors you constantly had where you forgot to double your backslashes in strings for g77? No other Fortran compiler did that, because a backslash is not special in Fortran. So you had to go into all programs that originated from other compilers and double backslashes. Well, guess what? Now you can change them all back. (Added note: Or use the -fbackslash option.)

The gfortran documentation says that intrinsic functions iargc and getarg have been maintained for backward compatibility reasons. Well, maybe, but the compiler does not know where they are. If you have that problem, adding the following two files to your gfortran line should fix it: iargc.f and getarg.f. (Added note: This may be a problem in how you pass the string and/or what their length is declared to be. However that may be, the fix works.)

The gfortran documentation says that intrinsic functions fget has been maintained for backward compatibility reasons. Well, maybe, but the compiler does not know where it is. The documentation says that you should use the new stream I/O instead, but trying to open stdin or unit 5 with access='stream' is refused. I found that the following file works: fget.f.