Alex Rivera | Logout

How to compile Fortran 77 files in linux?

Asked 2009-07-24T05:48:23.403
13

I need a compiler for Fortran 77 in linux.

Are there any free compilers out there that people use?

I've heard about g77, but I can't find the rpm or how to install it in linux.

Edit
Report

2 Answers

1

There's http://www.g95.org/ that's available.

If I remember well GNU doesn't have a FORTRAN compiler but a FORTRAN preprocessor (or whatever the name for that is). It just translates your code to C and the compiles it with the C compiler. Of course performance becomes crap in the process.

However if you're using FORTRAN I assume it's a kind of computation project. If it's for free (not academic and not course related) you can get Intel FORTRAN compiler for free. In my experience it goes about 3-4 times faster than any free implementation.

answered 2009-07-24T06:11:58.303
1

I did the following steps and worked!

  1. Edit your /etc/apt/sources.list

  2. add this text in that file (/etc/apt/sources.list):

    deb http://hu.archive.ubuntu.com/ubuntu/ hardy universe
    deb-src http://hu.archive.ubuntu.com/ubuntu/ hardy universe
    deb http://hu.archive.ubuntu.com/ubuntu/ hardy-updates universe
    deb-src http://hu.archive.ubuntu.com/ubuntu/ hardy-updates universe
    
  3. Save file

  4. Open terminal, type : sudo apt-get install fort77

answered 2013-04-16T15:51:45.827

Your Answer