Android NDK自定义交叉编译工具链
来源:互联网 发布:迪蒙网贷系统源码 编辑:程序博客网 时间:2024/05/22 02:00
简书排版
http://www.jianshu.com/p/3bbad4b1b099
- 1
首先上官方文档
https://developer.android.com/ndk/guides/standalone_toolchain.html
可以自定义工具链进行交叉编译
1.对不同的指令集APP_ABI设置
Architecture
Toolchain name
ARM-based
arm-linux-androideabi-<gcc-version>
x86-based
x86-<gcc-version>
MIPS-based
mipsel-linux-android-<gcc-version>
ARM64-based
aarch64-linux-android-<gcc-version>
X86-64-based
x86_64-<gcc-version>
MIPS64-based
mips64el-linux-android--<gcc-version>
2.工具链和相应的值,使用–arch
Toolchain
Value
mips64 compiler
--arch=mips64
mips GCC 4.8 compiler
--arch=mips
x86 GCC 4.8 compiler
--arch=x86
x86_64 GCC 4.8 compiler
--arch=x86_64
mips GCC 4.8 compiler
--arch=mips
3.工具链和相应的值,使用–toolchain
Toolchain
Value
arm
--toolchain=arm-linux-androideabi-4.8
arm
--toolchain=arm-linux-androideabi-4.9
arm
--toolchain=arm-linux-android-clang3.5
arm
--toolchain=arm-linux-android-clang3.6
x86
--toolchain=x86-linux-android-4.8
x86
--toolchain=x86-linux-android-4.9
x86
--toolchain=x86-linux-android-clang3.5
x86
--toolchain=x86-linux-android-clang3.6
mips
--toolchain=mips-linux-android-4.8
mips
--toolchain=mips-linux-android-4.9
mips
--toolchain=mips-linux-android-clang3.5
mips
--toolchain=mips-linux-android-clang3.6
arm64
--toolchain=aarch64-linux-android-4.9
arm64
--toolchain=aarch64-linux-android-clang3.5
arm64
--toolchain=aarch64-linux-android-clang3.6
x86_64
--toolchain=x86_64-linux-android-4.9
x86_64
--toolchain=x86_64-linux-android-clang3.5
x86_64
--toolchain=x86_64-linux-android-clang3.6
mips64
--toolchain=mips64el-linux-android-4.9
mips64
--toolchain=mips64el-linux-android-clang3.5
mips64
--toolchain=mips64el-linux-android-clang3.6
主机工具链和相应的值,使用-system
Host toolchain
Value
64-bit Linux
-system=linux-x86_64
64-bit MacOSX
-system=darwin-x86_64
64-bit Windows
-system=windows-x86_64
自定义
- 1
- 2
- 3
上面演示的仅仅是单一的arm工具链
可以根据自己的需要独立配置
不过相应的arch和对应的toolchain要对应
可以写个Shell脚本处理make_toolchain.sh
在开头配置好相应的路径,和platform即可
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
- 28
- 29
- 30
- 31
运行
- 1
交叉编译的工具链配置完成,方便后续进行交叉编译
阅读全文
0 0
- Android NDK自定义交叉编译工具链
- NDK交叉编译之自定义工具链
- Android NDK 提供的交叉工具链手动编译源码
- Android NDK 提供的交叉工具链手动编译源码
- Android NDK 提供的交叉工具链手动编译源码
- android--ndk交叉编译工具安装
- android NDK提取toolchain(交叉编译工具)
- android NDK 交叉编译
- android NDK 交叉编译
- android NDK 交叉编译
- Android NDK 交叉编译
- android NDK 交叉编译
- android NDK 交叉编译
- android NDK 交叉编译
- Android NDK 交叉编译
- 使用 Android NDK Stand-alone 交叉编译工具
- Android 下交叉编译使用(Android NDK 默认的交叉编译工具 )
- 使用 Android NDK 的交叉编译工具链移植 C/C++ 项目到安卓平台
- 实战第二站--购物车简单实现
- sql数据库的分析方式 事物 索引 锁机制
- Java小功能(1)--使用默认工具打开文件
- openCV学习笔记(三): 认识Mat
- ubuntu16.04 安装keepass并汉化,解决乱码问题
- Android NDK自定义交叉编译工具链
- 非程序员的编程之旅——Python基础篇(4)流程控制与异常处理
- MVP解绑
- 数据分析师的编程之旅——Python基础篇(8)常用内置模块文档
- [Android]解决小米手机神坑问题:Installation failed with message Failed to establish session
- BZOJ 2001 Hnoi2010 城市建设
- HiDeubg-unity日志扩展插件(免费)
- kendoGrid 选中上一行、下一行
- TabLayout横向滑动菜单