关于在 Ubuntu VM(64 位)上安装 ARM 工具链的建议 [英] Advice regarding installing ARM toolchain on Ubuntu VM (64bit)

查看:29
本文介绍了关于在 Ubuntu VM(64 位)上安装 ARM 工具链的建议的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

尝试在Ubuntu虚拟机上为arm平台编译Linux内核

Trying to compile Linux kernel for arm platform on a Ubuntu virtual machine

$make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi-

失败如下

arm-none-linux-gnueabi-gcc: not found

尝试安装

$sudo apt-get install arm-none-linux-gnueabi-gcc

E: unable to locate package arm-none-linux-gnueabi-gcc

在哪里可以找到正确的包?如何将其包含在系统中?(我在网上找到了几个对我不起作用的链接).如果您能提供正确的解决方案或参考,那就太好了.

Where to find the correct package? how to include it in the system? (I found a couple of links on line that didn't work for me). It would be great if you could provide a correct solution or reference.

推荐答案

  1. https://sourcery.mentor.com/GNUToolchain/

https://sourcery.mentor.com/sgpp/lite/arm/portal/subscription?@template=lite

获取 arm-none-linux-gnueabi 工具链的正确版本(即针对 GNU/Linux 而不是 EABI).

Get correct version of the arm-none-linux-gnueabi toolchain (i.e. targetting GNU/Linux rather than EABI).

解压

tar xvf arm-2013.05-24-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2

  • 打开 bashrc

  • open bashrc

    vi .bashrc
    

    最后添加下面的命令

    export PATH=$PATH:{path to toolchain}arm-2013.05/bin
    

    例如 export PATH=$PATH:/home/vinay/under_linux/arm-2013.05/bin

    保存并退出终端.

    然后你可以交叉编译而无需每次导出.

    then you can cross-compile without everytime export.

    同样采用正确的工具链,有两种工具链可以根据您的要求进行选择.

    Also take of correct toolchain there are two toolchain available choose according to your requirement.

    交叉编译错误arm-none-eabi-g++ 找不到入口符号"

    这篇关于关于在 Ubuntu VM(64 位)上安装 ARM 工具链的建议的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

  • 查看全文
    登录 关闭
    扫码关注1秒登录
    发送“验证码”获取 | 15天全站免登陆