像我儿子一样永远保持好奇和梦想

【读书笔记0102】Beginning linux programming-3rd

上一篇 / 下一篇  2011-12-21 10:27:37 / 心情: 平静 / 个人分类:linux

Chapter 1: getting start
7O|0u Tl|AKi0任何一本书都不可能适合任何人,这本书适合没有任何linux经验的C程序员ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台 C1cw$|`)n/? ws]-K0e

这章主要是介绍了unix linux gun的发展历史,
*s3@$bVh ~P)^w5~y0Unix is a trademark by The Open Group and source code belongs to SCO.ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台fKB"|+I9Z
Unix phliosophy: The why we choose Unix.有点老掉牙的话题
o3x|Uyh m&I0这本书讲的却非常精辟:
Hw{K-y&f_6J1D01 what is Simplicity,ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台jR!\LL^Z+X
Small&simple in utilites
R G TX)G]IaPr02 Focus,ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台7|O;RG~"Xmv6G [
It means,from the requirement ,we first break down the user needs.Then we try very small utilites which combined to perform. a single purpose so that easy to perform. and improve later for the better algorithms and interface.
(p+Tg+xc u0t;|Ss03 Reusable,ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台j7L?$E0q!EeK
To realize the reusable,you should have the ability to find out the core of your applications. then make it a lib.ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台5rdAqN
And you should well documented with simple but flexible programming interface to helps others programmer.
u$_/S.reI A We04 Filters,
r0C9lf8tjp_0Filter is just transform. input and output ,to helps combining the programs.ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台Sf2e!t1G+aDx
5 Openfileformat
N9n[H9[9r HHY06 Flexibility:
7|*zx:Yag6t:k0is for the ingeniously users , never assume that user might want to do.ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台m;OU5g:H@/U8k!I
avoid arbitrary limits on field size,numbers limitation ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台 U`-zTs

Remember the famous name:AT&T,Linus Torvalds,Helsinki,Richard Stallman on GNU,Dennis Ritchie,ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台^0J _&c\)y&V$V'o.[

Programming Linux
,[$p6{|a01 Linux programs: two special typs: executables and scripts:
Nl c-j/l u0these two type can replace each other vice versa.
+O4Ai \[!gMAP d4u0
What the tips I learn form. this charpter:
8}OS8ww01  / forward slash ,remember the UNIX got the first, the DOS not.ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台8?OSRY9P
2  C compiler C89
-wnP2H*qf8y03  emacs is a important editor in linux
#?k rx0Zg5]XX04  ./  what that meansET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台Arl3n&J*E3G
5  the RoadMap actually -- where the tools and development resources are located.
l Y.M\ i(m/PS*Mo0ok,这是个入门的重点:那就是知道linux是如何组织和应用各个应用和工具的:默认路径,这个往往是初学者不知道的东西:ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台KoJS)k
general applications: /usr/bin
dI;Pmz2qT.b`0administrator specific: /usr/local/bin  or /optET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台BRp'J{3e H|
usr/local will not remove while you reinstall the OSET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台Df3l1[9ise {
ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台n8hP9L Hkv,t\
You need to know the applications /include header files/ and the library files.
e'd8x#f7VBm0
Some very useful flags for:
$rb!Ki a#G0-I (uppercase letter for "i")  used for libs include path
r0[L1wL#\-Z0-l (lowercase letter for "L")  find a lib's full path and name standard lib path. eg. -lm include a math libs in standard path
E s/w)Ql"V0-L  add search directory , if not specify then it means just in current directory.ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台kh-?Y1qj1bL^A E

how to generate a lib and use
acRe3m&Q.X01 use -C while we compile the program:
|;^ X0k\6CnO \02 use ar to creat a archive
'm"fQ+~ G"XsG x,E0
then chapter said how a shared libraries are works ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台 cQ"bOdgj

Getting helps show us the basic help method:
*? L'GK,Ox `'a/V01 man
:~PAnz02 infoET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台'V E[+D?G;C
3 help  eg: used in bash shell:ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台(D3G7E3GO)_:G
help setET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台)Wk.H\r.zL

r p?B*Hj5{4K,T0
.P5ew StA!`B(b0ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台X)IQ-CP
ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台0}8E _Zk|&x
ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台.x2CX3kDT1dnMf
ET创芯网(EETOP)-电子设计论坛、博客、超人气的电子工程师资料分享平台9u U-tnW UDX vYo

TAG: linux Linux LINUX 读书笔记

 

评分:0

我来说两句

显示全部

:loveliness: :handshake :victory: :funk: :time: :kiss: :call: :hug: :lol :'( :Q :L ;P :$ :P :o :@ :D :( :)

Open Toolbar