ANTsX / ANTsR

R interface to the ANTs biomedical image processing library
https://antsx.github.io/ANTsR
Apache License 2.0
127 stars 35 forks source link

install fails for R 3.6.1 #278

Closed ptsii closed 4 years ago

ptsii commented 5 years ago

I updated R to 3.6.1. It then complained that it didn't know ANTsR anymore:

library(ANTsR) Error in library(ANTsR) : there is no package called ‘ANTsR’

I then tried reinstalling using:

library(devtools) install_github("stnava/cmaker") install_github("stnava/ANTsR") install_github("stnava/ANTsR")

On the last step I get:

clang: warning: no such sysroot directory: '/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk' [-Wmissing-sysroot] In file included from Atropos.cpp:1: In file included from /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/algorithm:642: In file included from /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/cstring:61: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/string.h:61:15: fatal error: 'string.h' file not found

include_next

          ^~~~~~~~~~

1 error generated. make: *** [Atropos.o] Error 1 ERROR: compilation failed for package ‘ANTsRCore’

Any suggestions about what I might try?

-Tom

ptsii commented 5 years ago

I get the same error if I do:

git clone https://github.com/ANTsX/ANTsRCore.git R CMD INSTALL ANTsRCore

ptsii commented 5 years ago

Looks like I needed to install the Command Line Tools for Xcode:

xcode-select --install

(then select the option to install them from a popup window) (https://apple.stackexchange.com/questions/337744/installing-xcode-command-line-tools/339015)

I then tried

R CMD INSTALL ANTsRCore

again, and it seems to be compiling...

adigherman commented 5 years ago

Do a ‘xcode-select install’ in the terminal and then try it again.