gfortran for M1?

Marius Schamschula lists at schamschula.com
Sat Mar 20 14:23:59 UTC 2021


Petr,

sudo port select gcc mp-gcc-devel

will add links so that the binaries, includes and libraries can be found.

> On Mar 20, 2021, at 8:59 AM, <petr.2006 at centrum.cz> <petr.2006 at centrum.cz> wrote:
> 
> Thank you Chris,
> 
> I found gfortran-mp-devel in /opt/local/bin.
> 
> However trying to compile my source a got linker error:
> ld: library not found for -lm
> 
> And I am lost again. I did not specified any linker options,
> just compiler options:
> -g -fbounds-check -ffpe-trap=invalid,zero,overflow -ffpe-summary=invalid,zero,overflow -fno-sign-zero -fno-automatic -Wuninitialized
> 
> (Sorry for beginner question. Google did not help.)
> 
> Petr
> 
> ______________________________________________________________
>> Od: "Chris Jones" <jonesc at hep.phy.cam.ac.uk>
>> Komu: petr.2006 at centrum.cz
>> Datum: 20.03.2021 14:04
>> Předmět: Re: gfortran for M1?
>> 
>> CC: <macports-users at lists.macports.org>
>> Hi,
>> 
>> Gcc-devel provides gfortran for M1 machines by default.
>> 
>> Chris
>> 
>>> On 20 Mar 2021, at 1:01 pm, petr.2006 at centrum.cz wrote:
>>> 
>>> Is it already possible to install gfortran on M1?
>>> It seems that gcc-devel does not have +gfortran variant and and other gcc versions are not compatible. 
>>> Thank you, 
>>> Petr
>> 
>> 
>> 

Marius
--
Marius Schamschula



More information about the macports-users mailing list