I wish my first post would not be about an installation issue… but here I am! Yesterday, I upgraded my linux system from Fedora 37 to Fedora 38 and noticed I could not compile Stan models with cmdstanr anymore. I have tried to reinstall cmdstan multiple ways (through cmdstanr in R, or using make on github downloads of v2.31.0 and v2.32.0-rc1) but it keeps failing. According to cmdstanr::check_cmdstan_toolchain(), my C++ toolchain is setup properly. The problem seems to be related with “tbb”.
example of error message with cmdstanr::install_cmdstan():
../tbb_2020.3/include/tbb/task.h:300:20: error: declaration of ‘tbb::task& tbb::internal::task_prefix::task()’ changes meaning of ‘task’ [-Wchanges-meaning]
and the installation stops with:
make: *** [../tbb_2020.3/build/common_rules.inc:80: pipeline.o] Error 1 make: *** Waiting for unfinished jobs.... make: Leaving directory '/home/username/.cmdstan/cmdstan-2.31.0/stan/lib/stan_math/lib/tbb' make: *** [stan/lib/stan_math/make/libraries:169: stan/lib/stan_math/lib/tbb/tbb.def] Error 2 make: *** Waiting for unfinished jobs.... make: *** [make/command:5: bin/cmdstan/print.o] Error 1 make: *** [make/command:5: bin/cmdstan/stansummary.o] Error 1 make: *** [make/command:5: bin/cmdstan/diagnose.o] Error 1 make: *** [make/program:14: src/cmdstan/main.o] Error 1 make: *** [make/program:27: stan/src/stan/model/model_header.hpp.gch] Error 1
example of error message using make on v2.32.0-rc1:
stan/lib/stan_math/lib/tbb_2020.3/include/tbb/task.h:300:20: error: declaration of ‘tbb::task& tbb::internal::task_prefix::task()’ changes meaning of ‘task’ [-Wchanges-meaning]
Any hint of what could be wrong on my side?