您的位置:首页 > 编程语言 > Java开发

BBB(三):在Eclipse中搭建BBB交叉编译环境——在线运行与gdb远程调试

2016-06-16 11:52 811 查看
用Vim写代码尽管快速,但是没有代码补全,也懒得折腾找插件;另外GDB调试起来由于不太熟练,常常比较慢。代码简单、较短的还可以应付,长一点就头疼了。因此一个交叉编译环境还是需要的。

主要参考的链接:

http://blog.csdn.net/zy812248258/article/details/38342287

http://blog.csdn.net/zj651927693/article/details/12874717

以及盈鹏飞linux_evb-t335ii\linux\doc\应用开发调试手册eclipse.pdf

这里最好先根据自己BBB上的gcc编译器去选择合适的,输入命令arm-linux-gnueabi来补全,看到底有没有hard float。例如第二个链接中的gcc是arm-linux-gnueabi。可以输入gcc -v查看版本,我BBB上是的arm-linux-gnueabihf-gcc,版本是4.6.3的arm-linux-gnueabihf-gcc




在宿主机上则是4.8.6的arm-linux-gnueabihf-gcc



安装的时候第一个作者的教程挺详细的,但还是遇到了问题:

主要问题:

首先添加完Remote System 时没有Terminal



远程登录后添加单独到一个terminal
1: Navigate to: Help -> Install New Software...
Dropdown list for Work with: to say Mars - http://download.eclipse.org/releases/mars Select: Mobile and Device Development, especially Target Management Terminal which is "An ANSI (vt102) compatible Terminal including plug-ins for Serial, SSH and Telnet connections."
Click Next and anything else to finish the install ...
2: Open the view
Navigate to: Window -> Show View -> Other ... -> Terminal -> Terminal (NOTE: singular Terminal, not plural Terminals)
3: Open a terminal
在remote工程名上右键,open terminal。




远程在线调试

这里的问题是



我自己编译GDB,可是失败了,后来在盈鹏飞的资料中发现他们已经做过这一步啦,而且编译文件也放出来了。

经过多方参考,我的BBB上的设置如下







最后的远程调试截图

内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: