Problem on compiling project with JSB on Android platform

Hello, I tried to compile for Android platform using:

cocos compile -p android --android-studio

it’s a c++ projects with JS Bindings capability, and then encountered with this problem:

/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xb84): error: undefined reference to 'std::ios_base::ios_base()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xbe8): error: undefined reference to 'std::basic_ios<char, std::char_traits<char> >::init(std::basic_streambuf<char, std::char_traits<char> >*)'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xc08): error: undefined reference to 'std::basic_filebuf<char, std::char_traits<char> >::basic_filebuf()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xc14): error: undefined reference to 'std::basic_ios<char, std::char_traits<char> >::init(std::basic_streambuf<char, std::char_traits<char> >*)'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xc28): error: undefined reference to 'std::basic_filebuf<char, std::char_traits<char> >::open(char const*, std::_Ios_Openmode)'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xc54): error: undefined reference to 'std::basic_ios<char, std::char_traits<char> >::clear(std::_Ios_Iostate)'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xc8c): error: undefined reference to 'std::basic_istream<char, std::char_traits<char> >& std::getline<char, std::char_traits<char>, std::allocator<char> >(std::basic_istream<char, std::char_traits<char> >&, std::basic_string<char, std::char_traits<char>, std::allocator<char> >&, char)'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xcc0): error: undefined reference to 'std::string::find(char const*, unsigned int, unsigned int) const'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xce4): error: undefined reference to 'std::string::assign(char const*, unsigned int)'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xcec): error: undefined reference to 'std::ios_base::ios_base()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xd34): error: undefined reference to 'std::basic_ios<char, std::char_traits<char> >::init(std::basic_streambuf<char, std::char_traits<char> >*)'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xd4c): error: undefined reference to 'std::basic_filebuf<char, std::char_traits<char> >::basic_filebuf()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xd58): error: undefined reference to 'std::basic_ios<char, std::char_traits<char> >::init(std::basic_streambuf<char, std::char_traits<char> >*)'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xd6c): error: undefined reference to 'std::basic_filebuf<char, std::char_traits<char> >::open(char const*, std::_Ios_Openmode)'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xda0): error: undefined reference to 'std::basic_ios<char, std::char_traits<char> >::clear(std::_Ios_Iostate)'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xdb4): error: undefined reference to 'std::string::find(char const*, unsigned int, unsigned int) const'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xdec): error: undefined reference to 'std::ctype<char>::_M_widen_init() const'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xe10): error: undefined reference to 'std::basic_istream<char, std::char_traits<char> >& std::getline<char, std::char_traits<char>, std::allocator<char> >(std::basic_istream<char, std::char_traits<char> >&, std::basic_string<char, std::char_traits<char>, std::allocator<char> >&, char)'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xe68): error: undefined reference to 'std::basic_filebuf<char, std::char_traits<char> >::close()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xe70): error: undefined reference to 'std::__basic_file<char>::~__basic_file()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xe88): error: undefined reference to 'std::locale::~locale()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xeb0): error: undefined reference to 'std::ios_base::~ios_base()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xebc): error: undefined reference to 'std::ctype<char>::_M_widen_init() const'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xf20): error: undefined reference to 'std::basic_filebuf<char, std::char_traits<char> >::close()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xf2c): error: undefined reference to 'std::__basic_file<char>::~__basic_file()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xf38): error: undefined reference to 'std::locale::~locale()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xf60): error: undefined reference to 'std::ios_base::~ios_base()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0xfac): error: undefined reference to 'std::string::_Rep::_M_destroy(std::allocator<char> const&)'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0x1000): error: undefined reference to 'std::string::find(char const*, unsigned int, unsigned int) const'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0x1038): error: undefined reference to 'std::__throw_bad_cast()'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0x1044): error: undefined reference to 'std::string::_Rep::_S_empty_rep_storage'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0x1048): error: undefined reference to 'vtable for std::basic_ios<char, std::char_traits<char> >'
/Development/android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64/bin/../lib/gcc/arm-linux-androideabi/4.9/../../../../arm-linux-androideabi/bin/ld: the vtable symbol may be undefined because the class is missing its key function
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0x104c): error: undefined reference to 'VTT for std::basic_ifstream<char, std::char_traits<char> >'
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0x1050): error: undefined reference to 'vtable for std::basic_ifstream<char, std::char_traits<char> >'
/Development/android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64/bin/../lib/gcc/arm-linux-androideabi/4.9/../../../../arm-linux-androideabi/bin/ld: the vtable symbol may be undefined because the class is missing its key function
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0x107c): error: undefined reference to 'vtable for std::basic_filebuf<char, std::char_traits<char> >'
/Development/android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64/bin/../lib/gcc/arm-linux-androideabi/4.9/../../../../arm-linux-androideabi/bin/ld: the vtable symbol may be undefined because the class is missing its key function
/Projects/zl-client-2/ZeroLegend/proj.android-studio/../cocos2d/external/spidermonkey/prebuilt/android/armeabi-v7a/libjs_static.a(jscntxt.o)(.text+0x1080): error: undefined reference to 'vtable for std::basic_streambuf<char, std::char_traits<char> >'
/Development/android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64/bin/../lib/gcc/arm-linux-androideabi/4.9/../../../../arm-linux-androideabi/bin/ld: the vtable symbol may be undefined because the class is missing its key function
collect2: error: ld returned 1 exit status
make: *** [obj/local/armeabi-v7a/libcocos2dcpp.so] Error 1
make: Leaving directory `/Projects/zl-client-2/ZeroLegend/proj.android-studio/app'
Error running command, return code: 2.

Below is the development environment I’m currently in:
Mac OS X 10.11.3
Cocos2Dx 3.8
Android NDK r10e

And here’s a snippet of my Application.mk file:

APP_STL := c++_static

APP_PLATFORM := android-15

APP_CPPFLAGS := -frtti -DCC_ENABLE_CHIPMUNK_INTEGRATION=1 -std=c++11 -fsigned-char -fexceptions -D__STDC_LIMIT_MACROS -lstdc++
APP_LDFLAGS := -latomic

APP_ABI := armeabi-v7a

ifeq ($(NDK_DEBUG),1)
  APP_CPPFLAGS += -DCOCOS2D_DEBUG=1
  APP_OPTIM := debug
else
  APP_CPPFLAGS += -DNDEBUG
  APP_OPTIM := release
endif

I have tried some solution posted on other topics and stackoverflow as well, starting from change the NDK runtime, change the NDK itself to r11, r12, updating spidermonokey module with the one from repository, but none of them seems to solve this.

If any any of you guys ever encountered the same or similar problem, or have the solution, please help me figure this out. Thanks in advance.