Linux GCC makeÎļþµÄд·¨2
ÎļþÔÚÁ½¸öÎļþ¼Ð£º
inc/hello.h
main/hello.c, main.c, Makefile
ÎļþÄÚÈÝ£º
hello.h
void hello(char name[]);
hello.c
#include <stdio.h>
void hello(char name[])
{
printf("Hello %s!\n", name);
}
main.c
#include <stdio.h>
#include "../inc/hello.h"
// The second
int main()
{
hello("GCC");
printf("Haha Linux Ubuntu!\n");
return 0;
}
Makefile
# String declaration
objects = main.o hello.o
# Command
app : $(objects)
cc -o app $(objects)
main.o : main.c hello.h
cc -c main.c
hello.o : hello.c stdio.h
cc -c hello.c
# Search paths
vpath %.h /usr/include ../inc
# Clean the intermediate files
.PHONY : clean
clean :
rm app $(objects)
Ïà¹ØÎĵµ£º
ºÍ
WindowsϵͳһÑùLinuxÒ²Óо²Ì¬/¶¯Ì¬Á´½Ó¿â£¬ÏÂÃæ½éÉÜ´´½¨ºÍʹÓ÷½·¨£º
¼ÙÉèÓÐÏÂÃæ¼¸¸öÎļþ£º
Í·ÎļþString.h£¬ÉùÃ÷Ïà¹Øº¯ÊýÔÐΣ¬ÄÚÈÝÈçÏ£º
Strlen.c£º
º¯ÊýStrlenµÄʵÏÖ£¬»ñÈ¡¸ø¶¨×Ö·û´®µÄ³¤¶È£¬ÄÚÈÝÈçÏ£º
Strlnen.c£ºº¯Êý
StrNlenµÄʵÏÖ£¬»ñÈ¡¸ø¶¨×Ö·û´®µÄ³¤¶È£¬Èç¹ûÊäÈë×Ö·û´®µÄ³¤¶È´óÓÚÖ¸¶¨µÄ×î´ó³¤¶È£¬Ô ......
Òý£º
Linux²Ù×÷ϵͳÊÇÓÉLinus TorvaldsÏÈÉúÔÚ1991Äê´´½¨µÄ£¬Ö®ºó²»¶Ï»ñµÃ»¥ÁªÍøÉÏÖÚ¶à³ÌÐòÔ±µÄ×ÔÔ¸Ö§³Ö£¬¾¹ýÊ®¼¸ÄêµÄ·¢Õ¹£¬Èç½ñÒѾ³ÉΪ¼ÌWindowsÖ®ºóµÄµÚ¶þ´óµçÄÔ²Ù×÷ϵͳÈí¼þ¡£
ÄãÊÇ·ñ¶ÔLinuxÓгä·ÖµÄÁ˽âÄØ£¿×÷ΪһÖÖÆ½Ì¨£¬LinuxÊ×ÏÈ»ñµÃÁ˳ÁÄçÓÚijÖÖñ±ºÃ֮ʿºÍºÚ¿ÍÃǵÄ
Çàíù¡£Linux²Ù×÷ϵͳÊÇÓÉLinus
TorvaldsÏÈÉú ......
Ëæ×Å Linux ²Ù×÷ϵͳµÄ¹ã·ºÓ¦Óã¬ÌرðÊÇ Linux ÔÚǶÈëʽÁìÓòµÄ·¢Õ¹£¬Ô½À´Ô½¶àµÄÈË¿ªÊ¼Í¶Éíµ½ Linux Äں˼¶µÄ¿ª·¢ÖС£Ãæ¶ÔÈÕÒæÅÓ´óµÄ Linux ÄÚºËÔ´´úÂ룬¿ª·¢ÕßÔÚÍê³É×Ô¼ºµÄÄں˴úÂëºó£¬¶¼½«ÃæÁÙ×ÅͬÑùµÄÎÊÌ⣬¼´ÈçºÎ½«Ô´´úÂëÈÚÈëµ½ Linux ÄÚºËÖУ¬Ôö¼ÓÏàÓ¦µÄ Linux ÅäÖÃÑ¡Ï²¢×îÖÕ±»±àÒë½ø Linux Äںˡ£Õâ¾ÍÐèÒªÁ˽â Linu ......
ÔÎijö´¦£ºhttp://www.svn8.com/shouce/Linux/kernel_options.html×ðÖØÔ´´£¡
Code maturity level options
´úÂë³ÉÊì¶ÈÑ¡Ïî
Prompt for development and/or incomplete code/drivers ÏÔʾÉÐÔÚ¿ª·¢ÖлòÉÐδÍê³ÉµÄ´úÂëÓëÇý¶¯.³ý·ÇÄãÊDzâÊÔÈËÔ±»òÕß¿ª·¢Õß,·ñÔòÇëÎðÑ¡Ôñ
General setup
³£¹æÉèÖÃ
Local version - append ......
ÎÒΪʲô·¢±í²»ÁËÎÄÕÂÄØ£¿
1. ÔÚLinuxϵͳÖУ¬ÒÔ Îļþ ·½Ê½·ÃÎÊÉ豸 ¡£
2. LinuxÄÚºËÒýµ¼Ê±£¬´ÓÎļþ /etc/fstab ÖжÁȡҪ¼ÓÔØµÄÎļþϵͳ¡£
3. LinuxÎļþϵͳÖÐÿ¸öÎļþÓà i½Úµã À´±êʶ¡£
4. È«²¿´ÅÅÌ¿éÓÉËĸö²¿·Ö×é³É£¬·Ö±ðΪÒýµ¼¿é ¡¢×¨ÓÃ¿é ¡¢ i½Úµã±í¿é ºÍÊý¾Ý´æ´¢¿é¡£
5. Á´½Ó·ÖΪ£º Ó²Á´½Ó ºÍ ·ûºÅÁ´½Ó ¡£
6. ³¬ ......