-
-
Notifications
You must be signed in to change notification settings - Fork 134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Compilation of 'rstanarm' survival extension failed #614
Comments
It also fails when trying to install in R 4.3.2 on Mac OS 12.7.3. Both RStan and rstanarm installed successfully, so I know the c++ toolchain works. The errors I get along the lines of this (they go on and on and on and on....)
using C++ compiler: ‘Apple clang version 14.0.0 (clang-1400.0.29.202)’ Wrote C++ file "stan_files/bernoulli.cc" clang++ -arch arm64 -std=gnu++17 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I"../inst/include" -I"/Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/library/StanHeaders/include/src" -DBOOST_DISABLE_ASSERTS -DEIGEN_NO_DEBUG -DBOOST_MATH_OVERFLOW_ERROR_POLICY=errno_on_error -DUSE_STANC3 -D_HAS_AUTO_PTR_ETC=0 -I'/Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/library/StanHeaders/include' -I'/Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/library/rstan/include' -I'/Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/library/BH/include' -I'/Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/library/Rcpp/include' -I'/Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/library/RcppEigen/include' -I'/Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/library/RcppParallel/include' -I/opt/R/arm64/include -I'/Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/library/RcppParallel/include' -D_REENTRANT -DSTAN_THREADS -fPIC -falign-functions=64 -Wall -g -O2 -c stan_files/bernoulli.cc -o stan_files/bernoulli.o In file included from stan_files/bernoulli.cc:3: define _LIBCPP_DEPRECATED_IN_CXX17 _LIBCPP_DEPRECATED
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__config:1043:48: note: expanded from macro '_LIBCPP_DEPRECATED' define _LIBCPP_DEPRECATED attribute ((deprecated))
In file included from stan_files/bernoulli.cc:3: define _LIBCPP_DEPRECATED_IN_CXX17 _LIBCPP_DEPRECATED
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__config:1043:48: note: expanded from macro '_LIBCPP_DEPRECATED' define _LIBCPP_DEPRECATED attribute ((deprecated))
In file included from stan_files/bernoulli.cc:3: define _LIBCPP_DEPRECATED_IN_CXX17 _LIBCPP_DEPRECATED
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__config:1043:48: note: expanded from macro '_LIBCPP_DEPRECATED' define _LIBCPP_DEPRECATED attribute ((deprecated))
In file included from stan_files/bernoulli.cc:3: define _LIBCPP_DEPRECATED_IN_CXX17 _LIBCPP_DEPRECATED
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__config:1043:48: note: expanded from macro '_LIBCPP_DEPRECATED' define _LIBCPP_DEPRECATED attribute ((deprecated))
In file included from stan_files/bernoulli.cc:3: define _LIBCPP_DEPRECATED_IN_CXX17 _LIBCPP_DEPRECATED
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__config:1043:48: note: expanded from macro '_LIBCPP_DEPRECATED' define _LIBCPP_DEPRECATED attribute ((deprecated))
In file included from stan_files/bernoulli.cc:3: define _LIBCPP_DEPRECATED_IN_CXX17 _LIBCPP_DEPRECATED
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__config:1043:48: note: expanded from macro '_LIBCPP_DEPRECATED' define _LIBCPP_DEPRECATED attribute ((deprecated))
In file included from stan_files/bernoulli.cc:3: define _LIBCPP_DEPRECATED_IN_CXX17 _LIBCPP_DEPRECATED
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__config:1043:48: note: expanded from macro '_LIBCPP_DEPRECATED' define _LIBCPP_DEPRECATED attribute ((deprecated))
In file included from stan_files/bernoulli.cc:3: define _LIBCPP_DEPRECATED_IN_CXX17 _LIBCPP_DEPRECATED
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__config:1043:48: note: expanded from macro '_LIBCPP_DEPRECATED' define _LIBCPP_DEPRECATED attribute ((deprecated))
In file included from stan_files/bernoulli.cc:3: define _LIBCPP_DEPRECATED_IN_CXX17 _LIBCPP_DEPRECATED
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__config:1043:48: note: expanded from macro '_LIBCPP_DEPRECATED' define _LIBCPP_DEPRECATED attribute ((deprecated))
In file included from stan_files/bernoulli.cc:3: define _LIBCPP_DEPRECATED_IN_CXX17 _LIBCPP_DEPRECATED
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__config:1043:48: note: expanded from macro '_LIBCPP_DEPRECATED' define _LIBCPP_DEPRECATED attribute ((deprecated))
|
For what it's worth, downloading the zip file from the '<> Code` dropdown and the using devtools::install_local( |
Many thanks Andrew, just to note it still did not install for me. The error I am getting is now: **Error: package or namespace load failed for 'rstanarm' in .doLoadActions(where, attach):
Reminder that my code is: install.packages("rstanarm", repos = c("https://mc-stan.org/r-packages/", getOption("repos"))) and I am trying to install the survival extension of the rstanarm packages into my R version 4.2 on a Windows 10 computer. |
Thank you so much! This worked for me too! |
Hello, I also downloaded the zip file to downloads and used the code devtools::install_local("~/Downloads/rstanarm-feature-survival.zip"), it gives me following error message Error : Could not copy `C:\Users\hazel2544\Documents\Downloads\rstanarm-feature-survival.zip` to `C:\Users\hazel2544\AppData\Local\Temp\1\RtmpKqr3LA\fileaa018702cd3`
In addition: Warning message:
In normalizePath(path.expand(path), winslash, mustWork) :
path[1]="Downloads/rstanarm-feature-survival.zip": The system cannot find the path specified Could anyone please help? Thanks very much in advanced. |
Hi @Hazel2544, |
Using the code:
install.packages("rstanarm", repos = c("https://mc-stan.org/r-packages/", getOption("repos")))
devtools::install_github("stan-dev/rstanarm", ref = "feature/survival", build_vignettes = FALSE)
I am trying to install the survival extension of the rstanarm packages into my R version 4.2 on a Windows 10 computer.
It runs until:
C:/Users/wilhch00/AppData/Local/R/win-library/4.2/RcppEigen/include/Eigen/src/Core/DenseCoeffsBase.h:55:30: warning: ignoring attributes on template argument 'Eigen::internal::packet_traits::type' {aka '__m128d'} [-Wignored-attributes]
"C:/PROGRA
1/R/R-421.3/bin/x64/Rscript" -e "source(file.path('..', 'tools', 'make_cc.R')); make_cc(commandArgs(TRUE))" stan_files/surv.stanand then the error states that:
Error in rstan::stanc(file, allow_undefined = TRUE, obfuscate_model_name = FALSE) :
0
Semantic error in 'string', line 404, column 2 to line 411, column 3:
402: }
403:
404: vector quadrature_log_cdf(vector qwts, vector log_hazard, int qnodes, int N) {
^
405: int M = rows(log_hazard);
406: vector[M] hazard = exp(log_hazard);
Real return type required for probability functions ending in _log, _lpdf, _lupdf, _lpmf, _lupmf, _cdf, _lcdf, or _lccdf.
Calls: make_cc ->
Execution halted
make: *** [Makevars.win:28: stan_files/surv.cc] Error 1
rm stan_files/polr.cc stan_files/mvmer.cc stan_files/count.cc stan_files/lm.cc stan_files/jm.cc stan_files/bernoulli.cc stan_files/binomial.cc stan_files/continuous.cc
ERROR: compilation failed for package 'rstanarm'
Warning messages:
1: In utils::untar(tarfile, ...) :
‘tar.exe -xf "C:\Users\wilhch00\AppData\Local\Temp\RtmpcphJws\file12c849956fc.tar.gz" -C "C:/Users/wilhch00/AppData/Local/Temp/RtmpcphJws/remotes12c83388f58"’ returned error code 1
2: In i.p(...) :
installation of package ‘C:/Users/wilhch00/AppData/Local/Temp/RtmpcphJws/file12c83b9a3c1e/rstanarm_2.26.1.tar.gz’ had non-zero exit status
I have tried to also download the survival extension and building the package from R studio as well.
But the same issue reoccurs.
Any help would be greatly appreciated.
Charlotte
The text was updated successfully, but these errors were encountered: