Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

linux ϶¯Ì¬¿â¡¢¾²Ì¬¿âǶÌ×ʹÓÃ

linuxϾ²Ì¬¿âǶÌ×ʹÓÃ
ǰÌáÊÇÄã»áÔÚlinuxϵ÷Óþ²Ì¬¿âºÍ¶¯Ì¬¿âºÍMakfile±à³Ì(µ±È»²»»áMakfileÖ±½ÓÔÚÖÕ¶ËÃüÁîÒ²³É)
±¾ÀýÊÇÏÈÓÉStringLen.h,StringLen.cÉú³Élibrak.a
È»ºóÀûÓÃStringLen2.h£¬StringLen2.²¢µ÷ÓÃlibrak.aÉú³Élibrak2.a
×îºóÀûÓÃStringLen3.h,StringLen3.cµ÷ÓÃlibrak2.a Éú³Élibrak3.so
--------------------------------------------------------------------------------------
#StringLen.h:
#ifndef _STRINGLEN_H__
#define _STRINGLEN_H__
int Strlen(char *pStr);
#endif
#StringLen.c:
#include<stdio.h>
#include<assert.h>
#include "StringLen.h"
int  Strlen(char  *pStr)
{        
    unsigned  long  ulLength;
    assert(NULL  !=  pStr);
    ulLength  =  0;
    while(*pStr++)
    {                
        ulLength++;
    }
    return  ulLength;
}
gcc -Wall -c *.c
ar rc librak.a *.o
------------------------------------------------------------------------------------
#StringLen2.h:
#ifndef _STRINGLEN_H2__
#define _STRINGLEN_H2__
#ifdef __UDT
#include "StringLen.h"
#endif
int Strlen2(char *pStr);
#endif
#StringLen2.c:
#include<stdio.h>
#include<assert.h>
#include "StringLen2.h"
int  Strlen2(char *pStr)
{        
    unsigned  long  ulLength;
    #ifdef __UDT
    ulLength  =  Strlen(pStr);
    #else
        ulLength = -1;
    #endif
   
    return  ulLength;
}
gcc -Wall -c *.c -D__UDT
ar rc librak2.a *.o
------------------------------------------------------------------------------------


Ïà¹ØÎĵµ£º

Linux Äں˱à³Ìѧϰ


Linux 
Äں˱à³Ìѧϰ
³£³£ÓÐÈËÎÊ£ºÎÒÏëѧϰÄںˣ¬ÐèҪʲô»ù´¡Âð£¿Linus Torvalds
±¾ÈËÊÇÕâÑù»Ø´ðµÄ£ºÄã±ØÐëʹÓùý
Linux
¡£ Õâ¸ö
……
»¹ÊÇÓеãÌ«·ºÁ˰ɣ¬ÎÒÏëÏÂÃæ¼¸¸ö»ù´¡¿ÉÄÜ»¹ÊÇÐèÒªµÄ£¬¾¡¹Ü²»Ò»¶¨±ØÐ裺
1, ¹ØÓÚ²Ù×÷ϵͳÀíÂÛµÄ×î³õ¼¶µÄ֪ʶ¡£²»ÐèҪͨ¶Á²¢Àí½â¡¶²Ù×÷ϵͳ¸ÅÄ ......

½«Linux´úÂëÒÆÖ²µ½WindowsµÄ¼òµ¥·½·¨(1)

Ò»£®Ç°ÑÔ
¡¡¡¡LinuxÓµÓзḻ¸÷ÖÖÔ´´úÂë×ÊÔ´,µ«ÊǴ󲿷ִúÂëÔÚWindowsƽ̨Çé¿öÊÇÎÞ·¨Õý³£±àÒëµÄ¡£Windowsƽ̨¸ù±¾ÎÞ·¨Ö±½ÓÀûÓÃÕâЩԴ´úÂë×ÊÔ´¡£Èç¹ûÏëҪʹÓÃÍêÕûµÄ´úÂ룬¾ÍÒª×öÒÆÖ²¹¤×÷¡£ÒòΪC/C++ LibraryµÄ²»Í¬ºÍÆäËûµÄһЩԭÒò£¬ÒÆÖ²C/C++´úÂëÊÇÒ»ÏîÀ§ÄѵŤ×÷¡£±¾ÎĽ«ÒÔÒ»¸öʵ¼ÊµÄÀý×Ó£¨Tar£©À´ËµÃ÷ÈçºÎ°ÑLinux´úÂëÒÆÖ² ......

Linux»»ÐÐÎÊÌâ

WindowsÓëLinuxÖеĻ»ÐÐÊDz»Ò»ÑùµÄ£¬ÒѾ­Óöµ½¹ýºÃ¼¸´ÎÎÊÌâÁË¡«ÅúÁ¿Ð½¨Óû§µÄʱºò£¬ÐÂÓû§²»ÄܵǼ£¬ÒòΪÎÒµÄÎı¾ÊÇÔÚWindowsÏÂÉú³ÉµÄ£¬»»ÐÐÊÇWindows¸ñʽ£¬¶øLinuxÖÐʹÓÃnewusersÃüÁîµ¼Èëµ½passwdÎļþ£¬ÊÇÖ±½Ó¸´ÖƹýÈ¥µÄ¡«²»ÄÜÒ»ÐÐÒ»Ðеĸİ¡¡«ºÇºÇ£¬¸Õ¸Õѧµ½ÁËÒ»ÕС£
×Ö·ûÎļþÔÚÁ½¸öϵͳ֮¼ä¿½±´Ö®ºó£¬¿ÉÒÔʹÓÃdos2unix» ......

Linux I2CºËÐÄ¡¢×ÜÏßÓëÉ豸Çý¶¯

Linux I2CºËÐÄ¡¢×ÜÏßÓëÉ豸Çý¶¯
×¢:
 ÔÚlinux2.6.32°æ±¾ÖÐÓÐÕâÑùµÄ´úÂëÓë×¢ÊÍ:
struct i2c_driver {
    unsigned int class;
    /* Notifies the driver that a new bus has appeared or is about to be
     * removed. You should avoid using this if y ......

linux±àÒë³öÏÖ´íÎó

ÒýÓãºhttp://blog.chinaunix.net/u/12207/showart_2061214.html
¹ØÓÚ2.6.31Óöµ½µÄÎÊÌâ
´íÎóÌáʾ1£º
drivers/built-in.o(.init.text+0x3bad): In function `con_init':
include/trace/events/kmem.h:47: undefined reference to `.L1452'
½â¾ö£º
vi /usr/src/linux/drivers/char/vt.c ÕÒµ½static int __init con_init ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ