Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm a newbie in the Unix world so all this is a little confusing to me. I'm having trouble compiling some Fortran files under Cygwin on Windows XP.

Here's what I've done so far:

  1. Installed the e text editor.
  2. Installed Cygwin via the "automatic" option inside e text editor.
  3. I need to compile some Fortran files so via the "manage bundles" option I installed the Fortran bundle as well.

However, when I select "compile single file" I get an error saying gfortran was missing, and then that I need to set the TM_FORTRAN variable to the full path of my compiler.

I tried opening a Cygwin bash shell at the path mentioned (.../bin/gfortran), but the compiler was nowhere to be found.

Can someone tell me how to install this from the Cygwin command line? Where do I need to update the TM_FORTRAN variable for the bundle to work?

Also, how do I change the bundle "compile" option to work with ifort (my native compiler) on Windows? I've read the bundle file, but it is totally incomprehensible to me. Ifort is a Windows compiler, invoked simply by ifort filename.f90, since it is on the Windows path.

I know this is a lot to ask of a first time user here, but I really would appreciate any time you can spare to help.

share|improve this question

migrated from stackoverflow.com Jan 15 '12 at 3:46

This question came from our site for professional and enthusiast programmers.

    
The Fortran Compiler is in the package gcc-g77 in the Cygwin installer (/bin/g77) – Amro Nov 3 '09 at 5:33
    
haven't tried but echo $TM_FORTRAN and TM_FORTRAN=WHATEVERITSHOULDBE – barlop May 1 '15 at 19:53

Rerun the cygwin installer, and choose a Fortran compiler: gcc-g77 for the older Fortran 77, gcc4-gfortran for newer standards (Fortran 95 and parts of Fortran 2003 & 2008).

share|improve this answer

You must log in to answer this question.