dareus
OP
Created
Replies
19
Boosts
0
Views
18k
Participants
17
no commercial compiler
LLVM's Fortran front-end is not functional: cannot compile very simple code, array assignments, and basic libraries like LAPACK
GCC does not currently target arm-darwin
I have 100% confidence that Apple's level of support for Fortan will not change with the switch to Apple Silicon.Any update on this? All my native C applications compile for Apple Silicon. However, many scientists leverage my tools using R and their pipelines depend on Fortran for specific functions. Good support for R and Fortran is really important for many scientists.
make: gfortran: No such file or directory - this is solved by installing the experimental gfortran release
ld: warning: directory not found for option '-L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin18/8.2.0' - can not find anything related to this.
I am a computational physicist and neuroscientist and I need Intel Fortran to do my work. Without this, I have to switch to Linux.
After enabling flang in homebrew llvm you have on intel:
flang-new --version
Homebrew flang-new version 15.0.5
Target: x86_64-apple-darwin22.1.0
Thread model: posix
InstalledDir: /usr/local/Cellar/llvm/15.0.5/bin
Please test this on M1/M2
Flang-new works perfect on MacOS Sequoia. Faster than gfortran. Install it with Homebrew and add the following lines on .zprofile:
Support for flang-new compiler
export LIBRARY_PATH=/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib export LIBRARY_PATH="$LIBRARY_PATH:/Library/Developer/CommandLineTools/usr/lib/clang/16/lib/darwin" export LLVMTOOLS=/opt/homebrew/Cellar/flang/19.1.6/lib # directory with libfortran.a
Enjoy.