ÔÚLinuxÏÂÓÃbuildroot´î½¨mips/armµÄ½»²æ±àÒëƽ̨
ÔÚLinuxÏÂÓÃbuildroot´î½¨mips/armµÄ½»²æ±àÒëƽ̨
Õâ¸ö±àÒë»·¾³ÊDz»ÄܱàÒëfor¿ªÔ´ÎÞÏß·ÓÉÆ÷µÄ³ÌÐòµÄ£¬ÒòΪÄÚºËÊÇ2.6µÄ
½¨Òé²Î¿¼Õâƪ: http://www.felix021.com/blog/read.php?1467
Ç°Á½ÌìÂòÁËNetGear WRT614 V9£¬´îÔصÄÊÇBroadcomµÄ200MHz MIPS´¦ÀíÆ÷¡£
ÓÉÓÚʹÓõÄÊÇ¿ªÔ´²Ù×÷ϵͳLinux£¬ËùÒÔ¿ÉÒÔË¢ÍøÉÏһЩNBµÄ¹Ì¼þ£¬±ÈÈçdd-wrt, tomato, openwrt ...
ÓÚÊǾö¶¨°ÑÎä´óУ԰ÍøµÄnewstar ( feliciaÐÞ¸Ä×ÔsuperstarÐÞ¸Ä×Ômystar ) ¼¯³É½øÈ¥¡£
ÏëÒª×Ô¼º±àÒënewstar£¬¾Í±ØÐë´î½¨Ò»¸ö½»²æ±àÒë(cross-compile)ƽ̨
Ò²ÓÐÒ»ÖÖ˵·¨ÊÇcross compile toochain£¬½»²æ±àÒ빤¾ßÁ´
·´ÕýÒ»¸öÒâ˼£º¾ÍÊÇÄÜÔÚÄãÏÖÔÚÓõĻúÆ÷ÉÏ(Ò»°ãÊÇx86)±àÒë³ömips¼Ü¹¹µÄÄ¿±ê´úÂ룬ºÜNB¡£
ÍøÉÏËÑÁËһϣ¬·¢ÏÖÓÐÒ»¸öºÃ¶«Î÷°¢£¬ËüµÄÃû×ÖÊÇbuildroot
Ëü°ÑÖÆ×÷½»²æ¹¤¾ßÁ´µÄÕû¸ö¹ý³Ì¶¼°ü¸ÉÁË£¬ÄãֻҪѡÔñÄãÏëҪʲô¶«Î÷¾ÍºÃÁË
Ïêϸ½éÉܺÍʹÓüû http://buildroot.uclibc.org/buildroot.html
ÏÂÃæÊÇÎҵĴ¹ý³Ì£º
0. ÏÈ°²×°ÐèÒª°²×°µÄ¶«Î÷
°üÀ¨£º build-essential bison flex ...
# sudo apt-get install build-essential bison flex
1. ÏÂÔØbuildroot
ÎÒÏÂÔصÄÊÇ×îеİ汾
http://buildroot.uclibc.org/downloads/snapshots/buildroot-snapshot.tar.bz2
µ±È»ÄãÒ²¿ÉÒÔÔÚÕâÀïÕÒÔçÆڵİ汾 http://buildroot.uclibc.org/downloads/snapshots/
ÎÒ°ÑËü·ÅÔÚÁË /cross Õâ¸öĿ¼ÏÂÃ棬Äã¿ÉÒÔ×Ô¼ºÑ¡Ôñ£¬µ«ÊÇÏÂÃ涼ÒÔ /cross ΪÀý¡£
2. ´ò¿ªterminal£¬½âѹbuildroot
# su root //È»ºóÊäÈëÃÜÂë
# mkdir /cross
# cd /cross
# mv /{Äã°ÑËü·ÅÔÚÄÄÀïÁË?}/buildroot-snapshot.tar.bz2 ./
# tar jxvf buildroot-snapshot.tar.bz2 //µÃµ½ /cross/buildroot Ŀ¼
# cd buildroot
3. ÅäÖÃÄãÐèÒªµÄ¶«Î÷
# make menuconfig //È»ºó¿´µ½ÁËÊìϤµÄ½çÃæÁË°É¡«¡«ºÍ±àÒëKernelµÄÒ»ÑùàÞ¡«¡«
ÔÚTarget ArchitectureÀïÃ棬ѡÔñMIPS (µ±È»£¬ÄãÒ²¿ÉÒÔÑ¡ÔñARM£¬ÏÂÃ滹ÊÇÒÔMIPSΪÀý =.=)
ÔÚToolchainÀïÃæÑ¡ÉÏÄãÐèÒªµÄ±àÒ빤¾ß£¬±ÈÈçg++(±àÒënewstarÐèÒªg++)£¬ÊÇ
[ ] Build/install c++ compiler and libstdc++?
Òƶ¯µ½ÉÏÃ棬°´Ò»Ï¿ոñ£¬¾Í»á±ä³É
[*] Build/install c++ compiler and libstdc++?
È«²¿È·¶¨OKÒÔºóÑ¡ÔñExit£¬µã»÷YES£¬³ÌÐò»á×Ô¶¯Éú³ÉÒ»¸ö.configÎļþ
p.s. ½¨Òé²»Òª¼ÓÈë¶Ôjffs2µÄÖ§³Ö(ĬÈÏûÓÐ)£¬ÒòΪÎÒÕâÀï³öÏÖ±àÒë´íÎó£¬Óиöº¯Êýû
Ïà¹ØÎĵµ£º
×÷Õߣº±±ÄÏÄϱ±
ÔÞÖú£º
À´×Ô£ºLinuxSir.Org
ÕªÒª£º ±¾ÎÄÖ÷Òª½éÉÜLinuxϵͳµÄÓû§ºÍÓû§×éµÄ²éѯ¡¢Ìí¼Ó¡¢Ð޸ļ°É¾³ýµÈ¹ÜÀí¹¤¾ß£»
1¡¢/etc/passwd ºÍ/etc/groups
2¡¢³¬¼¶È¨ÏÞ¿ØÖÆ sudo µÄÅäÖÃÎļþ/etc/sudoers £»
3¡¢Ìí¼ÓÓû§¹æÔòÎļþ /etc/login.defs ºÍ /etc/default/useradd
1¡¢useradd ¹¤¾ß£»
1.1¡¢u ......
ÖÚËùÖÜÖª£¬LinuxµÄÎļþȨÏÞÈç:
777;666µÈ£¬ÆäʵֻҪÔÚÏàÓ¦µÄÎļþÉϼÓÉÏUIDµÄȨÏÞ£¬¾Í¿ÉÒÔÓõ½¼ÓȨÏÞÈ˵ÄÉí·ÝÈ¥ÔËÐÐÕâ¸öÎļþ¡£ËùÒÔÎÒÃÇÖ»ÐèÒª½«bash¸´ÖƳöÀ´µ½ÁíÒ»¸öµØ·½£¬
È»ºóÓÃroot¼ÓÉÏUIDȨÏÞ£¬Ö»ÒªÓû§ÔËÐдËShell¾Í¿ÉÒÔÓÃÓÃrootµÄÉí·ÝÀ´Ö´ÐÐÈκÎÎļþÁË¡£
£±.LinuxÏÂÈçºÎÖªµÀij¸ö¶Ë¿ÚÔÚÔËÐÐʲô³ÌÐò
µ±ÎÒÃÇÓ ......
ÈçºÎÔÚlinuxϲ鿴µ±Ç°µÇ¼µÄÓû§£¬²¢ÇÒÌßµôÄãÈÏΪӦ¸ÃÌßµôµÄÓû§£¿
¿´ÁËÍøÂçÖеÄһЩÀý×Ó.ÔÚÕâÀï×ܽáÒ»ÏÂ.Ö÷ÒªÓõ½µÄÃüÁîÓÐ,w,who,ps,kill,pkill
²é¿´µ±Ç°µÇ¼Óû§:
node8:/home # who
root :0 2009-11-04 16:26
root pts/0 &n ......
1¡¢¼òµ¥²âÊÔʵÀý
for i in `find . -type f -name "*.c"`
do
echo $i
basename $i »ñÈ¡*.cÎļþÃû
dirname $i »ñÈ¡*.c¶ÔÓ¦µÄĿ¼Ãû
done
2¡¢Êµ¼ÊÓ¦ÓÃ
diff LinuxÔ´Â룬²¢½«Óв»Ò»ÑùµÄÔ´ÂëÕûÀíÔÚÒ»Æð£¬ÒªÇó£ºÎļþ ......