<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Bạch Vân Thành</title>
	<atom:link href="http://axcoto.com/blog/feed" rel="self" type="application/rss+xml" />
	<link>http://axcoto.com/blog</link>
	<description>Mây trắng ngàn năm bay vu vơ</description>
	<lastBuildDate>Sat, 12 May 2012 20:16:33 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Compile PHP on Mac</title>
		<link>http://axcoto.com/blog/article/970</link>
		<comments>http://axcoto.com/blog/article/970#comments</comments>
		<pubDate>Sat, 12 May 2012 20:14:51 +0000</pubDate>
		<dc:creator>kureikain</dc:creator>
				<category><![CDATA[mac/ios]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[php 5.4]]></category>

		<guid isPermaLink="false">http://axcoto.com/blog/?p=970</guid>
		<description><![CDATA[Make sure you had homebrew. If not yet, head over http://mxcl.github.com/homebrew/ and install it. Then you need to install: pcre, libjpeg, mcrypt. Download PHP5.4 on PHP.net. Extract then come into that folder: You done.]]></description>
			<content:encoded><![CDATA[<p>Make sure you had homebrew. If not yet, head over http://mxcl.github.com/homebrew/ and install it.</p>
<p>Then you need to install: pcre, libjpeg, mcrypt.</p>
<p>brew install pcre</p>
<p>brew install libjpeg</p>
<p>brew install mcrypt</p>
<p>Download PHP5.4 on PHP.net. Extract then come into that folder:</p>
<div>
<div>
<div id="LC1">
<pre class="brush: bash; title: ; notranslate">&lt;/div&gt;
&lt;div&gt;./configure \&lt;/div&gt;
&lt;div id=&quot;LC2&quot;&gt;--prefix=/usr \&lt;/div&gt;
&lt;div id=&quot;LC3&quot;&gt;--mandir=/usr/share/man \&lt;/div&gt;
&lt;div id=&quot;LC4&quot;&gt;--infodir=/usr/share/info \&lt;/div&gt;
&lt;div id=&quot;LC5&quot;&gt;--sysconfdir=/private/etc \&lt;/div&gt;
&lt;div id=&quot;LC6&quot;&gt;--with-apxs2=/usr/sbin/apxs \&lt;/div&gt;
&lt;div id=&quot;LC7&quot;&gt;--enable-cli \&lt;/div&gt;
&lt;div id=&quot;LC8&quot;&gt;--with-config-file-path=/etc \&lt;/div&gt;
&lt;div id=&quot;LC9&quot;&gt;--with-libxml-dir=/usr \&lt;/div&gt;
&lt;div id=&quot;LC10&quot;&gt;--with-openssl=/usr \&lt;/div&gt;
&lt;div id=&quot;LC11&quot;&gt;--with-kerberos=/usr \&lt;/div&gt;
&lt;div id=&quot;LC12&quot;&gt;--with-zlib=/usr \&lt;/div&gt;
&lt;div id=&quot;LC13&quot;&gt;--enable-bcmath \&lt;/div&gt;
&lt;div id=&quot;LC14&quot;&gt;--with-bz2=/usr \&lt;/div&gt;
&lt;div id=&quot;LC15&quot;&gt;--enable-calendar \&lt;/div&gt;
&lt;div id=&quot;LC16&quot;&gt;--with-curl=/usr \&lt;/div&gt;
&lt;div id=&quot;LC17&quot;&gt;--enable-dba \&lt;/div&gt;
&lt;div id=&quot;LC18&quot;&gt;--enable-exif \&lt;/div&gt;
&lt;div id=&quot;LC19&quot;&gt;--enable-ftp \&lt;/div&gt;
&lt;div id=&quot;LC20&quot;&gt;--with-gd \&lt;/div&gt;
&lt;div id=&quot;LC21&quot;&gt;--enable-gd-native-ttf \&lt;/div&gt;
&lt;div id=&quot;LC22&quot;&gt;--with-icu-dir=/usr \&lt;/div&gt;
&lt;div id=&quot;LC23&quot;&gt;--with-iodbc=/usr \&lt;/div&gt;
&lt;div id=&quot;LC24&quot;&gt;--with-ldap=/usr \&lt;/div&gt;
&lt;div id=&quot;LC25&quot;&gt;--with-ldap-sasl=/usr \&lt;/div&gt;
&lt;div id=&quot;LC26&quot;&gt;--with-libedit=/usr \&lt;/div&gt;
&lt;div id=&quot;LC27&quot;&gt;--enable-mbstring \&lt;/div&gt;
&lt;div id=&quot;LC28&quot;&gt;--enable-mbregex \&lt;/div&gt;
&lt;div id=&quot;LC29&quot;&gt;--with-mysql=mysqlnd \&lt;/div&gt;
&lt;div id=&quot;LC30&quot;&gt;--with-mysqli=mysqlnd \&lt;/div&gt;
&lt;div id=&quot;LC31&quot;&gt;--without-pear \&lt;/div&gt;
&lt;div id=&quot;LC32&quot;&gt;--with-pdo-mysql=mysqlnd \&lt;/div&gt;
&lt;div id=&quot;LC33&quot;&gt;--with-mysql-sock=/var/mysql/mysql.sock \&lt;/div&gt;
&lt;div id=&quot;LC34&quot;&gt;--with-readline=/usr \&lt;/div&gt;
&lt;div id=&quot;LC35&quot;&gt;--enable-shmop \&lt;/div&gt;
&lt;div id=&quot;LC36&quot;&gt;--with-snmp=/usr \&lt;/div&gt;
&lt;div id=&quot;LC37&quot;&gt;--enable-soap \&lt;/div&gt;
&lt;div id=&quot;LC38&quot;&gt;--enable-sockets \&lt;/div&gt;
&lt;div id=&quot;LC39&quot;&gt;--enable-sysvmsg \&lt;/div&gt;
&lt;div id=&quot;LC40&quot;&gt;--enable-sysvsem \&lt;/div&gt;
&lt;div id=&quot;LC41&quot;&gt;--enable-sysvshm \&lt;/div&gt;
&lt;div id=&quot;LC42&quot;&gt;--with-tidy \&lt;/div&gt;
&lt;div id=&quot;LC43&quot;&gt;--enable-wddx \&lt;/div&gt;
&lt;div id=&quot;LC44&quot;&gt;--with-xmlrpc \&lt;/div&gt;
&lt;div id=&quot;LC45&quot;&gt;--with-iconv-dir=/usr \&lt;/div&gt;
&lt;div id=&quot;LC46&quot;&gt;--with-xsl=/usr \&lt;/div&gt;
&lt;div id=&quot;LC47&quot;&gt;--enable-zip \&lt;/div&gt;
&lt;div id=&quot;LC48&quot;&gt;--with-pcre-regex \&lt;/div&gt;
&lt;div id=&quot;LC49&quot;&gt;--with-pgsql=/usr \&lt;/div&gt;
&lt;div id=&quot;LC50&quot;&gt;--with-pdo-pgsql=/usr \&lt;/div&gt;
&lt;div id=&quot;LC51&quot;&gt;--with-freetype-dir=/usr/X11 \&lt;/div&gt;
&lt;div id=&quot;LC52&quot;&gt;--with-jpeg-dir=/usr \&lt;/div&gt;
&lt;div id=&quot;LC53&quot;&gt;--with-png-dir=/usr/X11&lt;/div&gt;
&lt;div&gt;--with-mcrypt=/usr&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;&lt;/div&gt;
&lt;div&gt;sudo make&lt;/div&gt;
&lt;div&gt;sudo make install&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;</pre>
</div>
<div>You done.</div>
<div></div>
]]></content:encoded>
			<wfw:commentRss>http://axcoto.com/blog/article/970/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Configure samba to share file between linux and win$</title>
		<link>http://axcoto.com/blog/article/968</link>
		<comments>http://axcoto.com/blog/article/968#comments</comments>
		<pubDate>Sat, 12 May 2012 19:54:30 +0000</pubDate>
		<dc:creator>kureikain</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[samba]]></category>

		<guid isPermaLink="false">http://axcoto.com/blog/?p=968</guid>
		<description><![CDATA[It&#8217;s really easy to share file between Linux-Linux which we can simply install NFS then mount it easily from other computer. But this article is to describe how to allow a Windows computer access READ/WRITE to a Linux computer in a very quick, easy, simple way. For Arch Linux, here is what I did to [...]]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s really easy to share file between Linux-Linux which we can simply install<br />
NFS then mount it easily from other computer.</p>
<p>But this article is to describe how to allow a Windows computer access<br />
READ/WRITE to a Linux computer in a very quick, easy, simple way.</p>
<p>For Arch Linux, here is what I did to achieve above purpose.</p>
<p>1. Install samba package<br />
sudo pacman -S samba<br />
sudo pacman -S smbclient</p>
<p>2. Edit config file</p>
<p>By default, we have a sample config which you can copy and edit itself.<br />
cp /etc/samba/smb.conf.default /etc/samba/smb.conf</p>
<p>And then, vim /etc/samba/smb.config</p>
<p>In [global] section, you may want to edit two line:</p>
<p>workgroup<br />
server string</p>
<p>This is optinal so identify your computer easily on network</p>
<p>And then, go to [public] to edit it to your own need.:w<br />
This section is to define public folder which everybody can access to it.</p>
<p>3. Adding user.</p>
<p>At this time, every thing is ready but you need to add an user with the same<br />
name of one of the account on your system. Later, on Windows, once Windows user<br />
go to Network &gt; Linux Computer, they will be asked for an username/password.<br />
They will need this password.</p>
<p>Because I&#8217;m using Linux under account lambasino so I run command:</p>
<p>sudo pbedit -a -u lambasino</p>
<p>And then I entered a password for this samba account. Remember, this is a<br />
password for SAMBA, not password for current account under linux system so you<br />
can enter anything you like. This username/password pair is to other user on other computer connect to your machine via it. This way your real password will be not exposed to the world. You give them samba username/pass instead.</p>
<p>4. Start samba server<br />
sudo rc.d start samba</p>
<p>That&#8217;s all.</p>
<p>On Windows, go to, enter the username/password which you created as above. Ok,<br />
it&#8217;s time to copy something fun over your LAN network ;P</p>
]]></content:encoded>
			<wfw:commentRss>http://axcoto.com/blog/article/968/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setup php-fpm with Apache</title>
		<link>http://axcoto.com/blog/article/880</link>
		<comments>http://axcoto.com/blog/article/880#comments</comments>
		<pubDate>Sat, 12 May 2012 19:46:56 +0000</pubDate>
		<dc:creator>kureikain</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php-fcgi]]></category>
		<category><![CDATA[php-fpm]]></category>

		<guid isPermaLink="false">http://axcoto.com/blog/?p=880</guid>
		<description><![CDATA[It has somay tutorial on how to get php-fpm work with Nginx but I did&#8217;t have much luck on setting it up with Apache. Hope this article can help s.o in the same situation like me: Setting php-fpm with apache. 1. Install apache, php, php-fpm package sudo pacman -S apache php php-fpm 2. create alias [...]]]></description>
			<content:encoded><![CDATA[<p>It has somay tutorial on how to get php-fpm work with Nginx but I did&#8217;t have much luck on setting it up with Apache. Hope this article can help s.o in the same situation like me: Setting php-fpm with apache.</p>
<p>1. Install apache, php, php-fpm package<br />
sudo pacman -S apache php php-fpm</p>
<p>2. create alias to php binary</p>
<p>ln -s /usr/bin/php-cgi /srv/http/php5.fcgi<br />
3. Edit config file</p>
<p>Make sure you don&#8217;t load apache php module. Remove all the lines which you added when installing php as an apache module.</p>
<p>Open the file /etc/httpd/conf/httpd.conf, make sire these link were there. If not, add them</p>
<p># PHP &#8211; FPM<br />
Include conf/extra/httpd-fpm.conf</p>
<p>Then we create conf/extra/httpd-fpm.conf as following:</p>
<p>LoadModule fastcgi_module modules/mod_fastcgi.so</p>
<p>Alias /php5.fcgi /srv/http/php5.fcgi<br />
# Assign the &#8216;fake&#8217; fcgi to call to an &#8216;external&#8217; FastCGI Server<br />
FastCGIExternalServer /srv/http/php5.fcgi -flush -host 127.0.0.1:9000 -pass-header Authorization</p>
<p># Create the handler mappings to associate PHP files with a call to &#8216;/php5.fcgi&#8217;<br />
AddType application/x-httpd-fastphp5 .php<br />
Action application/x-httpd-fastphp5 /php5.fcgi</p>
<p>Config /etc/php/php-fpm.conf for listen setting. When you installed php-fpm, this file is created for you. You just need to open it and carefully go over settings there to confirm if nothing wrong for your machine setting</p>
<p>4. Running</p>
<p>run apache first, then run php-fpm</p>
<p>sudo rc.d start httpd<br />
sudo rc.d start php-fpm<br />
Troubleshoot: If you see this error when connectiong to MySQL: #2002 &#8211; The server is not responding (or the local MySQL server&#8217;s socket is not<br />
correctly configured)</p>
<p>Edit setting for mysql socket in /etc/php.ini</p>
<p>mysqli.default_socket = /var/run/mysqld/mysqld.sock<br />
mysql.default_socket = /var/run/mysqld/mysqld.sock</p>
<p>Normally it is /var/run/mysqld/mysqld.socket<br />
You can double check via reading file /etc/mysql/my.cnf:</p>
<p># The MySQL server<br />
[mysqld]<br />
port            = 3306<br />
socket          = /var/run/mysqld/mysqld.sock<br />
datadir         = /var/lib/mysql<br />
skip-external-locking<br />
key_buffer_size = 16M<br />
max_allowed_packet = 1M<br />
table_open_cache = 64<br />
sort_buffer_size = 512K<br />
net_buffer_length = 8K<br />
read_buffer_size = 256K<br />
read_rnd_buffer_size = 512K<br />
myisam_sort_buffer_size = 8M</p>
]]></content:encoded>
			<wfw:commentRss>http://axcoto.com/blog/article/880/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Enable shell colorize</title>
		<link>http://axcoto.com/blog/article/959</link>
		<comments>http://axcoto.com/blog/article/959#comments</comments>
		<pubDate>Sat, 12 May 2012 18:54:53 +0000</pubDate>
		<dc:creator>kureikain</dc:creator>
				<category><![CDATA[mac/ios]]></category>
		<category><![CDATA[shell color]]></category>

		<guid isPermaLink="false">http://axcoto.com/blog/?p=959</guid>
		<description><![CDATA[Independently which shell you are using, if you ever want to make your shell look cool, turn on color is a great option. That&#8217;s easy. If you used bash. simply edit ~/.bashrc and put these lines: export CLICOLOR=1 export LSCOLORS=GxFxCxDxBxegedabagaced If you used zsh, simply edit ~/.zshrc and put above lines.]]></description>
			<content:encoded><![CDATA[<p>Independently which shell you are using, if you ever want to make your shell look cool, turn on color is a great option. That&#8217;s easy.</p>
<p>If you used bash. simply edit ~/.bashrc and put these lines:</p>
<blockquote><p>export CLICOLOR=1</p>
<p>export LSCOLORS=GxFxCxDxBxegedabagaced</p></blockquote>
<p>If you used zsh, simply edit ~/.zshrc and put above lines.</p>
<p><a href="http://axcoto.com/blog/wp-content/uploads/2012/05/Screen-Shot-2012-05-12-at-11.55.27-AM.png"><img class="aligncenter size-full wp-image-961" title="Screen Shot 2012-05-12 at 11.55.27 AM" src="http://axcoto.com/blog/wp-content/uploads/2012/05/Screen-Shot-2012-05-12-at-11.55.27-AM.png" alt="" width="764" height="485" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://axcoto.com/blog/article/959/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Build Cocoasyncsocket</title>
		<link>http://axcoto.com/blog/article/952</link>
		<comments>http://axcoto.com/blog/article/952#comments</comments>
		<pubDate>Sat, 12 May 2012 18:49:04 +0000</pubDate>
		<dc:creator>kureikain</dc:creator>
				<category><![CDATA[mac/ios]]></category>
		<category><![CDATA[Cocoasocket]]></category>
		<category><![CDATA[GCDAsynsocket]]></category>
		<category><![CDATA[ios]]></category>
		<category><![CDATA[socket]]></category>

		<guid isPermaLink="false">http://axcoto.com/blog/?p=952</guid>
		<description><![CDATA[When you started to worked with Socket in iOS  and you are new to XCode and iOS library,&#8230;you always got many problems when including and compiling external librarys. Today, I got problem with CocoAsynSocket so I want to blog and share about it. If you added GCDAsyncSocket classes, and see these errors when compiling: Then [...]]]></description>
			<content:encoded><![CDATA[<p>When you started to worked with Socket in iOS  and you are new to XCode and iOS library,&#8230;you always got many problems when including and compiling external librarys. Today, I got problem with CocoAsynSocket so I want to blog and share about it.</p>
<p>If you added GCDAsyncSocket classes, and see these errors when compiling:</p>
<pre class="brush: plain; title: ; notranslate">

&quot;_SSLClose&quot;, referenced from:
&lt;pre&gt;&lt;code&gt; -[GCDAsyncSocket closeWithError:] in GCDAsyncSocket.o &lt;/code&gt;&lt;/pre&gt;
&quot;_SSLRead&quot;, referenced from:
&lt;pre&gt;&lt;code&gt; -[GCDAsyncSocket flushSSLBuffers] in GCDAsyncSocket.o -[GCDAsyncSocket doReadData] in GCDAsyncSocket.o &lt;/code&gt;&lt;/pre&gt;
&quot;_SSLGetBufferedReadSize&quot;, referenced from:
&lt;pre&gt;&lt;code&gt; ___33-[GCDAsyncSocket flushSSLBuffers]_block_invoke_0 in GCDAsyncSocket.o -[GCDAsyncSocket doReadData] in GCDAsyncSocket.o &lt;/code&gt;&lt;/pre&gt;
&quot;_SSLWrite&quot;, referenced from:
&lt;pre&gt;&lt;code&gt; -[GCDAsyncSocket doWriteData] in GCDAsyncSocket.o &lt;/code&gt;&lt;/pre&gt;
&quot;_SSLCreateContext&quot;, referenced from:
&lt;pre&gt;&lt;code&gt; -[GCDAsyncSocket ssl_startTLS] in GCDAsyncSocket.o &lt;/code&gt;&lt;/pre&gt;
&amp;nbsp;
&lt;pre&gt;&lt;code&gt;
Undefined symbols for architecture i386:
&quot;_kCFStreamNetworkServiceType&quot;, referenced from:
-[GCDAsyncSocket enableBackgroundingOnSocketWithCaveat:] in GCDAsyncSocket.o
&quot;_kCFStreamNetworkServiceTypeVoIP&quot;, referenced from:
-[GCDAsyncSocket enableBackgroundingOnSocketWithCaveat:] in GCDAsyncSocket.o
&quot;_kCFStreamPropertySSLSettings&quot;, referenced from:
-[GCDAsyncSocket cf_startTLS] in GCDAsyncSocket.o
&quot;_kCFStreamSSLAllowsAnyRoot&quot;, referenced from:
-[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
-[GCDAsyncSocket ssl_startTLS] in GCDAsyncSocket.o
&quot;_kCFStreamSSLAllowsExpiredCertificates&quot;, referenced from:
-[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
-[GCDAsyncSocket ssl_startTLS] in GCDAsyncSocket.o
&quot;_kCFStreamSSLAllowsExpiredRoots&quot;, referenced from:
-[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
-[GCDAsyncSocket ssl_startTLS] in GCDAsyncSocket.o
&quot;_kCFStreamSSLCertificates&quot;, referenced from:
-[GCDAsyncSocket ssl_startTLS] in GCDAsyncSocket.o
&quot;_kCFStreamSSLIsServer&quot;, referenced from:
-[GCDAsyncSocket ssl_startTLS] in GCDAsyncSocket.o
&quot;_kCFStreamSSLLevel&quot;, referenced from:
-[GCDAsyncSocket ssl_startTLS] in GCDAsyncSocket.o
&quot;_kCFStreamSSLPeerName&quot;, referenced from:
-[GCDAsyncSocket ssl_startTLS] in GCDAsyncSocket.o
&quot;_kCFStreamSSLValidatesCertificateChain&quot;, referenced from:
-[GCDAsyncSocket maybeStartTLS] in GCDAsyncSocket.o
-[GCDAsyncSocket ssl_startTLS] in GCDAsyncSocket.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
</pre>
<p>Then make sure you added these libraries:</p>
<ul>
<li>Security.Framework</li>
<li>CFNetwork.framework</li>
</ul>
<p>&nbsp;</p>
<p><a href="http://axcoto.com/blog/wp-content/uploads/2012/05/Screen-Shot-2012-05-10-at-10.44.54-AM.png"><img class="aligncenter size-full wp-image-953" title="Screen Shot 2012-05-10 at 10.44.54 AM" src="http://axcoto.com/blog/wp-content/uploads/2012/05/Screen-Shot-2012-05-10-at-10.44.54-AM.png" alt="" width="599" height="430" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://axcoto.com/blog/article/952/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ios dev: unrecognized selector sent to instance</title>
		<link>http://axcoto.com/blog/article/946</link>
		<comments>http://axcoto.com/blog/article/946#comments</comments>
		<pubDate>Thu, 10 May 2012 05:43:33 +0000</pubDate>
		<dc:creator>kureikain</dc:creator>
				<category><![CDATA[MISC]]></category>
		<category><![CDATA[ios]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[unrecognized selector sent to instance]]></category>

		<guid isPermaLink="false">http://axcoto.com/blog/?p=946</guid>
		<description><![CDATA[Today is the first day I started to programmed on iOS. I compiled a very small, simple app. That went well until I ran it and clicked on a button. Instantly I got this error: If you google this error, it leads you to very complicated topics for a beginner: http://stackoverflow.com/questions/861626/how-to-resolve-unrecognized-selector-sent-to-instance Actually, my problem is [...]]]></description>
			<content:encoded><![CDATA[<p>Today is the first day I started to programmed on iOS. I compiled a very small, simple app. That went well until I ran it and clicked on a button. Instantly I got this error:</p>
<pre class="brush: plain; title: ; notranslate">

unrecognized selector sent to instance
</pre>
<p>If you google this error, it leads you to very complicated topics for a beginner:</p>
<p>http://stackoverflow.com/questions/861626/how-to-resolve-unrecognized-selector-sent-to-instance</p>
<p>Actually, my problem is much simpler. I forgot to define ancestor method for a property. I added a outlet in .h file, but in .m file I forgot to define getter and setter method, or in otherwords, I didn&#8217;t put indicator @synthesize .</p>
<p>I noted here so if you see something with above message, make sure you didn&#8217;t forgot any @synthesize or you need to define 2 accessor methods yourself:</p>
<ul>
<li><code>- (NSString *)userName</code></li>
<li><code>- (void)setUserName:(NSString *)newUserName</code></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://axcoto.com/blog/article/946/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Homebew and XCode 4.3: make, cmake issue</title>
		<link>http://axcoto.com/blog/article/939</link>
		<comments>http://axcoto.com/blog/article/939#comments</comments>
		<pubDate>Sat, 05 May 2012 00:14:49 +0000</pubDate>
		<dc:creator>kureikain</dc:creator>
				<category><![CDATA[MISC]]></category>
		<category><![CDATA[cmake]]></category>
		<category><![CDATA[command line tools]]></category>
		<category><![CDATA[homebrew]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[xcode 4.3]]></category>

		<guid isPermaLink="false">http://axcoto.com/blog/?p=939</guid>
		<description><![CDATA[If you used previous version XCode, you maybe never got some errors complain about make, cmake or sth which I totally forgot now. But if you use XCode4.3, then when you run homebrew and come to step &#8220;make install&#8221;, you will stuck there because of lots of  make, cmake, cflag errors&#8230; If you come to [...]]]></description>
			<content:encoded><![CDATA[<p>If you used previous version XCode, you maybe never got some errors complain about make, cmake or sth which I totally forgot now. But if you use XCode4.3, then when you run homebrew and come to step &#8220;make install&#8221;, you will stuck there because of lots of  make, cmake, cflag errors&#8230; If you come to Google u will got many complicated explanations and solutions. But the problem is much simpler. The real problem here is the missing of command line tools. XCODE 4.3 is shipped without Command Line Tool by default. You might to manually download and install inside XCode in Downloads section. Check the box &#8220;Command Lines Tools&#8221;,  install it and you will be able to compile and install with homebrew after that.</p>
<p><a href="http://axcoto.com/blog/wp-content/uploads/2012/05/Screen-Shot-2012-05-04-at-5.10.18-PM.png"><img class="aligncenter size-full wp-image-940" title="Screen Shot 2012-05-04 at 5.10.18 PM" src="http://axcoto.com/blog/wp-content/uploads/2012/05/Screen-Shot-2012-05-04-at-5.10.18-PM.png" alt="" width="740" height="532" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://axcoto.com/blog/article/939/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Using homebrew to install anything got: &#8220;Error: Cannot write to /usr/local/Cellar&#8221;</title>
		<link>http://axcoto.com/blog/article/934</link>
		<comments>http://axcoto.com/blog/article/934#comments</comments>
		<pubDate>Sat, 05 May 2012 00:00:42 +0000</pubDate>
		<dc:creator>kureikain</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[MISC]]></category>
		<category><![CDATA[/usr/local/Cellar]]></category>
		<category><![CDATA[cellar]]></category>
		<category><![CDATA[homebrew]]></category>
		<category><![CDATA[libjpeg]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[mac change username]]></category>
		<category><![CDATA[permission]]></category>
		<category><![CDATA[wget]]></category>

		<guid isPermaLink="false">http://axcoto.com/blog/?p=934</guid>
		<description><![CDATA[I had a weird situation once I install anything with homebrew, I stucked at: I do and got this For some reasons, /usr/local belongs to admin group insteads of wheel. with sudo, we need to have it in group &#8220;wheel&#8221;. I recall that this happened after I manually change the username. I had an account [...]]]></description>
			<content:encoded><![CDATA[<p>I had a weird situation once I install anything with homebrew, I stucked at:</p>
<pre class="brush: plain; title: ; notranslate">

Error: Cannot write to /usr/local/Cellar
</pre>
<p>I do</p>
<pre class="brush: plain; title: ; notranslate">

ls -la /usr
</pre>
<p>and got this</p>
<pre class="brush: bash; title: ; notranslate">

loho:~ kureikain$ ls -la /usr
total 8
drwxr-xr-x@   13 root  wheel    442 May  4 12:42 .
drwxrwxr-t    27 root  admin    986 May  3 10:44 ..
drwxr-xr-x     8 root  wheel    272 Jul  2  2011 X11
lrwxr-xr-x     1 root  wheel      3 Dec  7 11:43 X11R6 -&gt; X11
drwxr-xr-x  1058 root  wheel  35972 May  4 12:42 bin
drwxr-xr-x   288 root  wheel   9792 May  4 12:41 include
drwxr-xr-x   342 root  wheel  11628 May  4 12:42 lib
drwxr-xr-x   141 root  wheel   4794 May  4 12:42 libexec
drwxr-xr-x     7 root  wheel    238 Jan 27 18:32 llvm-gcc-4.2
drwxrwxr-x    10 root  admin    340 May  4 14:02 local
drwxr-xr-x   261 root  wheel   8874 May  4 12:42 sbin
drwxr-xr-x    69 root  wheel   2346 May  4 12:42 share
drwxr-xr-x     4 root  wheel    136 Jul  2  2011 standalone
</pre>
<p>For some reasons, /usr/local belongs to admin group insteads of wheel. with sudo, we need to have it in group &#8220;wheel&#8221;. I recall that this happened after I manually change the username. I had an account on Mac Mini with username &#8220;vinhnguyen&#8221;. I then decided to change it, so I manually enable root account and change the name of home folder. After I do that, /usr/local became to belong to admin group.</p>
<p>Futher, if I continue to check /usr/local, I got:</p>
<pre class="brush: plain; title: ; notranslate">

loho:~ kureikain$ ls -la /usr/local/
total 24
drwxrwxr-x  10 root        wheel  340 May  4 14:02 .
drwxr-xr-x@ 13 root        wheel  442 May  4 12:42 ..
-rw-r--r--   1 kureikain   admin  159 May  4 14:01 .gitignore
drwxr-xr-x   2 vinhnguyen  admin   68 May  4 11:10 Cellar
drwxrwxr-x   6 vinhnguyen  admin  204 May  2 12:06 Library
-rw-r--r--   1 kureikain   admin  789 May  4 14:02 README.md
drwxrwxr-x   3 vinhnguyen  admin  102 May  4 14:02 bin
lrwxr-xr-x   1 root        wheel   27 May  3 10:04 mysql -&gt; mysql-5.5.23-osx10.6-x86_64
drwxr-xr-x  16 root        wheel  544 Mar 30 00:33 mysql-5.5.23-osx10.6-x86_64
drwxrwxr-x   3 vinhnguyen  admin  102 May  2 12:06 share
</pre>
<p>You may get following error:</p>
<pre class="brush: bash; title: ; notranslate">
Error: Permission denied - /usr/local/include
</pre>
<p>So, I can say permission got messing up after I manually change account name from vinhnguyen to kureikain. So we need to manually correct permission again.</p>
<pre class="brush: bash; title: ; notranslate">

sudo chgrp wheel /usr/local/

sudo chown -R $USER /usr/local/
</pre>
<p>After you do that, everything should work fine.</p>
<p>&nbsp;</p>
<pre class="brush: bash; title: ; notranslate">

loho:~ kureikain$ brew install wget
==&gt; Downloading http://ftpmirror.gnu.org/wget/wget-1.13.4.tar.bz2
Already downloaded: /Library/Caches/Homebrew/wget-1.13.4.tar.bz2
==&gt; ./configure --disable-debug --prefix=/usr/local/Cellar/wget/1.13.4 --sysconf
==&gt; make install
/usr/local/Cellar/wget/1.13.4: 7 files, 552K, built in 34 seconds
</pre>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://axcoto.com/blog/article/934/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Copy to clipboard from command line on Linux and MacOSX</title>
		<link>http://axcoto.com/blog/article/927</link>
		<comments>http://axcoto.com/blog/article/927#comments</comments>
		<pubDate>Sun, 22 Apr 2012 07:44:23 +0000</pubDate>
		<dc:creator>kureikain</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[MISC]]></category>
		<category><![CDATA[clipboard]]></category>
		<category><![CDATA[gui]]></category>
		<category><![CDATA[pbcopy]]></category>
		<category><![CDATA[terminal]]></category>

		<guid isPermaLink="false">http://axcoto.com/blog/?p=927</guid>
		<description><![CDATA[Sometimes it&#8217;s really tough when dealing with clipboard to between terminal and a GUI app. For example, you may need to get the content of id_rsa.pub and paste into browser. In the beginning, I simply fire up a text editor, copy content then paste into browser. Or sometime I highlight text in terminal and use [...]]]></description>
			<content:encoded><![CDATA[<p>Sometimes it&#8217;s really tough when dealing with clipboard to between terminal and a GUI app. For example, you may need to get the content of id_rsa.pub and paste into browser. In the beginning, I simply fire up a text editor, copy content then paste into browser. Or sometime I highlight text in terminal and use mouse&#8217;s middle button to paste text into browser. But it actually has a simpler way to achieve this purpose.</p>
<p>Let use utility <em>pbcopy</em></p>
<pre class="brush: bash; title: ; notranslate">

pbcopy &lt; /path/to/file/need/to/copy/its/content
</pre>
<p>After that your clipboard will be fill in with file&#8217;s content.</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://axcoto.com/blog/article/927/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MacOSX: map home, end, page up/down keys</title>
		<link>http://axcoto.com/blog/article/920</link>
		<comments>http://axcoto.com/blog/article/920#comments</comments>
		<pubDate>Sun, 22 Apr 2012 07:21:01 +0000</pubDate>
		<dc:creator>kureikain</dc:creator>
				<category><![CDATA[MISC]]></category>
		<category><![CDATA[end]]></category>
		<category><![CDATA[home]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[page down]]></category>
		<category><![CDATA[page up]]></category>
		<category><![CDATA[re-map key]]></category>
		<category><![CDATA[special key]]></category>
		<category><![CDATA[zsh]]></category>

		<guid isPermaLink="false">http://axcoto.com/blog/?p=920</guid>
		<description><![CDATA[I have got a mac mini some months ago. I used it with a PC Keyboard and looks like I&#8217;m getting sth worng with home/end, page up/down keys in terminal. I found out that MAC KEYBOARD has special keys such as F15,16, F17 which is used to go to home or end. Since I don&#8217;t [...]]]></description>
			<content:encoded><![CDATA[<p>I have got a mac mini some months ago. I used it with a PC Keyboard and looks like I&#8217;m getting sth worng with home/end, page up/down keys in terminal. I found out that MAC KEYBOARD has special keys such as F15,16, F17 which is used to go to home or end. Since I don&#8217;t have those keys on my keyboard so I will need to remap it. Here is what I have done to get my home/end keys work:</p>
<ul>
<li>Go to Terminal &gt; Preference &gt; Settings &gt; Keyboards</li>
<li>Find the home/end key. By default, it shows action columns as: &#8220;scroll to home/end of buffer&#8221;. You need to edit and change that action to send &#8220;send string to shell&#8221;<br />

<a href='http://axcoto.com/blog/article/920/screen-shot-2012-04-22-at-12-15-11-am' title='Screen Shot 2012-04-22 at 12.15.11 AM'><img width="150" height="150" src="http://axcoto.com/blog/wp-content/uploads/2012/04/Screen-Shot-2012-04-22-at-12.15.11-AM-150x150.png" class="attachment-thumbnail" alt="Screen Shot 2012-04-22 at 12.15.11 AM" title="Screen Shot 2012-04-22 at 12.15.11 AM" /></a>
<a href='http://axcoto.com/blog/article/920/screen-shot-2012-04-22-at-12-15-34-am' title='Screen Shot 2012-04-22 at 12.15.34 AM'><img width="150" height="150" src="http://axcoto.com/blog/wp-content/uploads/2012/04/Screen-Shot-2012-04-22-at-12.15.34-AM-150x150.png" class="attachment-thumbnail" alt="Screen Shot 2012-04-22 at 12.15.34 AM" title="Screen Shot 2012-04-22 at 12.15.34 AM" /></a>
</li>
<li>Do the same for other keys. You will need to put a string which will be send to shell and shell take care the rest for you. Here is the list of strings:<br />
<table>
<tbody>
<tr>
<td>Home</td>
<td>\033[1~</td>
</tr>
<tr>
<td>End</td>
<td>\033[4~</td>
</tr>
<tr>
<td>Page Up</td>
<td>\033[5~</td>
</tr>
<tr>
<td>Page Down</td>
<td>\033[6~</td>
</tr>
</tbody>
</table>
</li>
</ul>
<p>Hope this will help s.o who is starting to use Mac like me <img src='http://axcoto.com/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> .</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://axcoto.com/blog/article/920/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

