Are configure files necessary when distributing R package that uses rstan?

Hello, I have a general question about developing an R package that uses rstan. I have read a lot of what has been written on this topic (e.g., here and here) and have played around with developing some toy R packages using rstantools. One problem I have run into was discussed in a previous post, and has to do with the ‘configure’ file created by rstantools::rstan_create_package() not being executable. The solution provided in that post is fine for developers (i.e., making the file executable manually), but seems likely to cause hassles for users installing the R package, since R will occasionally download package files into a temporary directory that lacks execution privileges during installation. While solutions to this problem have been posted elsewhere, these solutions might not be straightforward for all users.

My question is, does the configure file (and by extension) even need to be included in the distributed R package? My understanding it that it’s role is to recompile stan models whenever a developer makes changes to these models. Thus, could the configure file be added to .gitignore so that users installing the package from Github don’t have to deal with the potential of its non-executability? Deleting the configure file from my test package doesn’t hinder its installation and it passes devtools::check() without warnings or errors, but should I be concerned about subtle unintended consequences from removing the configure files?

Thank you in advance for any helpful insights, and I apologize for any of my R package/Stan ignorance.

1 Like