问题描述
我从飞思卡尔(的i.MX53)上运行的Linux操作系统Ubuntu ARM一的Coretex-A8开发板。它启动后就好了,我可以用鼠标/键盘/终端访问系统。
要开始我想就其上运行的主机操作系统里面的电路板的应用程序,就像您在您的PC上运行的应用程序做的。
我的问题是编译我的测试程序,使用类似YAGARTO工具链是基于GCC我与链接的麻烦最终bacause我还没有定义的启动脚本。
我找到很多资料建设裸机配置(inluding编译内核,使负荷和链接脚本),但没有什么有用的制作在主机操作系统上运行的应用程序一个 P>
我的开发环境是在Windows 7上运行我也有在Linux上运行X86的选择,但我怀疑这帮助对子级做我的应用ARM
有关ARM-Linux的应用开发preferable的选择是一个Linux主机(x86)的机器安装一个ARM工具链。在Ubuntu桌面机可以使用下面的命令来安装ARM工具链:
的apt-get安装GCC-ARM的Linux的gnueabi
在工具链安装,可以使用以下命令进行交叉编译:
GCC-ARM的Linux的gnueabi-GCC -o你好的hello.c
使用这个工具链可以跨编译使用标准C库,而无需启动code的C程序。应用程序可以在您的主机的Linux(x86)的平台交叉编译并在目标Linux(ARM)平台上运行。
ARM-Linux的工具链的Windows版本也已经推出。你可以从。
- 一个开放的组织,致力于在ARM Linux的提高,一定会为你的工作提供了良好的参考。
I have a ARM Coretex-A8 development board from Freescale (i.MX53) running Linux Ubuntu. It boots up just fine and I can access the system with mouse/keyboard/terminal.
To get started I would like to make an application running on the board inside the host OS, just as you do when you run application on your PC.
My problem is to compile my test program, using toolchains like YAGARTO which is based on gcc i end up in trouble with the linking bacause I have not defined any startup script.
I find lot of information on building "bare metal" configurations (inluding compiling the kernel and make load and link scripts), but not anything usefull for making a application running on a host OS.
My development environment is running on Windows 7. I also have the option to run on Linux X86, but i doubt this whould help me making ARM applications.
For ARM-Linux application development the preferable choice is a Linux Host(x86) machine with a ARM toolchain installed in it. In Ubuntu Desktop machine you can use the following command to install ARM toolchain:
apt-get install gcc-arm-linux-gnueabi
After toolchain installation you can use the following command for cross compilation:
gcc-arm-linux-gnueabi-gcc -o hello hello.c
Using this toolchain you can cross-compile your C program using Standard C library without the need of startup code. Applications can be cross-compiled at your Host Linux(x86) platform and run on Target Linux(ARM) platform.
Windows version of ARM-Linux Toolchain is also available. You can get it from here.
Linaro Developers Wiki - an open organization focused on improving Linux on ARM, will be a good reference for your work.
这篇关于编译一个Linux程序为ARM架构 - 主机操作系统上运行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!