[R-SIG-Mac] gfortran for lion

Simon Urbanek simon.urbanek at r-project.org
Sat Aug 6 16:46:56 CEST 2011


On Aug 6, 2011, at 10:33 AM, Jaffe, Andrew H wrote:

> Dear Simon,
> 
> On 6 Aug 2011, at 15:17, Simon Urbanek wrote:
> 
>> On Aug 3, 2011, at 7:19 AM, Jaffe, Andrew H wrote:
>> 
>>> I was attempting to install the latest gfortran for OS X 10.7 Lion. 
>>> 
>>> I note that there is an Xcode add-on version for Lion. Its readme screen does indeed claim that this "GNU Fortran 4.2.4 for Xcode 4.1".
>>> 
>>> However:
>>> 
>>> * the "file list" in the package says "GNU Fortran 4.2.4 for Xcode 3.2.3" 
>>> * the files themselves are labelled ./usr/bin/i686-apple-darwin11-gfortran-4.2.1.
>>> * gfortran --version gives "GNU Fortran (GCC) 4.2.1 (Apple Inc. build 5666) (dot 3)"
>>> 
>>> So, which is it? (And can/should I use the old 2008 CRAN version instead?)
>>> 
>> 
>> I have no idea what you mean by "file list", but everything else is exactly as it should be. It's GNU Fortran 4.2.4 compiled in Apple's gcc 4.2.1 (build 5666.3) branch - which is what Xcode 4.1 is (see gcc-4.2 --version).
> 
> Thanks for the clarification. 
> 
> By "file list" I meant what you get from the menu item "Show Files" in the installer. 
> 

I'm not on Lion right now so I'll check later, but I don't think I'll be re-packaging it for that ;).


> But I admit that it's all still a bit confusing. Nowhere does it say "4.2.4", just "4.2.1" which I think I now understand is the gcc version used to compile it, not the gfortran version. Should "--version" give the version of the program you're using?
> 

It does - your'e using Apple's gcc 4.2.1 with Fortran front-end from gcc 4.2.4 (i.e. the back-end is still gcc-4.2.1). Obviously, it's something that the authors didn't anticipate so there is no provision for labeling that mix ;) - the build simply shows the branch version which is gcc-4.2.1 5666.3. Given that Apple has no Fortran in their branch, there is really no "corresponding" Fortran.

Cheers,
Simon


>> You can use either (as the post said). The differences from the CRAN Fortran are the same as for any of the Leopard and Snow Leopard Xcode add-ons, nothing changed since.
>> 
>> Cheers,
>> Simon
> 
> Yours,
> 
> Andrew
> 
> 



More information about the R-SIG-Mac mailing list