Linking 'gfortran' command to compiler in gcc43
Rainer Müller
raimue at macports.org
Fri Apr 23 12:59:34 PDT 2010
On 2010-04-23 21:41 , Andrew Lambe wrote:
> When I first installed gcc43 through Macports, I noticed that the
> command gfortran was undefined, even though gfortran comes with the
> package (for some reason gcc did work as expected.) To compensate, I
> downloaded gfortran separately using a precompiled binary. I found
> out too late that gfortran was disguised as 'gfortran-mp-4.3' and now
> I would like to link the gfortran command to that executable. (Note
> that the gfortran binary is currently in /usr/local/bin and is called
> 'gfortran')
>
> 1) How can I link the command 'gfortran' to the Macports executable?
Install the gcc_select port, then run 'sudo gcc_select mp-gcc43' to
select the compiler provided by MacPorts gcc43. Note that this also
changes gcc, g++ and others.
> 2) Is there an easy way to check if e.g. the 'gcc' command is linked
> to the Macports executable and not something else like Xcode?
For example 'ls -l $(which gcc)' to see where the symlink points to.
Rainer
More information about the macports-users
mailing list