This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: HELP with GFORTRAN, XCODE and TERMINAL_MAc
- From: FX <fxcoudert at gmail dot com>
- To: f dot lilla at libero dot it
- Cc: Fortran List <fortran at gcc dot gnu dot org>
- Date: Thu, 31 Jul 2014 19:45:08 +0200
- Subject: Re: HELP with GFORTRAN, XCODE and TERMINAL_MAc
- Authentication-results: sourceware.org; auth=none
Hi Francesca,
> I downloaded gfortran, i.e.gfortran-4.9.0-Mavericks.dmg, and I run sudo rm -r
> /usr/local/gfortran /usr/local/bin/gfortran on Terminal and it gives me this
> message: rm: /usr/local/gfortran: No such file or directory, is it true? How
> can I check if the gfortran is installed on my mac??
Take a deep breath! You’ll get through this.
1. Do you have command-line tools installed already? If you type “gcc” in a terminal, what does it say?
2. Have you installed successfully installed the package inside gfortran-4.9.0-Mavericks.dmg? It should install like any other software, with Apple installer interface.
3. Once you have done that, type “gfortran” in your terminal: what does it say?
4. If step #3 fails, can you open the Console, and see if there is anything in there related to why your gfortran installer failed to set things up properly?
PS: the “sudo rm -rf …” line is to *remove* gfortran, not to install it.
> Suppose that I have a file called example.f90 (written in text, i.e. txt) how
> do I run on my terminal??I tried to put this file on the directory, after
> cd/Users/myname/Desktop but the message is always: no such file or directory??
> Can someone help me telling all the necessary steps?
You need to read a short intro to the Terminal. It’s not so hard, but you need to learn the basics if you’ve never done it.
You can, for example, see here: http://blog.teamtreehouse.com/introduction-to-the-mac-os-x-command-line
> The last question: What are the steps to follow in order to write in Xcode the
> right file, call it with f.90/f.95 extension and run it on terminal???
I have never tried Xcode/gfortran integration, but some others have. With the right settings, you can get Xcode to run pretty much any command in its build procedure.
Cheers,
FX