Running on Mac, installed to Catalina
R version 3.6.3
R stan version: 2.19.3
Error in compileCode(f, code, language = language, verbose = verbose) :
Compilation ERROR, function(s)/method(s) not created! In file included from <built-in>:1:
In file included from /Library/Frameworks/R.framework/Versions/3.6/Resources/library/StanHeaders/include/stan/math/prim/mat/fun/Eigen.hpp:13:
In file included from /Library/Frameworks/R.framework/Versions/3.6/Resources/library/RcppEigen/include/Eigen/Dense:1:
In file included from /Library/Frameworks/R.framework/Versions/3.6/Resources/library/RcppEigen/include/Eigen/Core:82:
In file included from /Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/new:85:
In file included from /Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/exception:82:
In file included from /Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/cstdlib:86:
In file included from /Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/stdlib.h:94:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h:66:
In file included from /Library/Developer
In addition: Warning message:
In system(cmd, intern = !verbose) :
running command '/Library/Frameworks/R.framework/Resources/bin/R CMD SHLIB file1247215182820.cpp 2> file1247215182820.cpp.err.txt' had status 1
Okay…I recently downloaded Command_Line_Tools_for_Xcode_11.4_beta_3, so as not to have the entire Xcode version. Would I just go back to that installer package and use control in the same way and then reinstall stan from source?
Stan should be available for R 3.6.3 right? This is the output I get for install.packages(c(“StanHeaders”, “stan”), type = “source”).
Warning in install.packages :
package ‘stan’ is not available (for R version 3.6.3)
trying URL 'https://cran.rstudio.com/src/contrib/StanHeaders_2.19.2.tar.gz'
Content type 'application/x-gzip' length 1278581 bytes (1.2 MB)
==================================================
downloaded 1.2 MB
* installing *source* package ‘StanHeaders’ ...
** package ‘StanHeaders’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
clang -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -DNO_FPRINTF_OUTPUT -I"../inst/include" -include stan_sundials_printf_override.hpp -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -I/usr/local/include -fPIC -Wall -g -O2 -c cvodes/cvodea.c -o cvodes/cvodea.o
In file included from cvodes/cvodea.c:29:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h:66:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/wait.h:110:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/resource.h:72:
/usr/local/include/stdint.h:7:10: fatal error: 'zzip/conf.h' file not found
#include <zzip/conf.h>
^~~~~~~~~~~~~
1 error generated.
make: *** [cvodes/cvodea.o] Error 1
ERROR: compilation failed for package ‘StanHeaders’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/StanHeaders’
* restoring previous ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/StanHeaders’
Warning in install.packages :
installation of package ‘StanHeaders’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/5v/66f0x8953rn0b13jmqw36qnm0000gn/T/RtmpfpUA37/downloaded_packages’```
Haha…thanks. Yeah, there are a ton of packages. I’ll probably wait for some others to weigh in. But if you’re already on Stan, you’re moving quick, so kudos to you.
When I run the
install.packages("StanHeaders", type = "mac.binary")
I receive the following error:
> install.packages("StanHeaders", type = "mac.binary")
Error in install.packages : Updating loaded packages
> install.packages("StanHeaders", type = "mac.binary")
Warning in install.packages :
unable to access index for repository https://cran.rstudio.com/bin/macosx/contrib/3.6:
cannot open URL 'https://cran.rstudio.com/bin/macosx/contrib/3.6/PACKAGES'
package ‘StanHeaders’ is available as a source package but not as a binary
Warning in install.packages :
package ‘StanHeaders’ is not available (as a binary package for R version 3.6.3)
Hmmm–so I didn’t have that file, but I created it the text file within the .R directory and added the code. Still not working, but there isn’t any “Error:”
The error I do get is
Error in compileCode(f, code, language = language, verbose = verbose) :
Compilation ERROR, function(s)/method(s) not created! /bin/sh: /usr/local/clang7/bin/clang++: No such file or directory
make: *** [file39641b876b73.o] Error 127
I’ll do a search for this on the internet as well.
I tried installing stan from source: however, I get this error:
/bin/sh: /usr/local/clang7/bin/clang++: No such file or directory
make: *** [chains.o] Error 127
ERROR: compilation failed for package ‘rstan’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/rstan’
Warning in install.packages :
installation of package ‘rstan’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/5v/66f0x8953rn0b13jmqw36qnm0000gn/T/RtmpFtKGAw/downloaded_packages’
Should I alter the code within the Makevars folder?