Reputation: 1697
I have two versions of boost:
The first one (from xcode i guess) has files in /usr/local/include/boost
and
/usr/local/lib/boost
The second one (from homebrew) has files in
/usr/local/Cellar/boost/1.54.0/include/boost
and
/usr/local/Cellar/boost/1.54.0/lib
As I want to use the second one, I call cmake to create my makefile and i compile my project this way:
cmake -DBOOST_ROOT=/usr/local/Cellar/boost/1.54.0/ .
make
And I get this error:
/usr/local/include/boost/functional/hash/extensions.hpp:54:17: error:
variable 'hash_value' declared as a template
std::size_t hash_value(std::list<T, A> const& v);
^
Clearly the boost version that is used is not the one I mentioned using BOOST_ROOT
. How do I make sure that the version of boost that is used is the one in /usr/local/Cellar/boost/1.54.0/
?
Thanks in advance
Upvotes: 0
Views: 147
Reputation: 6274
My guess is that you have another dependency that requires -I/usr/local/include/
in the flags, and that that -I
flags is seen by the compiler before -I/usr/local/Cellar/boost/1.54.0/include
.
Debug your compilation process with:
make VERBOSE=1
to see the compilation commands that are used.
Upvotes: 1