jeudi 2 février 2017

Set CMake generated Eclipse project to recognize C++11 features like std::to_string()

Using Eclipse 3.8.1, I've generated a C++ project using CMake with two subprojects.

Both subprojects specify

# Use C++11 to compile your pass (i.e., supply -std=c++11).
target_compile_features(OpaquePass PRIVATE cxx_range_for cxx_auto_type)

in their CMakeLists.txt.

Now, this doesn't seem to work, since Eclipse cannot recognize methods like std::to_string().

I've tried to configure Eclipse myself, but right-clicking on project properties, I get these options:

enter image description here

It doesn't seem that I can specify any flags to GCC or customize behavior. What can I do to make Eclipse function properly with C++11?

Aucun commentaire:

Enregistrer un commentaire