clocktower
Index A-Z
From the Chancellor
Visitors
Alumni
People Finder
For the Media
For Parents
Jobs
SalukiNet
SIUC Intranet
Athletics
Events Calendar
Weather
IT Home
Get Help
How Do I
FAQ
Get Network ID
Get UNIX ID
Get Mypage ID
Change Password
Services Index
Doc Index
line

Using the Fortran Compiler on the Fatman Server

Print friendly page

The current release of Sun Workshop Fortran (f77, f90) is Version 4.2.

To invoke the Fortran 77 compiler, type:

f77 [options | filename]...

Some of the commonly used options are:

Option: Result:
-o {outfile} Specifies the output of your compiled code.
-c Specifies that you want to compile but not link.
-g Generate debugging info for use with gdb.
-I{inc_dir} Specifies additional user-defined directory for include files.
-l{libs} Use the specified library or libraries when compiling.
-ansi Force full ANSI support.
-S Compile and only generate assembly code.
 

Example:

To compile the program "myprogram.f", you would type:

f77 myprogram.f

If there were no errors, an executable file named "a.out" would be generated.

 

Fortran 90 Programs:

Invoking the Fortran 90 compiler is very similar to Fortran 77, you type:

f90 [options | filename]...

 

Additional Information:

Further information about f77 and f90 is available via the online man pages. To access the pages, type on of the following commands:

man f77

man f90