Android NDK clang compiler cannot find std :: make_unique

I am using Android NDK r10d. My application.mk is configured like this:

APP_CFLAGS := -DANDROID -DBUILD_OGLES2
APP_CPPFLAGS := $(APP_CFLAGS) -fexceptions -frtti -std=c++14
APP_STL := gnustl_static
APP_ABI := armeabi-v7a
APP_PLATFORM := android-15
NDK_TOOLCHAIN_VERSION := clang

I use std::make_uniquein my code and it does not compile (says it was not found). This feature should be available in STL starting with C ++ 14. I thought a little and it seems that clang does not use GNU STL 4.9 in the NDK. If that were the case, it would be available since I can see it inside the header <memory>.

What am I missing here? Is there any way to use 4.9 GNU STL with clang?

+4
source share
1 answer

make_unique gnustl clang. LLVM lib++. Application.mk:

APP_STL := c++_static
NDK_TOOLCHAIN_VERSION := clang

: GNU STL 4.9 ( TOOLCHAIN_VERSION android-ndk-r10d/toolchains/*toolchain_name*-clang3.5/setup.mk) :

clang++: /s/ndk-toolchain/src/llvm-3.5/llvm/tools/clang/lib/AST/DeclBase.cpp:1293: clang::DeclContext::lookup_result clang::DeclContext::lookup(clang::DeclarationName): Assertion 'DeclKind != Decl::LinkageSpec && "Should not perform lookups into linkage specs!"' failed.

+1

All Articles