I’m trying to re-install Rstan after updating to 3.5.0. Even after installing all dependencies, I still get the following error message:
lang__ast_def.cpp:18:33: fatal error: stan/lang/ast_def.cpp: No such file or directory
Full output is displayed below:
> install.packages("rstan", dependencies = TRUE)
Installing package into ‘/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5’
(as ‘lib’ is unspecified)
also installing the dependency ‘shinystan’
trying URL 'https://cran.rstudio.com/src/contrib/shinystan_2.5.0.tar.gz'
Content type 'application/x-gzip' length 2400413 bytes (2.3 MB)
==================================================
downloaded 2.3 MB
trying URL 'https://cran.rstudio.com/src/contrib/rstan_2.17.3.tar.gz'
Content type 'application/x-gzip' length 747202 bytes (729 KB)
==================================================
downloaded 729 KB
* installing *source* package ‘rstan’ ...
** package ‘rstan’ successfully unpacked and MD5 sums checked
** libs
g++ -m64 -I"/usr/include/R" -DNDEBUG -I"../inst/include" -I"../inst/include/boost_not_in_BH" -I"`"/usr/lib64/R/bin/Rscript" --vanilla -e "cat(system.file('include', 'src', package = 'StanHeaders'))"`" -DBOOST_RESULT_OF_USE_TR1 -DBOOST_NO_DECLTYPE -DBOOST_DISABLE_ASSERTS -DFUSION_MAX_VECTOR_SIZE=12 -DBOOST_PHOENIX_NO_VARIADIC_EXPRESSION -I"/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/Rcpp/include" -I"/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/RcppEigen/include" -I"/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/BH/include" -I"/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/StanHeaders/include" -I/usr/local/include -fpic -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -c chains.cpp -o chains.o
g++ -m64 -I"/usr/include/R" -DNDEBUG -I"../inst/include" -I"../inst/include/boost_not_in_BH" -I"`"/usr/lib64/R/bin/Rscript" --vanilla -e "cat(system.file('include', 'src', package = 'StanHeaders'))"`" -DBOOST_RESULT_OF_USE_TR1 -DBOOST_NO_DECLTYPE -DBOOST_DISABLE_ASSERTS -DFUSION_MAX_VECTOR_SIZE=12 -DBOOST_PHOENIX_NO_VARIADIC_EXPRESSION -I"/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/Rcpp/include" -I"/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/RcppEigen/include" -I"/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/BH/include" -I"/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/StanHeaders/include" -I/usr/local/include -fpic -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -c init.cpp -o init.o
g++ -m64 -I"/usr/include/R" -DNDEBUG -I"../inst/include" -I"../inst/include/boost_not_in_BH" -I"`"/usr/lib64/R/bin/Rscript" --vanilla -e "cat(system.file('include', 'src', package = 'StanHeaders'))"`" -DBOOST_RESULT_OF_USE_TR1 -DBOOST_NO_DECLTYPE -DBOOST_DISABLE_ASSERTS -DFUSION_MAX_VECTOR_SIZE=12 -DBOOST_PHOENIX_NO_VARIADIC_EXPRESSION -I"/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/Rcpp/include" -I"/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/RcppEigen/include" -I"/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/BH/include" -I"/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/StanHeaders/include" -I/usr/local/include -fpic -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -c lang__ast_def.cpp -o lang__ast_def.o
lang__ast_def.cpp:18:33: fatal error: stan/lang/ast_def.cpp: No such file or directory
#include <stan/lang/ast_def.cpp>
^
compilation terminated.
make: *** [lang__ast_def.o] Error 1
ERROR: compilation failed for package ‘rstan’
* removing ‘/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/rstan’
Warning in install.packages :
installation of package ‘rstan’ had non-zero exit status
ERROR: dependency ‘rstan’ is not available for package ‘shinystan’
* removing ‘/mnt/ide0/home/dmalison/R/x86_64-redhat-linux-gnu-library/3.5/shinystan’
Warning in install.packages :
installation of package ‘shinystan’ had non-zero exit status
The downloaded source packages are in
‘/home/dmalison/bin/JMP/work/RtmpWita53/downloaded_packages’