我需要将 ZThread 库移植到 android 开发环境。
我遵循了这个: http://blog.jimjh.com/compiling-open-source-libraries-with-android-ndk-part-2.html
当我设置 --host=arm-eabi
时,配置文件检查 arm-eabi-g++
arm-eabi-c++
...,但我的交叉编译工具链名为 arm-linux-androideabi-*
;好吧,当我更改为 --host=arm-linux-androideabi
,它说系统“androideabi”无法识别,我认为它不在 config.sub 文件中。
关键是configure文件如何找到正确的交叉编译工具?
错误信息是:
检查构建系统类型...无效配置 arm-linux-androideabi': system
androideabi' not recognized
编辑: 您可以尝试为您的第三个库编写 Android.mk 文件,android NDK 将使用 Android.mk 文件为您交叉编译库(就像 makefile 一样工作)。有一个 ZThread 的 Android.mk 示例,由我的评论给出
最佳答案
你需要更新配置。*
http://ftp.us.debian.org/debian/pool/main/a/autotools-dev/autotools-dev_20110511.1_all.deb
cp -av /usr/share/misc/config.guess ./
cp -av /usr/share/misc/config.sub ./
检查:
关于android - 配置文件如何找到正确的交叉编译工具?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6759315/