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

dz̸LinuxµÄ¿ÉÖ´ÐÐÎļþ¸ñʽELF

 ÏÖ´úLinux²ÉÓÃELF×öΪÆä¿ÉÁ¬½ÓºÍ¿ÉÖ´ÐÐÎļþµÄ¸ñʽ£¬Òò´ËELF¸ñʽҲÏòÎÒÃÇ͸³öÁËÒ»µãLinuxºËÄÚµÄÇé¾°£¬¾ÍÏñϷ̨άĻÁôϵÄÒ»ÌõδÀ­Ñϵķ졣PCÊÀ½ç32ÈÔÊÇÖ÷Á÷£¬µ«64λµÄ½Å²½È´ÒÑÈç´ËµÄ±Æ½ü¡£±¾ÎÄ×ÅÖؽ²Êö32λELFµÄͬʱ¸½´øÁË64λµÄÐÅÏ¢£¬ÕâÁ½ÖÖ¸ñʽÈç´ËÀ×ͬ£¬ÒÔÖÂÓÚ³õ´Î½Ó´¥ELFµÄ¶ÁÕß²»±Ø¼æ¹Ë×óÓÒ¡£Èç¹ûÄã¶ÔWindows±È½ÏÊìϤ£¬±¾ÎÄ»¹½«Ê±Ê±°ÑÄã´ø»Øµ½PEÖУ¬ÔÚËüÃǵÄÏàËÆÖ®´¦ÉÔ×ö±È½Ï¡£ELFÎļþÒÔ“ELFÍ·”¿ªÊ¼£¬ºóÃæ¿ÉÑ¡ÔñµÄ¸úËæ×ųÌÐòÍ·ºÍ½ÚÍ·¡£µØÀíѧÓõȸßÏßÓëµÈÎÂÏß·Ö±ðչʾͬһµØÇøµÄµØÊƺÍÆøºò£¬³ÌÐòÍ·ºÍ½ÚÍ·Ôò·Ö±ð´Ó¼ÓÔØÓëÁ¬½Ó½Ç¶ÈÀ´ÃèÊöEFLÎļþµÄ×éÖ¯·½Ê½¡£ÏÂÃæÎÒÃǽøÈëÕýÎÄ¡£
Ò»¡¢ELFÍ·
    ELFÍ·Ò²½ÐELFÎļþÍ·£¬ËüλÓÚÎļþÖÐ×ʼµÄµØ·½¡£ÎÒÓÃϵͳµÄÊÇFedora Core 2£¬ËüÔÚelf.hÎļþÖÐͬʱ¸ø³öÁËELFÍ·ÔÚ32λϵͳºÍ64λϵͳϵĽṹ£¬ÎÒÃÇÏÈÀ´¿´Ò»Ï£º
typedef struct
{
unsigned char e_ident[EI_NIDENT];
Elf32_Half e_type;
Elf32_Half e_machine;
Elf32_Word e_version;
Elf32_Addr e_entry;
Elf32_Off e_phoff;
Elf32_Off e_shoff;
Elf32_Word e_flags;
Elf32_Half e_ehsize;
Elf32_Half e_phentsize;
Elf32_Half e_phnum;
Elf32_Half e_shentsize;
Elf32_Half e_shnum;
Elf32_Half e_shstrndx;
} Elf32_Ehdr;
typedef struct
{
unsigned char e_ident[EI_NIDENT];
Elf64_Half e_type;
Elf64_Half e_machine;
Elf64_Word e_version;
Elf64_Addr e_entry;
Elf64_Off e_phoff;
Elf64_Off e_shoff;
Elf64_Word e_flags;
Elf64_Half e_ehsize;
Elf64_Half e_phentsize;
Elf64_Half e_phnum;
Elf64_Half e_shentsize;
Elf64_Half e_shnum;
Elf64_Half e_shstrndx;
} Elf64_Ehdr;
    elf.hÖйØÓÚELF¸ñʽËùÓнṹ¸ø³öµÄ¶¨Ò壬Æä³ÉÔ±×ֶεÄÀàÐÍÉùÃû¶¼ÊÇCÓïÑÔ»ù±¾ÀàÐ͵ıðÃû£¬²»»áÔÙǶÌ׽ṹ¡£¿ÉÒÔ¿´³ö32λϵͳºÍ64λϵͳÏÂELFÍ·µÄ½á¹¹»ù±¾Ïàͬ£¬²»Í¬µÄÊÇÁ½ÖֽṹÖеÄij¸ö³ÉÔ±×Ö¶ÎÕ¼ÓÃ×Ö½Ú¸öÊýÓÐËù±ä»¯¡£±ÈÈçe_entryÓÉ32λÏÂÕ¼4¸ö×Ö½ÚµÄElf32_Addr±äΪ64λÏÂÕ¼8¸ö×Ö½ÚµÄElf64_Addr£¬ÕâÊÇÒòΪÁ½ÖÖϵͳÏÂCPUÑ°Ö·ÄÜÁ¦²»Í¬Ôì³ÉµÄ¡£Í¬ÀíÎļþÆ«ÒÆÒ²´Ó4×Ö½ÚµÄElf32_Off±äΪ8×Ö½ÚµÄElf64_Off¡£ÓÐЩ³ÉÔ±×Ö¶ÎËäÈ»ÀàÐÍÉùÃû´ÓElf32_XXXX±ä³ÉÁËElf64_XXXX£¬¸ÃÓòËùÕ¼µÄ×Ö½Ú¸öÊý²¢Î´¸Ä±ä¡£ÈçElf32_HalfºÍElf64_Half¶¼Õ¼Á½¸ö×Ö½Ú£¬Elf32_Word¡¢Elf3


Ïà¹ØÎĵµ£º

ʵսLinux Bluetooth±à³Ì£¨Èý£© HCI²ã±à³Ì

1. HCI²ãЭÒé¸ÅÊö£º
HCIÌṩһÌ×ͳһµÄ·½·¨À´·ÃÎÊBluetoothµ×²ã¡£ÈçͼËùʾ£º
´ÓͼÉÏ¿ÉÒÔ¿´³ö£¬Host Controller Interface(HCI)  ¾ÍÊÇÓÃÀ´¹µÍ¨HostºÍModule¡£Hostͨ³£¾ÍÊÇPC£¬ ModuleÔòÊÇÒÔ¸÷ÖÖÎïÀíÁ¬½ÓÐÎʽ£¨USB,serial,pc-cardµÈ£©Á¬½Óµ½PCÉϵÄbluetooth Dongle¡£
ÔÚHostÕâÒ»¶Ë£ºapplication,SDP,L2capµÈЭÒé ......

[תÌû]LinuxÇý¶¯¿ª·¢Ñ§Ï°µÄһЩ±ØÒª²½Öè

 1. ѧ»áд¼òµ¥µÄmakefile
2. ±àһЩӦÓÃ
³ÌÐò
£¬¿ÉÒÔÓÃmakefileÅÜÆðÀ´
3. ѧ»áдÇý¶¯
µÄmakefile
4. дһ¼òµ¥charÇý¶¯£¬makefile±àÒëͨ¹ý£¬¿ÉÒÔinsmod£¬ lsmod£¬ rmmod. ÔÚÇý¶¯µÄinitº¯ÊýÀï´òÓ¡hello world£¬insmodºóÓ¦¸ÃÄܹ»Í¨¹ýdmesg¿´µ½Êä³ö
¡£
5. дһÍêÕûÇý¶¯£¬ ¼ÓÉÏread£¬ write£¬ ioctl£¬ pollingµÈ¸ ......

LinuxÖÐJDK1.6µÄ°²×°ºÍÅäÖ÷½·¨


Ò»¡¢°²×°
´´½¨°²×°Ä¿Â¼£¬ÔÚ/usr/local/javaϽ¨Á¢°²×°Â·¾¶£¬²¢½«Îļþ¿¼µ½¸Ã·¾¶Ï£º 
# mkdir /usr/local/java
1¡¢jdk-6u11-linux-i586.bin
Õâ¸öÊÇ×Ô½âѹµÄÎļþ£¬ÔÚlinuxÉÏ°²×°ÈçÏ£º 
# chmod 755 jdk-6u11-linux-i586.bin 
# ./jdk-6u11-linux-i586.bin
ÔÚ°´ÌáʾÊäÈëyesºó£¬jdk±»½âѹ¡£
......

ÈçºÎʵÏÖLinuxÎı¾Ä£Ê½ÏÂ×Ô¶¯¹ÒÔعâÇý

ÈçºÎʵÏÖLinuxÎı¾Ä£Ê½ÏÂ×Ô¶¯¹ÒÔعâÇý
http://blog.csdn.net/yzlworld/archive/2009/06/29/4307476.aspx
mountÊÇÓÃÀ´¹ÒÔØÎļþϵͳµÄ£¬¿ÉÒÔÔÚÆô¶¯µÄʱºò¹ÒÔØÒ²¿ÉÒÔÔÚÆô¶¯ºó¹ÒÔØ¡£ÔÚÆô¶¯ºó¹ÒÔØ¿ÉÒÔʹÓÃmountÃüÁîʵÏÖ£¬ÒªÊµÏÖÆô¶¯Ê±×Ô¶¯¹ÒÔØÉ豸ÔòÐèÆô¶¯autofs·þÎñ¾ÍÌṩÕâÖÖ¹¦ÄÜ¡£¸Ã¹¦ÄܾÍÏñwindowsÖеĹâÇý×Ô¶¯´ò¿ª¹¦ÄÜ£¬Ä ......

LinuxÉϵÄÐéÄ⻯¼¼Êõ


ÐéÄ⻯¼¼ÊõµÄ·½·¨, ¼Ü¹¹ºÍʵÏÖ¸ÅÀÀ
¼¶±ð: Öм¶
M. Tim Jones [mtj@mtjones.com], ¹ËÎʹ¤³Ìʦ, Emulex
Ô­ÎÄ: Virtual Linux
Òë: ÕÔçæ cn.zhaoke.com
http://blog.zhaoke.com/45.html
2006Äê12ÔÂ29ÈÕ
ÐéÄ⻯¼¼ÊõµÄÓ¦ÓÃÊ®·Ö¹ã·º. µ±Ç°ÐéÄ⻯¼¼ÊõÖ÷Òª¹Ø×¢ÓÚ·þÎñÆ÷µÄÐéÄ⻯, »òÔÚµ¥¸öÖ÷»úÉϼĴæ¶à¸ö¶ÀÁ¢µÄ²Ù×÷ϵͳ. ±¾Î ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ