ÔÚEclipseϵÄC/C++¿ª·¢£¨Eclipse3.2 + CDT 3.1£©
ÒªÈà Eclipse ¿ÉÒÔ¿ª·¢ C/C++ ³Ìʽ£¬Òª¹ÒÉÏ CDT ²Å¿ÉÒÔ¡£
Ê×ÏÈÒªÏÂÔØCDT
CDTµÄ×îа汾ÊÇ 3.1.0£¬ËüÖ§³Öeclipse3.2.0£¬ÆäÏÂÔصØÖ·£ºhttp://download3.eclipse.org/tools/cdt/releases/callisto/dist/3.1.0/£¬»òÕßÊǵ½http://www.eclipse.org/cdt/downloads.phpÏÂÔØÆäËü°æ±¾¡£Èç¹ûÄã°²裝µÄ Eclipse ÊÇ 3.0.x °æ¾Í±Ø須°²裝 CDT 2.1.1 ×îаæ
Èç¹û°²裝µÄ Eclipse ÊÇ 3.1.x °æ£¬¾Í±Ø須°²裝 CDT 3.0 °æ
½ÓÏÂÀ´ÊÇ°²裝
½«½âѹºóµÄfeatures¡¢pluginsÕû¸öÎļþ¼Ð¸´ÖƵ½Eclipse°²裝Ŀ¼ÖУ¬ÖØÐÂÆô¶¯Eclipse¼´¿É¡£ÔÚ½¨Á¢ÐÂÏîÄ¿µÄ´°¿ÚÀ¿´µ½ÒѾÓÐÁË C ¼° C++ µÄÑ¡Ï´ú±í°²裝³É¹¦ÁË¡£Èç¹û¿´²»µ½£¬ºÇºÇ£¬Äã¾Í×Ô¼ºÔÙÊÔ°É¡£
»¹Òª°²裝MinGW——Minimalist GNU for Windows
ËäÒÑÔÚ EclipseÉÏ°²×°ÁËCDT£¬µ«»¹ÐèÒªÒ»¸ö "±àÒïÆ÷" ²ÅÄܱàÒï³Ìʽ£¬ËùÒÔÒªÏÂÔØ¿ÉÔÚWindows»·¾³ÀïʹÓõÄGNU C¡¢C++±àÒïÆ÷£¬ÎÒÕâÀïÒªÏÂÔصÄÊÇ£ºMinGW¡£ËüµÄÏÂÔصØÖ·£ºhttp://sourceforge.net/project/showfiles.php?group_id=2435£¬Èç¹ûûÕÒµ½£¬Ò²¿Éµ½ËüµÄÀϼÒÈ¥ÕÒ£¬ÀϼҵØÖ·ÊÇhttp://www.mingw.org/download.shtml¡£ÎÒÓõÄÊÇ×îа汾£ºMinGW 5.0.3¡£
°²×°¾Í²»Óð³½²ÁË°É£¬¼ÙÉè°²×°ÔÚX:\MinGW¡£°²×°ºóÒªÉèÖÃÆä»·¾³±äÁ¿(Ëĸö)£º
PATH £º
X:\MinGW\bin;
LIBRARY_PATH£º
X:\MinGW\lib
C_INCLUDE_PATH£º
X:\MinGW\include
CPLUS_INCLUDE_PATH£º
X:\MinGW\include\c++\3.2.3;C:\MinGW\include\c++\3.2.3\mingw32;C:\MinGW\include\c++\3.2.3\backward;C:\MinGW\include
»¹ÓÐÁ½¸öϸ½Ú£º
1¡¢ÒòΪEclipseÀïÃæÔ¤ÉèÓÃÀ´±àÒïµÄÎļþÃûΪmake.exe£¬¶øÔÚMingw°²裝ºóÓÃ×÷makeµÄÎļþÃûΪmingw32-make.exe£¬ËùÒÔÒª°Ñmingw32-make ¸ÄÃûΪma
Ïà¹ØÎĵµ£º
CºÍC++ÖеÄÖ÷ÒªÊý¾ÝÀàÐͺÍ×Ö½Ú´óС(
C/C++µÄд·¨ÊDz»¿ÆѧºÍ²»ÑϽ÷µÄ¡£ÒòΪCºÍC++ËäÈ»ÓïÒ壬µ«ÊÇÉè¼Æ˼ÏëÊǽṹ»¯ÓëÃæÏò¶ÔÏó. C±ê×¼¹æ·¶ÓëC++µÄ±ê×¼¹æ·¶Ò²ÊÇÁ½¸öÎı¾¡£½üÀ´×ÐϸÑо¿ÁËËüÃǵÄÊý¾ÝÀàÐÍ£¬²ÅÖªµÀÆäÀ´ÁúÈ¥Âö£¬ÕæÕý×öµ½ÆäʵËùÒÔÈ»¡£
1¡¢CÓïÑÔ¶¨ÒåÁË5ÖÖ»ù±¾Êý¾ÝÀàÐÍ
char(×Ö·û), int(Õ ......
/*
**ÅжÏC?ÐÐ??¾³µÄ³ÌÐò
*/
/*
**¾²?³õʼ»¯
*/
int static_variable=5;
void
f()
{
register int i1, i2, i3, i4, i5, i6, i7, i8, i9, i10;
register char *c1, *c2, *c3, *c4, *c5, *c6, *c7 , *c8, *c9, *c10;
extern int a_very_long_name_to_sec_how_long_they_can_be;
double ......
access£¨ÅжÏÊÇ·ñ¾ßÓдæÈ¡ÎļþµÄȨÏÞ£©
¡¡¡¡Ïà¹Øº¯Êý stat£¬open£¬chmod£¬chown£¬setuid£¬setgid
¡¡¡¡±íÍ·Îļþ #include<unistd.h>
¡¡¡¡¶¨Ò庯Êý int access(const char * pathname,int mode);
¡¡¡¡º¯Êý˵Ã÷ access()»á¼ì²éÊÇ·ñ¿ÉÒÔ¶Á/дijһÒÑ´æÔÚµÄÎļþ¡£²ÎÊýmodeÓм¸ÖÖÇé¿ö×éºÏ£¬R_OK ......