RubD / Giotto_site

Website for the Giotto spatial toolbox

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

gfortran warning solved on M1 macOS 11.6.2

wyq977 opened this issue · comments

Hi, I found out that the even with R 4.2.0 and apple silicon Macs, gfortran can still be installed manally following the instruction here. Updates on https://rubd.github.io/Giotto_site/articles/installation_issues.html#errors-on-macos might be needed. I can make a pull requests if needed on gfortran on you can simply refer users here

This is specific to Apple silicon Macs, an experimental build of GNU Fortran compiler is required otherwise errors like these would pop up during installation:

ld: warning: directory not found for option '-L/opt/R/arm64/gfortran/lib/gcc/aarch64-apple-darwin20.6.0/12.0.1'

This is due to no Fortran compiler and it can be solved with an experimental build given that the R is installed at /opt/R/arm64/ via Homebrew

# for R>=4.2.0
curl -O https://mac.r-project.org/tools/gfortran-12.0.1-20220312-is-darwin20-arm64.tar.xz

# unpack
sudo tar fxz gfortran-12.0.1-20220312-is-darwin20-arm64.tar.xz -C /

# /opt/R/arm64/gfortran/SDK has to point to your macOS SDK
sudo gfortran-update-sdk

Ref: https://support.bioconductor.org/p/9138121/

@RubD Hi?

Thanks for the suggestion @wyq977 . If you want you can make a pull request with an update for the installation_issues file using your suggestion.

@drieslab Hi, I added the guide on m1 and new apple silicon macs, on rmd only. I didn't build the html, you can review and build it.

Thx

Perfect, thanks!

I wasn't clear how to update the sdk:

sudo gfortran-update-sdk
sudo: gfortran-update-sdk: command not found

Could you post this on the Giotto issues channel? https://github.com/drieslab/Giotto/issues

This repo is for the old website and will be deleted in the future.

commented

I was confused about updating the sdk:

sudo gfortran-update-sdk
sudo: gfortran-update-sdk: command not found