I’m trying to include eigen in an xcode project. So far i installed eigen:
brew install eigen
and set the header paths in the project file like so:
/usr/local/Cellar/eigen/3.2.1
now the library is found and starting to compile.
But I get many errors:
/usr/local/Cellar/eigen/3.2.1/include/eigen3/Eigen/src/Core/Block.h:50:15: Use of undeclared identifier 'Block'; did you mean 'clock'?
/usr/local/Cellar/eigen/3.2.1/include/eigen3/Eigen/src/Core/Block.h:50:21: 'XprType' does not refer to a value
/usr/local/Cellar/eigen/3.2.1/include/eigen3/Eigen/src/Core/Block.h:50:8: Explicit specialization of non-template struct 'traits'
/usr/local/Cellar/eigen/3.2.1/include/eigen3/Eigen/src/Core/Block.h:50:64: Expected unqualified-id
To me this seems to be a dialect problem.
Any ideas what I can try to fix it?
Ok in fact it seems that the code it is in c++11.
when i change the flag C++Standard Library from:
libstdc++ (GNU C++ standard library)
to:
libc++ (LLVM c++ standard libarary with C++11 support)
then the errors disappear and the famous “tr1/mememory” error appears.
Is there any way of running c++11 code in our current OF? can i compile it sepparatelly using c++11 and link it as an object? will that work?
Not currently on OSX that I know of, but it’s coming soon … we’re recompiling all libs to support libc++ for 64bit. 0.9.0 will have it, according to plan.
I believe you should be able to use C++11 features on linux already though using master branch.