Errors: No matching function and -Wno-ignored-attributes

Hi everyone!
I am running the Bernoulli example on cmdstan. Inside the compiling, linking C++ code phase I have the following error:

examples/bernoulli/bernoulli.hpp:160:0: error: no matching function for call to ‘stan::io::reader::reader(Eigen::Matrix<double, -1, 1>&, Eigen::Matrix<int, -1, 1>&)’
local_scalar_t__ DUMMY_VAR__(std::numeric_limits::quiet_NaN());

I tried to run other examples and all of them have similar problems.
I think it may be a problem due to the misplacement of some folder/function.

Furthermore, at the end I also have the following warning, which appears every time as well:

cc1plus: warning: unrecognized command line option ‘-Wno-ignored-attributes’

I deleted all the packages and installed from the beginning cmdstan but it is not working.
Does someone know with what this can be related? It was working until 3 weeks ago and I did not change anything.
Did someone face this problem before?

Hi,

can you elaborate what version of Cmdstan you are using. Are you using a clone from Github or the latest release?

Hi, I am sorry I did not mention it before.
I am using the version 2.24 on Ubuntu 14.04.6 LTS.
It is a bit different from the standard one. It comes from this repository:

Thanks, that repo hasnt changed since august so the changes in the code are not to blame here.

Can you post the output of

g++ --version

The output is the following:

g++ (Ubuntu 5.3.1-14ubuntu2) 5.3.1 20160413

When I first cloned, the version was just updated to 4.9.
Could the things be related? Many thanks

G++ should be at least 4.9.3. Maybe try cleaning and building it again.

Thank you for the advice.
I have just done it, but unfortunately nothing has changed.