找回密码
 注册
搜索
热搜: 回贴
微赢网络技术论坛 门户 服务器 Linux/BSD 查看内容

给eclipse安装CDT插件开发C/C 工程

2009-12-20 13:14| 发布者: admin| 查看: 105| 评论: 0|原作者: 夙玉


C/C 开发工具箱(C/C Development Toolkit,CDT),它是可用于 Eclipse 的最佳 C/C 工具箱。
按照eclipse的官方网站的要求,要下载如下的东东:
1.eclipse(
http://www.eclipse.org/downloads/index.php
),我下的是3.0,也有更高一点的版本,如果想要有中文帮助的,可以下载2.1.2版,我是把两个都下来,在2.1.2中看帮助,在3.0中用。
2.下载cdt 2.0.2(
http://download.eclipse.org/tools/cdt/releases/new/
),cdt的版本也很多,要注意下载的和你eclipse匹配的,支持eclipse 3.0的cdt 2.0.2还不是很成熟,所以在CDT主版本下载页面没有直接给出,你可以在我给的网址下载。
3.下载minGW,这个东西是什么你自己到网上查吧,反正必须有。但是网上不好找(官方网站连不上),我好人做到底,在我的服务器上下吧:
http://2peak.bluesaga.com/other/minGW.exe
,然后安装。
4.
假设你的minGW安装在c:\mingw目录中,在环境变量中设置PATH=c:\mingw\bin;这句一定放在最前面,防止和VC/.NET之类
的make命令冲突,并且把c:\mingw\bin目录中的XXX-make.EXE改成make.exe。然后在CMD中,执行一下
make.exe,如果是“*** No targets specified and no makefile found.
Stop.”那就对了。
screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt='Click here to open new window\nCTRL Mouse wheel to zoom in/out';}" onmouseover="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.style.cursor='hand'; this.alt='Click here to open new window\nCTRL Mouse wheel to zoom in/out';}" onclick="if(!this.resized) {return true;} else {window.open('http://c:\Documents and Settings\zhengyf\My Documents\My Pictures\11.JPG');}" onmousewheel="return imgzoom(this);" alt="" />
5.安装eclipse,解压就行了,不用什么安装程序(真是绿色啊)。
6.将cdt解压,有两个文件夹:features和plusins,把文件夹中的东东拷到eclipse对应的目录中。
7.现在启动eclipse,然后在file->new->project中看看有没有C/C 的工程向导?如果有,恭喜你!如果没有,也别着急,因为你碰到了我。
8.在help->software updates->find and install...中,选择search for new features to install,然后点击new remote site按钮,添加如下地址:
http://update.eclipse.org/tools/cdt/releases/new
,然后选中它,eclipse就会到这个地址查找新的cdt,等一会,列出cdt的版本,选择最新的,然后一路next,它就会开始从网上下载并安装,安装完后会提示重启eclipse。
screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt='Click here to open new window\nCTRL Mouse wheel to zoom in/out';}" onmouseover="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.style.cursor='hand'; this.alt='Click here to open new window\nCTRL Mouse wheel to zoom in/out';}" onclick="if(!this.resized) {return true;} else {window.open('http://c:\Documents and Settings\zhengyf\My Documents\My Pictures\3.JPG');}" onmousewheel="return imgzoom(this);" alt="" />
9.搞定,看到图中的c、c 工程向导了吧!
screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt='Click here to open new window\nCTRL Mouse wheel to zoom in/out';}" onmouseover="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.style.cursor='hand'; this.alt='Click here to open new window\nCTRL Mouse wheel to zoom in/out';}" onclick="if(!this.resized) {return true;} else {window.open('http://c:\Documents and Settings\zhengyf\My Documents\My Pictures\2.JPG');}" onmousewheel="return imgzoom(this);" alt="" />
现在测试你的编译器和make程序是否能正常工作。新建一个managed make C project(自动生成makefile),然后新建一个class文件,还是用helloworld的例子。我的文件内容如下:
相关链接
http://dev.csdn.net/article/39/39579.shtm
http://www.ibm.com/developerworks/cn/linux/opensource/os-ecc/











最新评论

QQ|小黑屋|最新主题|手机版|微赢网络技术论坛 ( 苏ICP备08020429号 )

GMT+8, 2024-9-29 15:32 , Processed in 0.196829 second(s), 12 queries , Gzip On, MemCache On.

Powered by Discuz! X3.5

© 2001-2023 Discuz! Team.

返回顶部