linux - Qt for Android on Mac 或 Linux build "Can not detect ndk toolchain..."

标签 linux macos qt android-ndk

我刚刚安装了SDKNDKJDK。 当我输入终端时:

moroz@moroz:~/qt/qt5$ ./configure -developer-build -opensource -confirm-license -xplatform android-g++ -nomake tests -nomake examples -android-ndk android-ndk-r9/ -android-sdk android-sdk-linux/ -android-ndk-host linux-x86_64 -android-toolchain-version 4.8 -skip qttranslations -skip qtwebkit -skip qtserialport -skip qtwebkit-examples

然后

moroz@moroz:~/qt/qt5$ /home/moroz/qt/qt5/qtbase/configure -top-level -developer-build -opensource -confirm-license -xplatform android-g++ -nomake tests -nomake examples -android-ndk android-ndk-r9/ -android-sdk android-sdk-linux/ -android-ndk-host linux-x86_64 -android-toolchain-version 4.8 -skip qttranslations -skip qtwebkit -skip qtserialport -skip qtwebkit-examples

我得到了以下错误:

Can not detect Android NDK toolchain. Please use -android-toolchain-version to specify

并且在 Mac 和 Ubuntu 上有相同的消息!

最佳答案

在 Mac 上你应该使用

-android-ndk-host darwin-x86_64

它在 ndkfolder/prebuilt/中解析 -android-ndk-host(我有 darwin-x86_x64、android-arm、android-mips、android-x86、common)

关于linux - Qt for Android on Mac 或 Linux build "Can not detect ndk toolchain...",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18750402/

相关文章:

python - 如何解决dyld : Symbol not found - Expected in:/usr/lib/libSystem. B.dylib(_fdopendir $ INODE64)

objective-c - 多线程在 NSView 中绘制

c++ - QML:如何在不实际移动任何可见组件的情况下在 MouseAeria 上获得鼠标移动的方向?

c - 如何清除 scanf 读取的内容?

c++ - APPNAME 不包含在 QStandardPaths::AppDataLocation 中

python - 由于权限问题,django-chronograph 脚本不会从 cron 作业运行或手动运行

linux - 为裸机部署设置 Kubernetes 节点

c++ - 无法在未指定捕获默认值的 lambda 中隐式捕获变量

html - QT html和CSS转pdf文件

c++ - Qt 安装程序框架 : How to sign the maintenancetool. exe