I have been trying to use C++11. I am developing an android project and i want to use std::mutex. Along with OpenCV
But no matter what I do, I just cant seem to fix the Type 'mutex' could not be resolved
error.
I have tried following the tutorials i found on SO and other places. LINK1 LINK2 LINK3LINK4
- ADT v22.3.0-887826
- Installed C/C++ compilers (CDT)
Following so many tutorials, it has become a real mess now. So I will explain my current settings
- Project > Properties > C/C++ Build > Tool Chain Editor
- Current Tool Chain is "Cross GCC"
- Current Builder is "Android Builder"
Project > Properties > C/C++ Build > Discovery Options
- Compiler invocation command is "gcc"
- Compilter Invocation argments are -E -P -v -dD "${plugin_state_location}/specs.c -std=c++11"
Project > C/C++ General > Paths and Symbols > # Symbols tab
- Symbol = __cplusplus and Value = 1
In my Application.mk file I have the following
APP_STL := gnustl_static
APP_USE_CPP0X := true
APP_CPPFLAGS := -std=c++11 -frtti -fexceptions
APP_ABI := armeabi-v7a
APP_PLATFORM := android-8
I tried to change the cplusplus symbol's value to 201103L and tried __GXX_EXPERIMENTAL_CXX0X with an empty value
But nothing seems to work, What am I doing wrong??
Any help is appreciated!