<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-7009751233469405122</id><updated>2024-09-08T08:39:03.072-07:00</updated><title type='text'>Joe&#39;s Notepad</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>40</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-2288345738189422917</id><published>2019-04-29T02:55:00.000-07:00</published><updated>2019-04-29T02:55:06.603-07:00</updated><title type='text'>CIFAR load and save to picture</title><content type='html'>import pickle as p&lt;br /&gt;
import numpy as np&lt;br /&gt;
from PIL import Image&lt;br /&gt;
import os&lt;br /&gt;
&lt;br /&gt;
def unpickle(file):&lt;br /&gt;
&amp;nbsp; &amp;nbsp; with open(file, &#39;rb&#39;) as fo:&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; dict = p.load(fo, encoding=&#39;bytes&#39;)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; return dict&lt;br /&gt;
&lt;br /&gt;
&#39;&#39;&#39;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; batch file key:&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; b&#39;batch_label&#39;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; b&#39;labels&#39;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; b&#39;data&#39;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; b&#39;filenames&#39;&lt;br /&gt;
&#39;&#39;&#39;&lt;br /&gt;
CIFAR10PATH = &quot;E:\\project\\python\\cifar10\\cifar-10-batches-py\\&quot;&lt;br /&gt;
DATABATCH = &quot;data_batch_&quot;&lt;br /&gt;
OUTPUTFOLDER = &quot;.\\images\\&quot;&lt;br /&gt;
#E:\project\python\cifar10\cifar-10-batches-py&lt;br /&gt;
if __name__ == &quot;__main__&quot;:&lt;br /&gt;
&amp;nbsp; &amp;nbsp; for i in range(1,2):&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; batchName = CIFAR10PATH + DATABATCH+str(i)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; print(&quot;batch name:&quot;+str(batchName))&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; cifar = unpickle(batchName)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; for d in range(10000):&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; labelNum = cifar[b&#39;labels&#39;][d]&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; imgData = cifar[b&#39;data&#39;][d]&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; #remove utf-8 name with b&#39;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; filenames = cifar[b&#39;filenames&#39;][d].decode(&quot;utf-8&quot;)&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; #If the dimension with length 3 is the RGB axis, then you want it at the end.&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; #If your array has shape (3, R, C), then np.transpose(img, (1, 2, 0))&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; #will have shape (R, C, 3).&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; imgData = imgData.reshape(3, 32, 32) #CIFAR default format 3 channels with RxC&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; #(0, 1, 2) no change (3, R, C) ==&amp;gt; transpose to (1, 2, 0) =&amp;gt; (R, C, 3)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; imgData = imgData.transpose(1, 2, 0)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; img = Image.fromarray(imgData, &#39;RGB&#39;)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; folderName = OUTPUTFOLDER + str(labelNum)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if not os.path.exists(folderName):&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; os.makedirs(folderName)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; img.save(folderName+&quot;\\&quot;+str(filenames).strip()+&#39;.jpg&#39;)&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/2288345738189422917/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2019/04/cifar-load-and-save-to-picture.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/2288345738189422917'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/2288345738189422917'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2019/04/cifar-load-and-save-to-picture.html' title='CIFAR load and save to picture'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-442921612415652096</id><published>2017-11-15T08:46:00.000-08:00</published><updated>2017-11-15T08:46:04.366-08:00</updated><title type='text'>android trace</title><content type='html'>traceView -&amp;gt; for app&lt;br /&gt;
&lt;br /&gt;
systrace -&amp;gt;focus on kernel ftrace(surfaceflinger, )&lt;br /&gt;
https://kknews.cc/zh-tw/news/enbv3on.html&lt;br /&gt;
kernel -&amp;gt; ftrace,&amp;nbsp; app-&amp;gt; trace class&lt;br /&gt;
/tools/systrace.py&lt;br /&gt;
&lt;br /&gt;
追到app問題後，也要使用traceView來協助分析</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/442921612415652096/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2017/11/android-trace.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/442921612415652096'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/442921612415652096'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2017/11/android-trace.html' title='android trace'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-1373398344893921846</id><published>2017-09-27T07:26:00.001-07:00</published><updated>2017-09-27T07:26:16.044-07:00</updated><title type='text'>mt.exe 停止運作 MSB6006</title><content type='html'>vs2010&lt;br /&gt;
&lt;br /&gt;
Property -&amp;gt; linker -&amp;gt; Manifest File -&amp;gt; Generate Manifest -&amp;gt; No(Manifest:No)</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/1373398344893921846/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2017/09/mtexe-msb6006.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/1373398344893921846'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/1373398344893921846'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2017/09/mtexe-msb6006.html' title='mt.exe 停止運作 MSB6006'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-1417206999273053758</id><published>2017-09-20T10:05:00.000-07:00</published><updated>2017-09-25T19:15:12.394-07:00</updated><title type='text'>arduino avrdude upload hex file by command</title><content type='html'>Arduino Uno&lt;br /&gt;
&lt;br /&gt;
avrdude -c arduino -P com4 -b 115200 -p ATMEGA328p -U flash:w:camBox.ino.hex&lt;br /&gt;
or&lt;br /&gt;
avrdude -c arduino -P com4 -b 115200 -p m328p -U flash:w:camBox.ino.hex&lt;br /&gt;
or&lt;br /&gt;
avrdude -c arduino -P com4 -b 115200 -p ATMEGA328p -U flash:w:E:\camBox.ino.hex:i&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Arduino Mega&lt;br /&gt;
&lt;br /&gt;
avrdude -c wiring -P com4 -b 115200 -p m2560 -U flash:w:camBox.ino.hex&lt;br /&gt;
&lt;br /&gt;
avrdude -c wiring&amp;nbsp;-P com4 -b 115200 -p&amp;nbsp;&lt;span style=&quot;background-color: white;&quot;&gt;ATmega2560&amp;nbsp;&lt;/span&gt;-U flash:w:E:\camBox.ino.hex:i&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
partno list&lt;br /&gt;
http://www.nongnu.org/avrdude/user-manual/avrdude_4.html&lt;br /&gt;
&lt;br /&gt;
or see the avrdude.conf&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/1417206999273053758/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2017/09/arduino-avrdude-upload-hex-file-by.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/1417206999273053758'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/1417206999273053758'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2017/09/arduino-avrdude-upload-hex-file-by.html' title='arduino avrdude upload hex file by command'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-8734666583818135487</id><published>2016-12-29T18:14:00.001-08:00</published><updated>2016-12-29T18:14:37.804-08:00</updated><title type='text'>步進馬達</title><content type='html'>幾相幾線?&lt;br /&gt;
&lt;br /&gt;
相:最直接影響的是 精度，越多相，精度越細&lt;br /&gt;
兩相: 激磁後，1.8DEG&lt;br /&gt;
&lt;br /&gt;
線:最直接影響就是unipolar or bi-polar, 單電流激磁，按照順序即可順轉反轉&lt;br /&gt;
雙電流則，電留有方向性來控制正反轉&lt;br /&gt;
&lt;br /&gt;
驅動IC:ULN2003，7組達靈頓電路，可以將每組並聯使用，放大驅動電流來達到驅動基本電流的需求</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/8734666583818135487/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2016/12/blog-post.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/8734666583818135487'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/8734666583818135487'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2016/12/blog-post.html' title='步進馬達'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-4433591506408038657</id><published>2016-02-18T00:31:00.002-08:00</published><updated>2016-02-18T00:31:33.658-08:00</updated><title type='text'>adb lauch each app from android</title><content type='html'>adb shell pm list package -f&lt;br /&gt;
adb shell pm list package #list all package&lt;br /&gt;
&lt;br /&gt;
launch each package by monkey&lt;br /&gt;
&lt;pre class=&quot;default prettyprint prettyprinted&quot; style=&quot;background-color: #eeeeee; border: 0px; color: #393318; font-family: Consolas, Menlo, Monaco, &#39;Lucida Console&#39;, &#39;Liberation Mono&#39;, &#39;DejaVu Sans Mono&#39;, &#39;Bitstream Vera Sans Mono&#39;, &#39;Courier New&#39;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &#39;Lucida Console&#39;, &#39;Liberation Mono&#39;, &#39;DejaVu Sans Mono&#39;, &#39;Bitstream Vera Sans Mono&#39;, &#39;Courier New&#39;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;adb shell monkey &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;p $&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;package_name&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;c android&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;intent&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;category&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;LAUNCHER &lt;/span&gt;&lt;span class=&quot;lit&quot; style=&quot;border: 0px; color: maroon; margin: 0px; padding: 0px;&quot;&gt;1&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: black; margin: 0px; padding: 0px;&quot;&gt;;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/4433591506408038657/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2016/02/adb-lauch-each-app-from-android.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/4433591506408038657'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/4433591506408038657'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2016/02/adb-lauch-each-app-from-android.html' title='adb lauch each app from android'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-4760187529089578751</id><published>2016-02-08T07:31:00.000-08:00</published><updated>2016-06-04T20:07:21.099-07:00</updated><title type='text'>github usage note</title><content type='html'>github 有個情境&lt;br /&gt;
&lt;br /&gt;
假設要共同開發一個project ex: &amp;nbsp;http://github.com/dev.git&lt;br /&gt;
這時你可以fork 到你的github, 經過開發時間透過pull request，跟夥伴貢獻了不少commit&lt;br /&gt;
&lt;br /&gt;
這時該如何更新最新的version到你fork的git?&lt;br /&gt;
&lt;br /&gt;
first, 先建立一個upstream, 可任意命名，就稱upstream吧&lt;br /&gt;
&lt;br /&gt;
git remote add upstream http://github.com/dev.git&lt;br /&gt;
&lt;br /&gt;
then, fetch remote, git remote -v --可以看origin 跟 remote的 git&lt;br /&gt;
&lt;br /&gt;
git fetch upstream&lt;br /&gt;
git checkout master&lt;br /&gt;
&lt;br /&gt;
這時可以更新你的git by rebase&lt;br /&gt;
git rebase upstream/master&lt;br /&gt;
也可透過merge方式來更新git&lt;br /&gt;
git merge upstream/master&lt;br /&gt;
&lt;br /&gt;
rebase push 到你的git&lt;br /&gt;
git push -f &amp;nbsp;origin master&lt;br /&gt;
&lt;br /&gt;
ref:&lt;br /&gt;
http://stackoverflow.com/questions/7244321/how-to-update-a-github-forked-repository&lt;br /&gt;
&lt;br /&gt;
開發local branch 一陣子後 commit 並merge 成 master&lt;br /&gt;
dev&lt;br /&gt;
master&lt;br /&gt;
git checkout dev&lt;br /&gt;
git commit -a&lt;br /&gt;
git checkout master&lt;br /&gt;
git merge dev&lt;br /&gt;
&lt;br /&gt;
更新upstream 後，merge 到 local dev branch&lt;br /&gt;
git checkout master&lt;br /&gt;
git fetch upstream&lt;br /&gt;
git merge upstream/master&lt;br /&gt;
==&amp;gt; commit to your fork&lt;br /&gt;
git checkout dev&lt;br /&gt;
git merge master&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/4760187529089578751/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2016/02/github-usage-note.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/4760187529089578751'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/4760187529089578751'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2016/02/github-usage-note.html' title='github usage note'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-2050993024199016751</id><published>2015-02-26T09:56:00.000-08:00</published><updated>2015-02-26T09:56:15.816-08:00</updated><title type='text'>C structure on 32bits/64bits compiler</title><content type='html'>64bits C structure alignment = 8&lt;br /&gt;
32Bits C structure alignment &amp;nbsp;= 4&lt;br /&gt;
&lt;br /&gt;
if u have a data which is building by 32Bits CPU and parsing by 64Bits for structure raw data. it is going to face the different compiler issue.&lt;br /&gt;
&lt;br /&gt;
although the data structure can be fixed the compliler pre-process as #pragma pack(1) to avoid this issue but it is not useful on the complex data structure. In this case, sending of data on different OS must flow the popular data format to avoid the structure raw data problem.</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/2050993024199016751/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2015/02/c-structure-on-32bits64bits-compiler.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/2050993024199016751'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/2050993024199016751'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2015/02/c-structure-on-32bits64bits-compiler.html' title='C structure on 32bits/64bits compiler'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-8990892826950281546</id><published>2013-09-26T08:50:00.002-07:00</published><updated>2013-09-26T08:50:25.357-07:00</updated><title type='text'>[XML Parser]building expat example by static prebuilt library</title><content type='html'>expat , free xml parser developed by C, which was made by James Clark.&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
we can download the free source by CVS as below link:&lt;/div&gt;
&lt;div&gt;
&lt;pre&gt;cvs -z3 -d:ext:&lt;i&gt;developername&lt;/i&gt;@expat.cvs.sourceforge.net:/cvsroot/expat co &lt;i&gt;modulename&lt;/i&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;i&gt;
&lt;/i&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; white-space: normal;&quot;&gt;you can download the pre-build win32 library by expat website.&lt;/span&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; white-space: normal;&quot;&gt;
&lt;/span&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;span style=&quot;font-family: Times New Roman;&quot;&gt;&lt;span style=&quot;white-space: normal;&quot;&gt;using VC10 to build expact example by static library. remember that XML_STATIC you must pre-define.&lt;/span&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;span style=&quot;font-family: Times New Roman;&quot;&gt;&lt;span style=&quot;white-space: normal;&quot;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;span style=&quot;font-family: Times New Roman;&quot;&gt;&lt;span style=&quot;white-space: normal;&quot;&gt;the static library is libexpatMT.lib&lt;/span&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/8990892826950281546/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2013/09/xml-parserbuilding-expat-example-by.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/8990892826950281546'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/8990892826950281546'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2013/09/xml-parserbuilding-expat-example-by.html' title='[XML Parser]building expat example by static prebuilt library'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-5275099393920742609</id><published>2013-09-05T00:07:00.002-07:00</published><updated>2013-09-05T00:07:47.734-07:00</updated><title type='text'>build android adb for windows</title><content type='html'>&lt;a href=&quot;http://source.android.com/source/downloading.html&quot;&gt;http://source.android.com/source/downloading.html&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
note that checkout specific branch will make you downloading fast.&lt;br /&gt;
&lt;br /&gt;
I used below command&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&lt;span class=&quot;pln&quot; style=&quot;font-size: 13px; line-height: 19px;&quot;&gt;$ repo init &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600; font-size: 13px; line-height: 19px;&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;font-size: 13px; line-height: 19px;&quot;&gt;u https&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600; font-size: 13px; line-height: 19px;&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000; font-size: 13px; line-height: 19px;&quot;&gt;//android.googlesource.com/platform/manifest -b android-4.2.2_r1&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;com&quot; style=&quot;color: #880000; font-size: 13px; line-height: 19px;&quot;&gt;$ repo -j10 sync&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;com&quot; style=&quot;color: #880000; font-size: 13px; line-height: 19px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style=&quot;color: #880000; font-size: x-small;&quot;&gt;&lt;span style=&quot;line-height: 19px;&quot;&gt;download complete, u should compiler the adb for Linux first&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: #880000; font-size: x-small;&quot;&gt;&lt;span style=&quot;line-height: 19px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span style=&quot;color: #880000; font-size: x-small;&quot;&gt;&lt;span style=&quot;line-height: 19px;&quot;&gt;make -j4 acp adb showcommands&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: #880000; font-size: x-small;&quot;&gt;&lt;span style=&quot;line-height: 19px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span style=&quot;color: #880000; font-size: x-small;&quot;&gt;&lt;span style=&quot;line-height: 19px;&quot;&gt;finish building Linux adb and then u can build for windows.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: #880000; font-size: x-small;&quot;&gt;&lt;span style=&quot;line-height: 19px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span style=&quot;color: #880000; font-size: x-small;&quot;&gt;&lt;span style=&quot;line-height: 19px;&quot;&gt;make -j4 USE_MINGW=y adb&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: #880000; font-size: x-small;&quot;&gt;&lt;span style=&quot;line-height: 19px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;
Install: out/host/windows-x86/bin/AdbWinUsbApi.dll&lt;br /&gt;
cp -fp out/host/windows-x86/obj/EXECUTABLES/AdbWinUsbApi_intermediates/AdbWinUsbApi.dll out/host/windows-x86/bin/AdbWinUsbApi.dll&lt;br /&gt;
host Prebuilt: AdbWinApi (out/host/windows-x86/obj/EXECUTABLES/AdbWinApi_intermediates/AdbWinApi.dll)&lt;br /&gt;
out/host/linux-x86/bin/acp -fp development/host/windows/prebuilt/usb/AdbWinApi.dll out/host/windows-x86/obj/EXECUTABLES/AdbWinApi_intermediates/AdbWinApi.dll&lt;br /&gt;
Install: out/host/windows-x86/bin/AdbWinApi.dll&lt;br /&gt;
cp -fp out/host/windows-x86/obj/EXECUTABLES/AdbWinApi_intermediates/AdbWinApi.dll out/host/windows-x86/bin/AdbWinApi.dll&lt;br /&gt;
Install: out/host/windows-x86/bin/adb.exe&lt;br /&gt;
cp -fp out/host/windows-x86/obj/EXECUTABLES/adb_intermediates/adb.exe out/host/windows-x86/bin/adb.exe&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Yes!! complete!&lt;/div&gt;
&lt;span class=&quot;com&quot; style=&quot;color: #880000; font-size: 13px; line-height: 19px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/5275099393920742609/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2013/09/build-android-adb-for-windows.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/5275099393920742609'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/5275099393920742609'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2013/09/build-android-adb-for-windows.html' title='build android adb for windows'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-7447698000519449689</id><published>2013-08-08T23:49:00.001-07:00</published><updated>2013-08-08T23:49:10.169-07:00</updated><title type='text'>Ubuntu 12.04 + android adb</title><content type='html'>1st Step:&lt;br /&gt;
Download SDK Tools only from&amp;nbsp;&lt;a href=&quot;http://developer.android.com/sdk/index.html&quot;&gt;http://developer.android.com/sdk/index.html&lt;/a&gt;.&lt;br /&gt;
My download link is&amp;nbsp;http://dl.google.com/android/android-sdk_r22.0.5-linux.tgz&lt;br /&gt;
&lt;br /&gt;
2nd Step:&lt;br /&gt;
untar the SDK tool in your folder and execute the android from $yourPath/android-sdk-linux/tools/&lt;br /&gt;
if you didn&#39;t have install the jdk, please install by the prompt. sudo apt-get install openjdk-7-jdk.&lt;br /&gt;
&lt;br /&gt;
3rd Step:&lt;br /&gt;
install the Android SDK Tools, Android SDK Build-tools by the Android SDK Manager as the &quot;&lt;br /&gt;android&quot; execution.&lt;br /&gt;
&lt;br /&gt;
4th Step:&lt;br /&gt;
./adb from the $yourPath/android-sdk-linux/platform-tools&lt;br /&gt;
Maybe it will be occurred &quot;No such file or directory when you execute. Please install by this prompt -&amp;gt; sudo apt-get install lib32ncurses5 lib32stdc++6</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/7447698000519449689/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2013/08/ubuntu-1204-android-adb.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/7447698000519449689'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/7447698000519449689'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2013/08/ubuntu-1204-android-adb.html' title='Ubuntu 12.04 + android adb'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-2052293080251370016</id><published>2013-08-07T19:10:00.003-07:00</published><updated>2013-08-07T19:10:39.587-07:00</updated><title type='text'>let VB using sharefolder</title><content type='html'>&lt;span style=&quot;background-color: white; color: #373737; font-family: &#39;Helvetica Neue&#39;, Helvetica, Arial, sans-serif; font-size: 15px; line-height: 24px;&quot;&gt;sudo usermod -G vboxsf -a [username]&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/2052293080251370016/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2013/08/let-vb-using-sharefolder.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/2052293080251370016'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/2052293080251370016'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2013/08/let-vb-using-sharefolder.html' title='let VB using sharefolder'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-5994253829009141565</id><published>2013-07-18T17:08:00.000-07:00</published><updated>2013-07-18T17:08:07.117-07:00</updated><title type='text'>ubuntu 12.04 samba setting</title><content type='html'># sudo apt-get install samba&lt;br /&gt;
# sudo apt-get install system-config-samba&lt;br /&gt;
&lt;br /&gt;
DASH --&amp;gt; samba&lt;br /&gt;
&lt;br /&gt;
setting complete~!</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/5994253829009141565/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2013/07/ubuntu-1204-samba-setting.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/5994253829009141565'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/5994253829009141565'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2013/07/ubuntu-1204-samba-setting.html' title='ubuntu 12.04 samba setting'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-6959928242349245686</id><published>2013-01-06T22:47:00.002-08:00</published><updated>2013-01-06T22:47:33.463-08:00</updated><title type='text'>pthread condition waiting mutex</title><content type='html'>pthread_cond_wait()&lt;br /&gt;
&lt;br /&gt;
再使用此function時，要特別注意，signal 的timing，不然很容易等不到訊號，必須配合mutex&lt;br /&gt;
&lt;br /&gt;
假設有 call function &quot;command&quot; 與 thread A process command 這種狀況。&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
command()&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp;enqueue_command();&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp;signal&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
thread_A()&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; &amp;nbsp;while(1)&lt;br /&gt;
&amp;nbsp; &amp;nbsp;{&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;waiting_signal&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;while(dequeue());&lt;br /&gt;
&amp;nbsp; &amp;nbsp;}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
如果沒有mutex 輔助的話，可能會發生還沒有waiting 時，signal 不斷的近來，這樣就算queue了之前的command 也無用，因為要等下一次 正確時間的 先waiting 後 signal 的狀況才能夠一次把這些dequeue乾淨，邏輯是不對的&lt;br /&gt;
&lt;br /&gt;
其實用select 的方式作 sleep 就可以解決這樣的問題，反正指令都已經queue起來了，所以有時後在這種狀況，使用waiting condition 配合mutex 是有點多此一舉。</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/6959928242349245686/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2013/01/pthread-condition-waiting-mutex.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/6959928242349245686'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/6959928242349245686'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2013/01/pthread-condition-waiting-mutex.html' title='pthread condition waiting mutex'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-842233492490876717</id><published>2012-11-29T22:21:00.004-08:00</published><updated>2012-11-29T22:24:09.261-08:00</updated><title type='text'>vim structure 自動完成</title><content type='html'>這是一大福音，vim7 已經support 可以像windows 一樣寫code 幫你尋找 結構中的成員，不是以前的 ctrl + n的功能了，只要在vimrc 底下，加入以下設定，搞定。 f8 為此功能，f7 就像以前ctrl+n&lt;br /&gt;
&lt;br /&gt;
filetype plugin indent on&lt;br /&gt;
set completeopt=longest,menu&lt;br /&gt;
imap &amp;lt;f8&amp;gt; &amp;lt;C-X&amp;gt;&amp;lt;C-O&amp;gt;&lt;br /&gt;
imap &amp;lt;f7&amp;gt; &amp;lt;C-X&amp;gt;&amp;lt;C-I&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/842233492490876717/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2012/11/vim-structure.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/842233492490876717'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/842233492490876717'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2012/11/vim-structure.html' title='vim structure 自動完成'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-5921747316368796410</id><published>2012-11-20T18:25:00.004-08:00</published><updated>2012-11-20T18:25:22.246-08:00</updated><title type='text'>xargs 好文章</title><content type='html'>&lt;br /&gt;
&lt;h3&gt;
&lt;a href=&quot;&quot; name=&quot;SECTION00342500000000000000&quot;&gt;xargs&lt;/a&gt;&lt;/h3&gt;
xargs用來處理一些輸出結果要來當另一個輸入的arguments碰到的問題。 例如&lt;pre&gt;      # find /usr/include/ -name &quot;*.h&quot; | xargs -n 2 diff
&lt;/pre&gt;
-n2是指定有兩兩當成輸出變成diff的argumnets&lt;pre&gt;      # find /usr/include/ -name &quot;*.h&quot; | xargs grep &#39;#ifdef&#39;
&lt;/pre&gt;
正常內定是輸出的一拖拉窟的結果，有用xargs時是一個一個餵給後面的命令&lt;pre&gt;      # find /usr/include/ -name &quot;*.h&quot; | xargs -i cp {} ~/include/
&lt;/pre&gt;
-i 與 { }可以把find的輸出的每一個當成cp的第一個argument，&amp;nbsp;/.就可以當成第 二個argument。 其實find裡面有-exec這個選項後面也可以用{ }表示一個一個餵給後面程式，而不是 一拖拉庫的餵給後面程式。&lt;pre&gt;      # find /usr/include/ -name &quot;*.h&quot; -exec cp {} ~/include/
&lt;/pre&gt;
&lt;pre&gt;
&lt;/pre&gt;
&lt;pre&gt;文章出自http://www.study-area.org/cyril/scripts/scripts/node30.html&lt;/pre&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/5921747316368796410/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2012/11/xargs.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/5921747316368796410'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/5921747316368796410'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2012/11/xargs.html' title='xargs 好文章'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-957754464657159753</id><published>2012-04-26T01:28:00.001-07:00</published><updated>2012-06-26T04:54:48.695-07:00</updated><title type='text'>defined but not used</title><content type='html'>&lt;br /&gt;
&lt;div&gt;
Just saw this thread while searching for solutions to this problem. I post here for completeness the solution I found...&lt;/div&gt;
&lt;div&gt;
The GCC compiler flags that control unused warnings are&lt;/div&gt;
&lt;div&gt;
-Wunused-function-Wunused-label-Wunused-parameter-Wunused-value-Wunused (=all of the above)&lt;/div&gt;
&lt;div&gt;
Each of these has a corresponding negative form with &quot;no-&quot; inserted after the W which turns off the warning (in case it was turned on by -Wall, for example). Thus, in your case you should use&lt;/div&gt;
&lt;div&gt;
-Wno-unused-function&lt;/div&gt;
&lt;div&gt;
Of course this works for the whole code, not just compile-time asserts. For function-specific behaviour, have a look at Function attributes.&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/957754464657159753/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2012/04/defined-but-not-used.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/957754464657159753'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/957754464657159753'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2012/04/defined-but-not-used.html' title='defined but not used'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-7634537383496067208</id><published>2012-04-11T07:39:00.002-07:00</published><updated>2012-06-26T04:55:44.821-07:00</updated><title type='text'>macbook pro virtualbox + ubuntu 10.04 vbox resolution</title><content type='html'>&lt;span style=&quot;font-size: 100%;&quot;&gt;sudo gedit /etc/X11/xorg.conf&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;font-size: 100%;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;font-size: 100%;&quot;&gt;
&lt;a href=&quot;http://ubuntuforums.org/showthread.php?t=719126&quot;&gt;http://ubuntuforums.org/showthread.php?t=719126&lt;/a&gt; &lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;font-size: 12px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;
&lt;span style=&quot;font-size: 12px;&quot;&gt;# xorg.conf (X.Org X Window System server configuration file) # # This file was generated by failsafeDexconf, using # values from the debconf database and some overrides to use vesa mode. # # You should use dexconf or another such tool for creating a &quot;real&quot; xorg.conf # For example: # &amp;nbsp; sudo dpkg-reconfigure -phigh xserver-xorg Section &quot;InputDevice&quot; &amp;nbsp;Identifier &quot;Generic Keyboard&quot; &amp;nbsp;Driver &amp;nbsp;&quot;kbd&quot; &amp;nbsp;Option &amp;nbsp;&quot;XkbRules&quot; &quot;xorg&quot; &amp;nbsp;Option &amp;nbsp;&quot;XkbModel&quot; &quot;pc105&quot; &amp;nbsp;Option &amp;nbsp;&quot;XkbLayout&quot; &quot;us&quot; EndSection &amp;nbsp;Section &quot;InputDevice&quot; &amp;nbsp;Identifier &quot;Configured Mouse&quot; &amp;nbsp; &amp;nbsp; Driver &amp;nbsp; &amp;nbsp; &amp;nbsp;&quot;vboxmouse&quot; &amp;nbsp; &amp;nbsp; Option &amp;nbsp; &amp;nbsp; &amp;nbsp;&quot;CorePointer&quot; EndSection &amp;nbsp;Section &quot;Device&quot; &amp;nbsp;Identifier &quot;Configured Video Device&quot; &amp;nbsp;Boardname &quot;vesa&quot; &amp;nbsp;Busid &amp;nbsp;&quot;PCI:0:2:0&quot; &amp;nbsp; &amp;nbsp; Driver &amp;nbsp; &amp;nbsp; &amp;nbsp;&quot;vboxvideo&quot; &amp;nbsp;Screen 0 EndSection &amp;nbsp;Section &quot;Monitor&quot; &amp;nbsp;Identifier &quot;Configured Monitor&quot; &amp;nbsp;Vendorname &quot;Generic LCD Display&quot; &amp;nbsp;Modelname &quot;LCD Panel 1440x900&quot; &amp;nbsp;Horizsync 31.5-56.0 &amp;nbsp;Vertrefresh 56.0 - 65.0 &amp;nbsp; modeline &amp;nbsp;&quot;800x600@56&quot; 36.0 800 824 896 1024 600 601 603 625 +hsync +vsync &amp;nbsp; modeline &amp;nbsp;&quot;800x600@60&quot; 40.0 800 840 968 1056 600 601 605 628 +hsync +vsync &amp;nbsp; modeline &amp;nbsp;&quot;1280x768@60&quot; 80.14 1280 1344 1480 1680 768 769 772 795 -hsync +vsync &amp;nbsp; modeline &amp;nbsp;&quot;1280x720@60&quot; 74.48 1280 1336 1472 1664 720 721 724 746 -hsync +vsync &amp;nbsp; modeline &amp;nbsp;&quot;1280x800@60&quot; 83.46 1280 1344 1480 1680 800 801 804 828 -hsync +vsync &amp;nbsp; modeline &amp;nbsp;&quot;1440x900@60&quot; 106.47 1440 1520 1672 1904 900 901 904 932 -hsync +vsync &amp;nbsp;Gamma 1.0 EndSection &amp;nbsp;Section &quot;Screen&quot; &amp;nbsp;Identifier &quot;Default Screen&quot; &amp;nbsp;Device &amp;nbsp;&quot;Configured Video Device&quot; &amp;nbsp;Monitor &amp;nbsp;&quot;Configured Monitor&quot; &amp;nbsp;Defaultdepth 24 &amp;nbsp;SubSection &quot;Display&quot; &amp;nbsp; Depth 24 &amp;nbsp; Virtual 1440 900 &amp;nbsp; Modes &amp;nbsp;&quot;1440x900@60&quot; &quot;1280x800@60&quot; &quot;1280x720@60&quot; &quot;1280x768@60&quot; &quot;800x600@60&quot; &quot;800x600@56&quot; &amp;nbsp;EndSubSection EndSection &amp;nbsp;Section &quot;ServerLayout&quot; &amp;nbsp;Identifier &quot;Default Layout&quot; &amp;nbsp; screen 0 &quot;Default Screen&quot; 0 0 EndSection Section &quot;Module&quot; &amp;nbsp;Load &amp;nbsp;&quot;glx&quot; &amp;nbsp;Load &amp;nbsp;&quot;GLcore&quot; &amp;nbsp;Load &amp;nbsp;&quot;v4l&quot; EndSection Section &quot;ServerFlags&quot; EndSection&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;font-size: 12px;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/7634537383496067208/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2012/04/macbook-pro-virtualbox-ubuntu-1004-vbox.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/7634537383496067208'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/7634537383496067208'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2012/04/macbook-pro-virtualbox-ubuntu-1004-vbox.html' title='macbook pro virtualbox + ubuntu 10.04 vbox resolution'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-6751388808217146896</id><published>2011-09-11T09:08:00.000-07:00</published><updated>2011-09-11T09:15:03.308-07:00</updated><title type='text'>ubuntu 11.04 tftp install</title><content type='html'>&lt;div&gt;joe@ubuntu: sudo apt-get install xinetd tftpd tftp &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;#vi /etc/xinetd.d/tftp &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;service tftp &lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space:pre&quot;&gt; &lt;/span&gt;{ &lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space:pre&quot;&gt;  &lt;/span&gt;protocol        = udp &lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space:pre&quot;&gt;  &lt;/span&gt;port            = 69 &lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space:pre&quot;&gt;  &lt;/span&gt;socket_type     = dgram &lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space:pre&quot;&gt;  &lt;/span&gt;wait            = yes &lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space:pre&quot;&gt;  &lt;/span&gt;user            = nobody &lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space:pre&quot;&gt;  &lt;/span&gt;server          = /usr/sbin/in.tftpd &lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space:pre&quot;&gt;  &lt;/span&gt;server_args     = /tftpboot &lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space:pre&quot;&gt;  &lt;/span&gt;disable         = no &lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space:pre&quot;&gt; &lt;/span&gt;} &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;#sudo /etc/init.d/xinetd restart&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/6751388808217146896/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2011/09/ubuntu-1104-tftp-install.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/6751388808217146896'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/6751388808217146896'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2011/09/ubuntu-1104-tftp-install.html' title='ubuntu 11.04 tftp install'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-6439263686496010815</id><published>2011-09-11T00:25:00.000-07:00</published><updated>2011-09-11T10:25:37.739-07:00</updated><title type='text'>vim + ctags + cscope + taglist + Trinity + NERD_tree + Source Explorer</title><content type='html'>VIM也用了將近一年半，以往都透過vim + ctags + cscope + taglist開發程式相當習慣，雖在某些功能部份稍嫌不足，但不足以掛齒，最近因為更新VIM，突然忘記vim plug-in 的路徑，請求Google大神後，無意發現有人整理vim的plug-in讓用起來很類似source insight, 似乎操作爽乎。所以乾脆就順便更新一下久沒動過的blogger，讓這些好用的外掛謹記在心。&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;先下載所有的plug-in&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;a href=&quot;http://www.vim.org/scripts/script.php?script_id=273&quot;&gt;Taglist&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;a href=&quot;http://www.vim.org/scripts/script.php?script_id=2347&quot;&gt;Trinity&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;a href=&quot;http://www.vim.org/scripts/script.php?script_id=2179&quot;&gt;Source Explorer&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;a href=&quot;http://www.vim.org/scripts/script.php?script_id=1658&quot;&gt;NERD_Tree&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;在ubuntu 11.04下安裝流程&lt;/div&gt;&lt;div&gt;先安裝ctags cscope&lt;/div&gt;&lt;div&gt;#sudo apt-get install cscope ctags&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Create the folder in ~/.vim/plugin/&lt;/div&gt;&lt;div&gt;將&lt;a href=&quot;http://cscope.sourceforge.net/cscope_maps.vim%20target=_blank&quot;&gt;cscope_map.vim&lt;/a&gt; 複製到以上資料夾&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;到你要開發的根目錄下，建立ctags and cscope&lt;/div&gt;&lt;div&gt;#ctags -R&lt;/div&gt;&lt;div&gt;#ctags -R --exclude Makefile, .svn and so on.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;#cscope -Rbq&lt;/div&gt;&lt;div&gt;基本上就這時就有vim + ctags + cscope的功能了。&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;接著把所有plugin *.vim copy 到 /usr/share/vim/vim73/plugin/&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;這時的外掛就已經安裝完了。&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;這時只需要修改~/.vimrc 成為你想要的行為。&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;以下為我的設定方式。一切搞定就緒！！&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;b&gt;&quot;ser vim&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;set number &quot;display number of line&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;set ai &quot;auto alignment&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;syntax on &quot;color text&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;set tabstop=4 &quot;tab is 4 spaces&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;set shiftwidth=4&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;set softtabstop=4&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;set nobackup &quot;no vi backup&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;set cursorline &quot;display the line for cursor&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;set hlsearch&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;set tags=tags;&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;set mouse=nv&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;&quot;set autochdir&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;hi ModeMsg ctermbg=none ctermfg=brown cterm=none&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;if has(&quot;autocmd&quot;)&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;autocmd BufRead *.txt set tw=78&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;autocmd BufReadPost *&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;\ if line(&quot;&#39;\&quot;&quot;) &amp;gt; 0 &amp;amp;&amp;amp; line (&quot;&#39;\&quot;&quot;) &amp;lt;= line(&quot;$&quot;) |&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;\ exe &quot;normal g`\&quot;&quot; |&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;\ endif&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;endif&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;&quot;set taglist&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;&quot;f12 is the fast link for creating TlistToggle&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;nnoremap &amp;lt;f12&amp;gt; :TrinityToggleAll&lt;cr&gt;&lt;/cr&gt;&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;let Tlist_Exit_OnlyWindow = 1&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;let Tlist_Show_One_File = 1&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;nnoremap &amp;lt;f7&amp;gt; :TrinityToggleTagList&lt;cr&gt;&lt;/cr&gt;&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;nnoremap &amp;lt;f8&amp;gt; :TrinityToggleSourceExplorer&lt;cr&gt;&lt;/cr&gt;&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;nnoremap &amp;lt;f9&amp;gt; :TrinityToggleNERDTree&lt;cr&gt;&lt;/cr&gt;&lt;/b&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;P.S 我透過更新的方式安裝了11.04，vim 照上面BufReadPost設定還是不會回復到上一次編輯的位置。這時可以透過修改/etc/vim/vimrc BufReadPost的部份，將註解拿掉。&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;reference:&lt;/div&gt;&lt;div&gt;&lt;a href=&quot;http://easy72.blogspot.com/2009/05/vim-trinity-tabbar.html&quot;&gt;http://easy72.blogspot.com/2009/05/vim-trinity-tabbar.html&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;a href=&quot;http://stenlyho.blogspot.com/2010/03/vim-trinity-source-explorer-tag-list.html&quot;&gt;http://stenlyho.blogspot.com/2010/03/vim-trinity-source-explorer-tag-list.html&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;a href=&quot;http://jimmynuts.blogspot.com/2010/12/vim.html&quot;&gt;http://jimmynuts.blogspot.com/2010/12/vim.html&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/6439263686496010815/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2011/09/vim-ctags-cscope-taglist-trinity.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/6439263686496010815'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/6439263686496010815'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2011/09/vim-ctags-cscope-taglist-trinity.html' title='vim + ctags + cscope + taglist + Trinity + NERD_tree + Source Explorer'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-411809022786558486</id><published>2011-07-25T17:01:00.000-07:00</published><updated>2012-04-26T01:27:55.155-07:00</updated><title type='text'>QT 好文</title><content type='html'>&lt;meta http-equiv=&quot;content-type&quot; content=&quot;text/html; charset=utf-8&quot;&gt;&lt;a href=&quot;http://thornbird-life.blogbus.com/logs/115983233.html&quot;&gt;http://thornbird-life.blogbus.com/logs/115983233.html&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/411809022786558486/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2011/07/qt.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/411809022786558486'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/411809022786558486'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2011/07/qt.html' title='QT 好文'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-431309137332164658</id><published>2011-04-02T07:32:00.000-07:00</published><updated>2012-04-26T01:27:55.197-07:00</updated><title type='text'>android porting note</title><content type='html'>kernel porting &lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;s3c6410&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;android kernel-2.6.32&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;machine ID error &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;Uncompressing Linux.........................................................................................&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Error: unrecognized/unsupported machine ID (r1 = 0x000009d8).&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Available machine support:&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;ID (hex)        NAME&lt;/div&gt;&lt;div&gt;0000065a        SMDK6410&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Please check your kernel config and/or bootloader.&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Refer linux-kernel2.6.32/include/asm/mach-types.h&lt;/div&gt;&lt;div&gt;#define MACH_TYPE_SMDK6410             1626   ==&amp;gt; 0x65A&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;u-boot wasMINI6410 # bdinfo&lt;/div&gt;&lt;div&gt;arch_number = 0x000009D8&lt;/div&gt;&lt;div&gt;env_t       = 0x00000000&lt;/div&gt;&lt;div&gt;boot_params = 0x50000100&lt;/div&gt;&lt;div&gt;DRAM bank   = 0x00000000&lt;/div&gt;&lt;div&gt;-&amp;gt; start    = 0x50000000&lt;/div&gt;&lt;div&gt;-&amp;gt; size     = 0x10000000&lt;/div&gt;&lt;div&gt;ethaddr     = 08:90:90:90:90:90&lt;/div&gt;&lt;div&gt;ip_addr     = 192.168.2.230&lt;/div&gt;&lt;div&gt;baudrate    = 115200 bps&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;為了麻煩不改變u-boot machine ID 直接改kernel include/asm/mach-type.h，將smdk6410 與 mini6410 的板號直接對調 rebuild 即可。&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;P.S 有些u-boot 可以直接餵  machine id 在 u-boot 的環境變數即可。mini6410 應該是沒有support。&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;File systems-&amp;gt;Miscellaneous-&amp;gt;yaffs2*.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;drivers/misc/pmem.c:441: error: conflicting types for &#39;phys_mem_access_prot&#39;&lt;/div&gt;&lt;div&gt;/home/joe/project/mini6410/android/diff/android_pure_kernel/arch/arm/include/asm/pgtable.h:322: note: previous declaration of &#39;phys_mem_access_prot&#39; was here&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;他要call 的是static 的function&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;這只是名稱有重複使用跟宣告了，把phys_mem_access_prot改個名字就可以了！ 我給他改成pmem_access_prot&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;build kernel 看過程內容 V=1&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;arm-linux-ld: no machine record defined&lt;/div&gt;&lt;div&gt;arm-linux-ld: no machine record defined&lt;/div&gt;&lt;div&gt;arm-linux-ld: no machine record defined&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;因為沒完整移植mach-部份，倒置config 沒選擇正確的CPU會出現的錯誤&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;android 2.2  building&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;編譯完成後，所有的檔案會再 out/target/product/generic 底下， 會有3個產物 ramdisk.img, system.img, userdata.img, 這3個檔案都有對應的目錄，將其所有內容複製到同一資料夾再給予開機格式掛載即可。&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;注意原始建立出來的 dev 目錄底下是沒有任何node的 必須至少建立一個console &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;sudo mknode console c 5 1&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/431309137332164658/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2011/04/android-porting-note.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/431309137332164658'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/431309137332164658'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2011/04/android-porting-note.html' title='android porting note'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-1142409432765888775</id><published>2011-03-29T22:28:00.000-07:00</published><updated>2012-04-26T01:27:55.083-07:00</updated><title type='text'>peripheral note</title><content type='html'>nand flash with MTD based on linux&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;--&amp;gt; ioctl-&amp;gt; linux-kernel/mtd/mtdchar.c ==&amp;gt; mtd_ioctl&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;mtd-abi.h&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;MEMGETINFO&lt;/div&gt;&lt;div&gt;MEMERASE&lt;/div&gt;&lt;div&gt;MEMGETREGIONCOUNT&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/1142409432765888775/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2011/03/peripheral-note.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/1142409432765888775'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/1142409432765888775'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2011/03/peripheral-note.html' title='peripheral note'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-5057672883848765257</id><published>2011-03-21T06:15:00.000-07:00</published><updated>2011-03-21T06:47:44.290-07:00</updated><title type='text'>git</title><content type='html'>git 真的是一個很強大的分散式版本控制器，用途跟SVN目的有點類似但是功能跟使用方法算是天壤之別。&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;假如今天我要下載samsung linux 的kernel 在網站看到 &lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: sans-serif; font-size: 13px; &quot;&gt;git://git.kernel.org/pub/scm/linux/kernel/git/kki_ap/linux-2.6-samsung.git&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;所以可以先將其整個clone到你的local端，&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;$git clone &lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: sans-serif; font-size: 13px; &quot;&gt;git://git.kernel.org/pub/scm/linux/kernel/git/kki_ap/linux-2.6-samsung.git&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: sans-serif; font-size: 13px; &quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;這時候他會將全部的歷史資料download到你的.git裡，下載完成後，可以看到資料夾中是&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: sans-serif; font-size: 13px; &quot;&gt;/linux-2.6-samsung.git中&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;kernel最後的版本，這時可以透過branch的方式來看有多少remote的分支版本&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;$git branch -a&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;  2.6.29&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;  2.6.32&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt; *master&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;  remotes/origin/2.6.24-samsung&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;  remotes/origin/2.6.28-samsung&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;  remotes/origin/2.6.29-samsung&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;  remotes/origin/2.6.31-samsung&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;  remotes/origin/2.6.32-samsung&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;  remotes/origin/2.6.35-samsung&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;  remotes/origin/2.6.36-samsung&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;  remotes/origin/HEAD -&gt; origin/master&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;  remotes/origin/master&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;這時你可以看到remote之後的分支，假設我們現在再主分支master，為此git kernel最新版本2.6.36-samsung，這時想用2.6.24的版本，就透過checkout方式來切換，這地方有點不習慣，因為SVN通常都是一個個資料夾來存取一個版本的方式，git再這邊是多個版本共用一個資料夾，透過checkout的方式可以切換不同版本。&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;#可以透過tab鍵幫你自動補齊檔案名稱唷~很方便&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;$git checkout orgin/2.6.24-samsung&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;Checking out files: 100% (29816/29816), done.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;Note: checking out &#39;origin/2.6.24-samsung&#39;.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;You are in &#39;detached HEAD&#39; state. You can look around, make experimental&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;changes and commit them, and you can discard any commits you make in this&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;state without impacting any branches by performing another checkout.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;If you want to create a new branch to retain commits you create, you may&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;do so (now or later) by using -b with the checkout command again. Example:&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;  git checkout -b new_branch_name&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;HEAD is now at b30234a... Official Release(09.08.26)&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;$git branch -a&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;&lt;div&gt;* (no branch)&lt;/div&gt;&lt;div&gt;  2.6.29&lt;/div&gt;&lt;div&gt;  2.6.32&lt;/div&gt;&lt;div&gt;  2.6.36&lt;/div&gt;&lt;div&gt;  master&lt;/div&gt;&lt;div&gt;  remotes/origin/2.6.24-samsung&lt;/div&gt;&lt;div&gt;  remotes/origin/2.6.28-samsung&lt;/div&gt;&lt;div&gt;  remotes/origin/2.6.29-samsung&lt;/div&gt;&lt;div&gt;  remotes/origin/2.6.31-samsung&lt;/div&gt;&lt;div&gt;  remotes/origin/2.6.32-samsung&lt;/div&gt;&lt;div&gt;  remotes/origin/2.6.35-samsung&lt;/div&gt;&lt;div&gt;  remotes/origin/2.6.36-samsung&lt;/div&gt;&lt;div&gt;  remotes/origin/HEAD -&gt; origin/master&lt;/div&gt;&lt;div&gt;  remotes/origin/master&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;這時會跑在no branch上，可以透過建立local的branch來存放2.6.24&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;$git branch 2.6.24&lt;/div&gt;&lt;div&gt;$git checkout 2.6.24&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;上面兩行合併就為&lt;/div&gt;&lt;div&gt;&lt;div&gt;&amp;amp;git checkout -b 2.6.24&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;$git branch -a&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;這時你會看到2.6.24會有*號表示正在使用此branch，你可以多件幾個版本跟隨不同的local branch。&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;如果不小心建立的不要的branch可以透過下面指令來刪除&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;$git branch -d [deleted branch name]&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;大致上git就是這麼神奇，功能如此強大，就是剛開始clone的時間久了一點，因為他將從頭到尾的資料全部塞再.git底下&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: sans-serif; font-size: small; &quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/5057672883848765257/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2011/03/git.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/5057672883848765257'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/5057672883848765257'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2011/03/git.html' title='git'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7009751233469405122.post-2328474330886291075</id><published>2011-02-27T23:35:00.000-08:00</published><updated>2011-02-27T23:45:03.371-08:00</updated><title type='text'>cross compile openssl</title><content type='html'>download openssl from &lt;a href=&quot;http://www.openssl.org/&quot;&gt;http://www.openssl.org/&lt;/a&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The makefile is already exist,  just modify Makefile without config. The modified configuration as shown below.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;#you want to make install directory.&lt;/div&gt;&lt;div&gt;&lt;div&gt;INSTALLTOP=/home/joe/test_program/openssl-1.0.0d/out&lt;/div&gt;&lt;div&gt;OPENSSLDIR=/home/joe/test_program/openssl-1.0.0d/out&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;CC= arm-none-linux-gnueabi-gcc&lt;/div&gt;&lt;div&gt;CFLAG= -O&lt;/div&gt;&lt;div&gt;DEPFLAG= -DOPENSSL_NO_GMP -DOPENSSL_NO_JPAKE -DOPENSSL_NO_MD2 -DOPENSSL_NO_RC5 -DOPENSSL_NO_RFC3779 -DOPENSSL_NO_STORE&lt;/div&gt;&lt;div&gt;PEX_LIBS= &lt;/div&gt;&lt;div&gt;EX_LIBS= &lt;/div&gt;&lt;div&gt;EXE_EXT= &lt;/div&gt;&lt;div&gt;ARFLAGS= &lt;/div&gt;&lt;div&gt;AR= &lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15.9722px; &quot;&gt;arm-none-linux-gnueab&lt;/span&gt;-ar $(ARFLAGS) r&lt;/div&gt;&lt;div&gt;RANLIB= &lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15.9722px; &quot;&gt;arm-none-linux-gnueab&lt;/span&gt;-ranlib&lt;/div&gt;&lt;div&gt;NM= nm&lt;/div&gt;&lt;div&gt;PERL= /usr/bin/perl&lt;/div&gt;&lt;div&gt;TAR= tar&lt;/div&gt;&lt;div&gt;TARFLAGS= --no-recursion&lt;/div&gt;&lt;div&gt;MAKEDEPPROG=makedepend&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;modified complete, type make, make install as usual.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://live-joesblogger.blogspot.com/feeds/2328474330886291075/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://live-joesblogger.blogspot.com/2011/02/cross-compile-openssl.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/2328474330886291075'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7009751233469405122/posts/default/2328474330886291075'/><link rel='alternate' type='text/html' href='http://live-joesblogger.blogspot.com/2011/02/cross-compile-openssl.html' title='cross compile openssl'/><author><name>joe&#39;s notepad</name><uri>http://www.blogger.com/profile/06287119730183063189</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>