smart pointers not working with Android NDK r8

前端 未结 2 1506
情话喂你
情话喂你 2020-12-15 08:31

I can\'t figure out how to use shared pointers within my Android project. I\'m using the latest Eclipse ADT on Mac OS X with the Android NDK r8d.

Here is what is in

2条回答
  •  太阳男子
    2020-12-15 09:30

    these settings did it for me:

    Application.mk:

    NDK_TOOLCHAIN_VERSION=4.7
    APP_STL := gnustl_static
    

    Android.mk:

    LOCAL_CFLAGS :=-D__GXX_EXPERIMENTAL_CXX0X__  <--important
    LOCAL_CPPFLAGS  := -std=c++11
    

    Eclipse Settings: C/C++ General\Path and Symbols should contain:

    C:\android\ndk\sources\cxx-stl\gnu-libstdc++\4.7\include
    C:\android\ndk\sources\cxx-stl\gnu-libstdc++\4.7\libs\armeabi\include
    

提交回复
热议问题