J'ai essayé d'installer rstan, un package pour R pour l'échantillonnage MCMC, qui nécessite une compilation pour fonctionner. Malheureusement, le compilateur échoue lors de l'installation avec un très long message d'erreur dont je ne poste que les dernières étapes:
/home/XXX/R/x86_64-pc-linux-gnu-library/3.2/BH/include/boost/phoenix/core/detail/preprocessed/actor_operator_10.hpp:557:9: note: template<class A0, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> typename boost::phoenix::result_of::actor<typename boost::mpl::eval_if_c<boost::mpl::or_<boost::phoenix::is_custom_terminal<Expr>, mpl_::bool_<boost::is_placeholder<Expr>::value> >::value, boost::proto::terminal<T>, boost::mpl::identity<T> >::type::proto_base_expr, const A0&, const A1&, const A2&, const A3&, const A4&, const A5&, const A6&, const A7&, const A8&, const A9&>::type boost::phoenix::actor<Expr>::operator()(const A0&, const A1&, const A2&, const A3&, const A4&, const A5&, const A6&, const A7&, const A8&, const A9&) const [with A0 = A0; A1 = A1; A2 = A2; A3 = A3; A4 = A4; A5 = A5; A6 = A6; A7 = A7; A8 = A8; A9 = A9; Expr = boost::proto::exprns_::basic_expr<boost::proto::tagns_::tag::assign, boost::proto::argsns_::list2<boost::proto::exprns_::expr<boost::proto::tagns_::tag::terminal, boost::proto::argsns_::term<boost::spirit::attribute<0> >, 0l>, boost::phoenix::actor<boost::proto::exprns_::basic_expr<boost::phoenix::detail::tag::function_eval, boost::proto::argsns_::list4<boost::proto::exprns_::basic_expr<boost::proto::tagns_::tag::terminal, boost::proto::argsns_::term<stan::gm::subtraction_expr3>, 0l>, boost::phoenix::actor<boost::spirit::attribute<0> >, boost::phoenix::actor<boost::spirit::argument<0> >, boost::phoenix::actor<boost::proto::exprns_::basic_expr<boost::proto::tagns_::tag::terminal, boost::proto::argsns_::term<boost::reference_wrapper<std::basic_stringstream<char> > >, 0l> > >, 4l> > >, 2l>]
operator()(A0 const& a0 , A1 const& a1 , A2 const& a2 , A3 const& a3 , A4 const& a4 , A5 const& a5 , A6 const& a6 , A7 const& a7 , A8 const& a8 , A9 const& a9) const
^
/home/XXX/R/x86_64-pc-linux-gnu-library/3.2/BH/include/boost/phoenix/core/detail/preprocessed/actor_operator_10.hpp:557:9: note: template argument deduction/substitution failed:
In file included from /home/XXX/R/x86_64-pc-linux-gnu-library/3.2/BH/include/boost/spirit/home/qi/action/action.hpp:21:0,
from /home/XXX/R/x86_64-pc-linux-gnu-library/3.2/BH/include/boost/spirit/home/qi/action.hpp:14,
from /home/XXX/R/x86_64-pc-linux-gnu-library/3.2/BH/include/boost/spirit/home/qi.hpp:14,
from /home/XXX/R/x86_64-pc-linux-gnu-library/3.2/BH/include/boost/spirit/include/qi.hpp:16,
from ../inst/include/stansrc/stan/gm/grammars/expression07_grammar_def.hpp:16,
from ../inst/include/stansrc/stan/gm/grammars/expression07_grammar_inst.cpp:1,
from gm__grammars__expression07_grammar_inst.cpp:1:
/home/XXX/R/x86_64-pc-linux-gnu-library/3.2/BH/include/boost/spirit/home/support/action_dispatch.hpp:178:39: note: candidate expects 10 arguments, 3 provided
f(attr_wrap, context, pass);
make: *** [gm__grammars__expression07_grammar_inst.o] Error 1
ERROR: compilation failed for package ‘rstan’
plus tôt, ce message d'erreur est répété plusieurs fois, y compris une trace de pile légèrement plus longue.
Cette question semble similaire, mais les gars là-bas reçoivent des messages d'erreur différents, donc j'ai pensé que cela valait une nouvelle question
J'apprécierais toute aide, ce qui pourrait mal avec le compilateur ou ses paramètres
J'ai eu le même problème. Cela m'a corrigé:
devtools::install_url("http://cran.r-project.org/src/contrib/Archive/BH/BH_1.55.0-3.tar.gz")
devtools::install_url("https://github.com/stan-dev/rstan/releases/download/v2.6.0/rstan_2.6.0.tar.gz",dependencies = FALSE)
library(rstan)
set_cppo("fast")