[英]NDK r16b standalone toolchain error: “/usr/bin/ld: this linker was not configured to use sysroots”
I'm trying to build an app using Android NDK. 我正在尝试使用Android NDK构建应用程序。 The compile went successfully but in the linking step it fails with error as below:
编译成功,但在链接步骤中失败,并显示以下错误:
1> /usr/bin/ld: this linker was not configured to use sysroots
clang50++.exe: error: linker command failed with exit code 1 (use -v to see invocation)
I'm using 我正在使用
--sysroot=<MyNDKPath>/sysroot
And 和
-isystem <MyNDKPath>/sysroot/usr/include/arm-linux-androideabi
when compiling 编译时
Can anyone help me on resolving this ? 谁能帮助我解决这个问题?
For me it was a missing path to ld. 对我而言,这是通往ld的缺失之路。 I added it to the PATH environment variable inside Eclipse and it worked:
我将其添加到Eclipse内的PATH环境变量中,并且可以正常工作:
${ANDROID_NDK}\toolchains\aarch64-linux-android-4.9\prebuilt\windows-x86_64\bin
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.