Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Help with gfortran on mac

  1. Apr 18, 2013 #1
    I just downloaded gfortran on my mac and I'm having an issue running the program.
    For example, when I run the following using .f90,

    program test
    write (*,*) "Hello"
    end program test

    the computer, seemingly infinitely, spews out y's:
    y
    y
    y
    y
    y
    y
    y
    ..
     
  2. jcsd
  3. Apr 18, 2013 #2

    AlephZero

    User Avatar
    Science Advisor
    Homework Helper

    This is a guess, but it once caught me out on a Unix system, and the Mac OS is basically unix plus a lot of advertising hype :smile:

    There is a unix command called "test" (in fact several different commands all called "test", depending what shell you are running etc). So you might not be running your program at all!

    Try renaming it "mytest" or whatever.
     
  4. Apr 19, 2013 #3
    AlephZero's guess is a very solid one.

    Up to my experience every programmer working on *nix-style systems sooner or later runs into this, so
    "Welcome to the club, Nikolaus!" :smile:
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook




Similar Discussions: Help with gfortran on mac
  1. Cuda for gfortran ? (Replies: 4)

Loading...