Unable to install Gfortran through homemade software

When I tried to install gfortran, I received this message.

~$brew install gfortran
Error: No available formula for gfortran
GNU Fortran is now provided as part of GCC, and can be installed with:
brew install gcc

My question is how to use homemade software or Port to install gfortran?

Either

If GNU Fortran is now part of GCC, how do I use gcc to compile fortran code?

I’m not sure if I misunderstood something I remember last time I could still use gfortran to compile my code but now it doesn’t work.

More information:

When I use the command brew list, I still see that gfortran is there but I cannot use it.

More information (latest):

Ok, now I You can use the gfortran command, but another problem is coming

~$gfortran-4.9 hello.f
dyld: Library not loaded: /usr/local/lib/ libcloog-isl.4.dylib
Referenced from: /usr/local/Cellar/gcc/4.9.2/libexec/gcc/x86_64-apple-darwin14.0.0/4.9.2/f951
Reason: image not found
gfortran-4.9: internal compiler error: Trace/BPT trap: 5 (program f951)
Abort trap: 6

Follow the instructions to do “brew install gcc”. The gcc package contains gcc, g, gfortran, etc..

When I try to install gfortran , I received this message.

~$brew install gfortran
Error: No available formula for gfortran
GNU Fortran is now provided as part of GCC, and can be installed with:
brew install gcc

My question is how to install gfortran with homebrew or port?

Either

If GNU Fortran is now part of GCC, how do I use gcc to compile fortran code?

I’m not sure if I misunderstood something I remember last time I could still use gfortran to compile my code but now it doesn’t work.

More information:

When I use the command brew list, I still see that gfortran is there but I cannot use it.

More information (latest):

Ok, now I You can use the gfortran command, but another problem is coming

~$gfortran-4.9 hello.f
dyld: Library not loaded: /usr/local/lib/ libcloog-isl.4.dylib
Referenced from: /usr/local/Cellar/gcc/4.9.2/libexec/gcc/x86_64-apple-darwin14.0.0/4.9.2/f951
Reason: image not found
gfortran-4.9: internal compiler error: Trace/BPT trap: 5 (program f951)
Abort trap: 6

Follow the instructions to do “brew install gcc”. The gcc package contains gcc, g, gfortran, etc.

Leave a Comment

Your email address will not be published.