Closed gliomas closed 4 years ago
This is not something I am familiar with because I am not a Mac user. But from what I see online, RcppArmadillow just changed the minimum requirements to C++11, see here. You are also using R version 4, which is not brand new but I am not sure if it has something to do with it.
The first thing to try is the instructions on how to set up RcppArmadillo here. These probably refer to the same issue you are encountering, and is also mentioned in the issues RcppArmadillo itself.
Then, I see three other potential solutions:
src/Makevars
to add the std flag you mention, as shown here. Then do the manual local installation with R CMD INSTALL LESYMAP
from the parent folder.Hopefully the very first instructions will have the help you need. Let me know if you manage to fix it, and how.
YES!!!!!! I went with 1. Downloaded the master from GitHub and edited MakeVars. Then used devtool install_local in R and pointed to the local directory. Ran into one more issue later in the compilation where I was missing gfortran but that was an easy fix. Thanks a ton
I keep getting the error below when I try to compile LESYMAP from GitHub. I've tried all three methods to no avail. Compliation of ANTsR, ANTsRCore and ITKR work fine.
`In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include/armadillo:21: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include/armadillo_bits/compiler_check.hpp:50:4: error: "*** C++11 compiler required; enable C++11 mode in your compiler, or use an earlier version of Armadillo"
error "*** C++11 compiler required; enable C++11 mode in your compiler, or use an earlier version of Armadillo"`
I believe the issue is that this command
clang++ -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include' -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include' -I/usr/local/include -fPIC -Wall -g -O2 -c BMfast.cpp -o BMfast.o
needs to start with
clang ++ -std=c++11
but I don't know how to do that Any help would be very appreciated! Thank you