cbergmeir / Rlgt

Rlgt is an R package for Bayesian Exponential Smoothing
20 stars 11 forks source link

Add compatibility for next version of rstan #4

Closed andrjohns closed 3 years ago

andrjohns commented 3 years ago

Hi,

This PR adds the changes to build flags that are needed for compatibility with the upcoming release of rstan. These changes include adding compiler & linker flags needed for working with StanHeaders >= 2.26, namely the addition of the TBB (RcppParallel).

Additionally, this PR adds a compiler flag to your Makevars files which is needed for compatibility with the upcoming version of rstan: -DUSE_STANC3

The Stan-to-c++ transpiler (stanc) was refactored after 2.21, and so different c++ is used in the new rstan package (>= 2.26). Because of this, the flag -DUSE_STANC3 needs to be added when a stan model is being run using the new rstan package (and the new stanc implementation).

Feel free to let me know if you need any more info.

Thanks! Andrew

cbergmeir commented 3 years ago

Great, thanks a lot for providing this, I've merged it.