Android ndk-build 编译错误 : ld: error: undefined symbol: std::__ndk1:

原因:

local.properties:ndk.dir 过期:

NDK was located by using ndk.dir property.
This method is deprecated and will be removed in a future release.
If you delete ndk.dir from local.properties and set android.ndkVersion to [22.1.7171670]
then NDK at
/Users/tmk/Library/Android/sdk/ndk/22.1.7171670 will be used.
https://developer.android.com/r/studio-ui/ndk-dir

解决:

1、取消 local.properties 中的 ndk.dir :

sdk.dir=/Users/tmk/Library/Android/sdk
#ndk.dir=/Users/tmk/Library/Android/sdk/ndk-bundle

2、确保已下载 ndkcmake

Android ndk-build 编译错误 : ld: error: undefined symbol: std::__ndk1:_第1张图片

你可能感兴趣的:(Android ndk-build 编译错误 : ld: error: undefined symbol: std::__ndk1:)