<?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: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-9117442876284981323</id><updated>2011-11-27T16:23:35.386-08:00</updated><category term='tethering'/><category term='pycairo'/><category term='vine'/><category term='configd'/><category term='snow leopard'/><category term='apple'/><category term='macosx'/><category term='locale'/><category term='opendns'/><category term='pygtk'/><category term='pkg_config'/><category term='fontconfig'/><category term='lion'/><category term='osx'/><category term='pygobject'/><category term='test fest'/><category term='umit'/><category term='internationalization'/><category term='iphone'/><category term='libjpeg'/><category term='nokia'/><category term='leopard'/><category term='python'/><category term='libedit'/><category term='gettext'/><category term='libpng'/><category term='unicode'/><category term='freetype'/><category term='php'/><category term='nmap'/><category term='pango'/><category term='sqlite'/><category term='macsaber'/><category term='scutil'/><category term='vnc'/><category term='atk'/><category term='isync'/><category term='expat'/><category term='dns'/><category term='qa'/><category term='svg'/><category term='pixman'/><category term='glib'/><category term='gtk+'/><category term='icu'/><category term='swf'/><category term='cairo'/><category term='macports'/><category term='less'/><category term='libtiff'/><title type='text'>Tales from a summer coder</title><subtitle type='html'>the treasure chest of a geek</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://ifeghali.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://ifeghali.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>iGor Feghali</name><uri>http://www.blogger.com/profile/16943173973806079281</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp3.blogger.com/_mEndU8JPa2c/R9MhoxnXHnI/AAAAAAAAAp4/MAcUlMbPT24/S220/2108287763_d7e562d049.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>10</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-9117442876284981323.post-3167483611275773576</id><published>2011-09-16T18:36:00.000-07:00</published><updated>2011-09-16T18:43:02.362-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='php'/><category scheme='http://www.blogger.com/atom/ns#' term='osx'/><category scheme='http://www.blogger.com/atom/ns#' term='libedit'/><category scheme='http://www.blogger.com/atom/ns#' term='macosx'/><category scheme='http://www.blogger.com/atom/ns#' term='lion'/><category scheme='http://www.blogger.com/atom/ns#' term='less'/><category scheme='http://www.blogger.com/atom/ns#' term='apple'/><title type='text'>Mac OS X 10.7 Lion and PHP</title><content type='html'>&lt;p&gt;Since Lion upgrade, I have noted that sometimes the pager utility &lt;i&gt;less&lt;/i&gt; was misbehaving. That's what happens when I try &lt;i&gt;&lt;b&gt;php -i | less&lt;/b&gt;&lt;/i&gt;:&lt;/p&gt;&lt;pre&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;th-png-dir=/BinaryCache/apache_mod_php/apache_mod_php-66.1~51/Root/usr/local' '--enable-gd-native-ttf' '--with-icu-dir=/usr' '--with-iodbc=/usr' '--with-ldap=/usr' '--with-ldap-sasl=/usr' '--with-libedit=/usr' '--enable-mbstring' '--enable-mbregex' '--with-mysql=mysqlnd' '--with-mysqli=mysqlnd' '--without-pear' '--with-pdo-mysql=mysqlnd' '--with-mysql-sock=/var/mysql/mysql.sock' '--with-readline=/usr' '--enable-shmop' '--with-snmp=/usr' '--enable-soap' '--enable-sockets' '--enable-sqlite-utf8' '--enable-suhosin' '--enable-sysvmsg' '--enable-sysvsem' '--enable-sysvshm' '--with-tidy' '--enable-wddx' '--with-xmlrpc' '--with-iconv-dir=/:j&lt;br /&gt;usr' '--with-xsl=/usr' '--enable-zend-multibyte' '--enable-zip' '--with-pcre-regex=/usr' '--with-pgsql=/usr' '--with-pdo-pgsql=/usr'&lt;br /&gt;:j&lt;br /&gt;Server API =&gt; Command Line Interface&lt;br /&gt;Virtual Directory Support =&gt; disabled&lt;br /&gt;:j&lt;br /&gt;Configuration File (php.ini) Path =&gt; /etc&lt;br /&gt;Loaded Configuration File =&gt; /private/etc/php.ini&lt;br /&gt;:j&lt;br /&gt;Scan this dir for additional .ini files =&gt; (none)&lt;br /&gt;Additional .ini files parsed =&gt; (none)&lt;br /&gt;:j&lt;br /&gt;PHP API =&gt; 20090626&lt;br /&gt;PHP Extension =&gt; 20090626&lt;br /&gt;:&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;/pre&gt;&lt;p&gt;And that's what I would expect:&lt;/p&gt;&lt;pre&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;Build Date =&gt; Sep 16 2011 21:54:05&lt;br /&gt;Configure Command =&gt;  './configure'  '--prefix=/opt/php536' '--enable-cli' '--with-libxml-dir=/usr' '--with-openssl=/usr' '--with-kerberos=/usr' '--with-zlib=/usr' '--enable-bcmath' '--with-bz2=/usr' '--enable-calendar' '--with-curl=/usr' '--enable-dba' '--enable-exif' '--enable-ftp' '--with-iodbc=/usr' '--with-ldap=/usr' '--with-ldap-sasl=/usr' '--enable-mbstring' '--enable-mbregex' '--with-mysql=mysqlnd' '--with-mysqli=mysqlnd' '--without-pear' '--with-pdo-mysql=mysqlnd' '--with-mysql-sock=/var/mysql/mysql.sock' '--enable-shmop' '--with-snmp=/usr' '--enable-soap' '--enable-sockets' '--enable-sqlite-utf8' '--enable-sysvmsg' '--enable-sysvsem' '--enable-sysvshm' '--with-tidy' '--enable-wddx' '--with-xmlrpc' '--with-iconv-dir=/usr' '--with-xsl=/usr' '--enable-zend-multibyte' '--enable-zip' '--with-pcre-regex' '--with-pgsql=/usr' '--with-pdo-pgsql=/usr' '--enable-pcntl' '--with-gmp'&lt;br /&gt;Server API =&gt; Command Line Interface&lt;br /&gt;Virtual Directory Support =&gt; disabled&lt;br /&gt;Configuration File (php.ini) Path =&gt; /opt/php536/lib&lt;br /&gt;Loaded Configuration File =&gt; /opt/php536/lib/php.ini&lt;br /&gt;Scan this dir for additional .ini files =&gt; (none)&lt;br /&gt;Additional .ini files parsed =&gt; (none)&lt;br /&gt;PHP API =&gt; 20090626&lt;br /&gt;PHP Extension =&gt; 20090626&lt;br /&gt;Zend Extension =&gt; 220090626&lt;br /&gt;Zend Extension Build =&gt; API220090626,NTS&lt;br /&gt;:&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;/pre&gt;&lt;p&gt;In both cases I tried to go down by pressing the key &lt;b&gt;j&lt;/b&gt; five times.&lt;/p&gt;&lt;p&gt;At first I thought it was some change in a newer version of &lt;i&gt;less&lt;/i&gt; so I was missing some command line option to make it behave like the old good way. But after spending an hour reading its manual, I was convinced it was not a feature - but a bug somewhere.&lt;/p&gt;&lt;p&gt;It turns out that Mac OS X 10.7 Lion (and other &lt;a href="https://bugs.launchpad.net/ubuntu/+source/php5/+bug/322214"&gt;operating systems&lt;/a&gt; as well) comes with a borked &lt;i&gt;libedit&lt;/i&gt; version. Unfortunately in that case Lion's &lt;i&gt;PHP&lt;/i&gt; is shipped with &lt;i&gt;libedit&lt;/i&gt; enabled, as we can see below:&lt;/p&gt;&lt;pre class="cli"&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;$ otool -L `which php` | grep libedit&lt;br /&gt;	/usr/lib/libedit.3.dylib (compatibility version 2.0.0, current version 3.0.0)&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;/pre&gt;&lt;p&gt;So when you try to output &lt;i&gt;PHP&lt;/i&gt;'s &lt;b&gt;stdout&lt;/b&gt; to &lt;i&gt;less&lt;/i&gt;, &lt;i&gt;libedit&lt;/i&gt; and &lt;i&gt;less&lt;/i&gt; starts fighting for &lt;b&gt;stdin&lt;/b&gt; in a not very healthy way - so you get a bad user experience (i.e. screen doesn't redraws well).&lt;/p&gt;&lt;p&gt;The first way I found around it is :&lt;/p&gt;&lt;pre class="cli"&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;$ php -i &lt; /dev/null | less&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;/pre&gt;&lt;p&gt;which is not practical in my opinion. The second way is to custom build &lt;i&gt;PHP&lt;/i&gt; yourself:&lt;/p&gt;&lt;pre class="cli"&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;cd /usr/src&lt;br /&gt;&lt;br /&gt;# download and extract php 5.2.6&lt;br /&gt;wget http://museum.php.net/php5/php-5.3.6.tar.bz2&lt;br /&gt;tar -jxf php-5.3.6.tar.bz2&lt;br /&gt;&lt;br /&gt;# go to source dir&lt;br /&gt;cd php-5.3.6&lt;br /&gt;&lt;br /&gt;# configure&lt;br /&gt;CFLAGS='-arch x86_64' \&lt;br /&gt;CXXFLAGS='-arch x86_64' \&lt;br /&gt;LDFLAGS='-arch x86_64' \&lt;br /&gt;'./configure'  '--prefix=/opt/php536' '--enable-cli' '--with-libxml-dir=/usr' '--with-openssl=/usr' '--with-kerberos=/usr' '--with-zlib=/usr' '--enable-bcmath' '--with-bz2=/usr' '--enable-calendar' '--with-curl=/usr' '--enable-dba' '--enable-exif' '--enable-ftp' '--with-iodbc=/usr' '--with-ldap=/usr' '--with-ldap-sasl=/usr' '--enable-mbstring' '--enable-mbregex' '--with-mysql=mysqlnd' '--with-mysqli=mysqlnd' '--without-pear' '--with-pdo-mysql=mysqlnd' '--with-mysql-sock=/var/mysql/mysql.sock' '--enable-shmop' '--with-snmp=/usr' '--enable-soap' '--enable-sockets' '--enable-sqlite-utf8' '--enable-sysvmsg' '--enable-sysvsem' '--enable-sysvshm' '--with-tidy' '--enable-wddx' '--with-xmlrpc' '--with-iconv-dir=/usr' '--with-xsl=/usr' '--enable-zend-multibyte' '--enable-zip' '--with-pcre-regex' '--with-pgsql=/usr' '--with-pdo-pgsql=/usr' '--enable-pcntl' '--with-gmp'&lt;br /&gt;&lt;br /&gt;# build and install&lt;br /&gt;make&lt;br /&gt;make install&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;/pre&gt;&lt;p&gt;I usually do this as a regular user. You might want to give yourself permissions over &lt;b&gt;/usr/src&lt;/b&gt; and &lt;b&gt;/opt&lt;/b&gt;.&lt;/p&gt;&lt;p&gt;Also, note that Lion's &lt;i&gt;PHP&lt;/i&gt; comes with a few improvements such as &lt;b&gt;suhosin&lt;/b&gt; patch which we are not contemplating here.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/9117442876284981323-3167483611275773576?l=ifeghali.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://ifeghali.blogspot.com/feeds/3167483611275773576/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=9117442876284981323&amp;postID=3167483611275773576' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/3167483611275773576'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/3167483611275773576'/><link rel='alternate' type='text/html' href='http://ifeghali.blogspot.com/2011/09/mac-os-x-107-lion-and-php.html' title='Mac OS X 10.7 Lion and PHP'/><author><name>iGor Feghali</name><uri>http://www.blogger.com/profile/16943173973806079281</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp3.blogger.com/_mEndU8JPa2c/R9MhoxnXHnI/AAAAAAAAAp4/MAcUlMbPT24/S220/2108287763_d7e562d049.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-9117442876284981323.post-1137762672432364473</id><published>2009-10-12T11:58:00.000-07:00</published><updated>2011-03-27T16:18:29.104-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tethering'/><category scheme='http://www.blogger.com/atom/ns#' term='scutil'/><category scheme='http://www.blogger.com/atom/ns#' term='dns'/><category scheme='http://www.blogger.com/atom/ns#' term='snow leopard'/><category scheme='http://www.blogger.com/atom/ns#' term='opendns'/><category scheme='http://www.blogger.com/atom/ns#' term='iphone'/><category scheme='http://www.blogger.com/atom/ns#' term='configd'/><category scheme='http://www.blogger.com/atom/ns#' term='macosx'/><category scheme='http://www.blogger.com/atom/ns#' term='apple'/><title type='text'>Mac OS X 10.6 Snow Leopard, iPhone USB Tethering and Bad Carriers</title><content type='html'>Since &lt;i&gt;iPhone OS 3.0&lt;/i&gt; it is possible to [officially] use your 3G internet connection right into your laptop. That works very well for the all new &lt;i&gt;Snow Leopard&lt;/i&gt;, with one single drawback: it is not possible to set name resolution servers when tethering via USB.&lt;br /&gt;&lt;br /&gt;You might think it is a small issue but I would say you can be wrong, sorry. Relying on carrier's default DNS can be very annoying when they are faulty. And thats exactly what happens with me all the time. My carrier DNS frequently stops resolving top hit domains such as &lt;i&gt;google.com&lt;/i&gt; and many more.&lt;br /&gt;&lt;br /&gt;Of course I can switch to &lt;i&gt;bluetooth&lt;/i&gt;, in which case &lt;i&gt;Snow Leopard&lt;/i&gt; "weirdly" allows you to set your own DNS. But keep in mind that sometimes the phone might have no battery for that. Again, I could just let the phone plugged in a power outlet and bring &lt;i&gt;bluetooth&lt;/i&gt; up, but that would have any fun ! I like to have choices, and not being able to tether via USB is something that annoys me and challenged me for quite some time. &lt;br /&gt;&lt;br /&gt;No more bla bla bla, I could fix my problem when I found about something called &lt;i&gt;configd&lt;/i&gt; and &lt;i&gt;scutil&lt;/i&gt;. You can find a bit of information about them &lt;a href="http://www.afp548.com/article.php?story=20050703052052393"&gt;here&lt;/a&gt; and &lt;a href="http://www.macosxhints.com/article.php?story=20050621051643993"&gt;here&lt;/a&gt;. Going straight to the point, I could manage to overwrite my default DNS (with the address for &lt;a href="http://www.opendns.com/"&gt;&lt;i&gt;opendns&lt;/i&gt;&lt;/a&gt;) using &lt;i&gt;scutil&lt;/i&gt; and a little of bash scripting. That is what I came up with:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;code&gt;&lt;br /&gt;#!/bin/sh&lt;br /&gt;#&lt;br /&gt;# Replaces current DNS with the one you want in Mac OS X&lt;br /&gt;#&lt;br /&gt;# Author: Igor Feghali &lt;ifeghali.blogspot.com&gt;&lt;br /&gt;# &lt;br /&gt;&lt;br /&gt;#DNS="208.67.222.222 208.67.220.220"&lt;br /&gt;DNS="8.8.8.8 8.8.4.4"&lt;br /&gt;STATE=`echo "list State:/Network/Service/[^/]+/DNS" | scutil | awk '{print $4}'`&lt;br /&gt;&lt;br /&gt;(echo "d.init"; echo "d.add ServerAddresses * $DNS"; echo "set $STATE";) | sudo scutil&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;You can set the contents of the variable &lt;i&gt;DNS&lt;/i&gt; in the above script to whichever you want. But don't get too excited. This solution will work only for a few moments. I guess that's because &lt;i&gt;configd&lt;/i&gt; rebuilds the network configuration periodically. &lt;br /&gt;&lt;br /&gt;A short visit to &lt;i&gt;configd&lt;/i&gt; man page led me to the right place: &lt;i&gt;/Library/Preferences/SystemConfiguration/preferences.plist&lt;/i&gt; stores the preferences for all the network interfaces. The first thing to do is to find out the HEX code of which one we want to modify.&lt;br /&gt;&lt;br /&gt;That would be &lt;i&gt;BB6EBCF-861B-4A73-94FE-E08F7EEEE5EE&lt;/i&gt; for me. Now open &lt;i&gt;preferences.plist&lt;/i&gt; (in the above path) and look for the key string somewhere in the file between a &amp;lt;key&amp;gt; and a &amp;lt;/key&amp;gt;. Now replace:&lt;br /&gt;&lt;br /&gt;&lt;pre class="cli"&gt;&lt;code&gt;&lt;br /&gt;&amp;lt;key&amp;gt;EBB6EBCF-861B-4A73-94FE-E08F7EEEE5EE&amp;lt;/key&amp;gt;&lt;br /&gt;&amp;lt;dict&amp;gt;&lt;br /&gt;&amp;lt;key&amp;gt;AppleTalk&amp;lt;/key&amp;gt;&lt;br /&gt;&amp;lt;dict/&amp;gt;&lt;br /&gt;&amp;lt;key&amp;gt;DNS&amp;lt;/key&amp;gt;&lt;br /&gt;&amp;lt;dict/&amp;gt;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;/pre&gt;with:&lt;br /&gt;&lt;pre class="cli"&gt;&lt;code&gt;&lt;br /&gt;&amp;lt;key&amp;gt;EBB6EBCF-861B-4A73-94FE-E08F7EEEE5EE&amp;lt;/key&amp;gt;&lt;br /&gt;&amp;lt;dict&amp;gt;&lt;br /&gt;&amp;lt;key&amp;gt;AppleTalk&amp;lt;/key&amp;gt;&lt;br /&gt;&amp;lt;dict/&amp;gt;&lt;br /&gt;&amp;lt;key&amp;gt;DNS&amp;lt;/key&amp;gt;&lt;br /&gt;&amp;lt;dict&amp;gt;&lt;br /&gt;&amp;lt;key&amp;gt;ServerAddresses&amp;lt;/key&amp;gt;&lt;br /&gt;&amp;lt;array&amp;gt;&lt;br /&gt;&amp;lt;string&amp;gt;208.67.222.222&amp;lt;/string&amp;gt;&lt;br /&gt;&amp;lt;string&amp;gt;208.67.220.220&amp;lt;/string&amp;gt;&lt;br /&gt;&amp;lt;/array&amp;gt;&lt;br /&gt;&amp;lt;/dict&amp;gt;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Just be sure to edit the file as &lt;i&gt;root&lt;/i&gt; (&lt;i&gt;$sudo vim&lt;/i&gt; for instance), save and reboot. That should do the trick.&lt;br /&gt;&lt;br /&gt;I couldn't manage to reload the system configuration without a reboot, just let me know if you do.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/9117442876284981323-1137762672432364473?l=ifeghali.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://ifeghali.blogspot.com/feeds/1137762672432364473/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=9117442876284981323&amp;postID=1137762672432364473' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/1137762672432364473'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/1137762672432364473'/><link rel='alternate' type='text/html' href='http://ifeghali.blogspot.com/2009/10/mac-os-x-106-snow-leopard-iphone-usb.html' title='Mac OS X 10.6 Snow Leopard, iPhone USB Tethering and Bad Carriers'/><author><name>iGor Feghali</name><uri>http://www.blogger.com/profile/16943173973806079281</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp3.blogger.com/_mEndU8JPa2c/R9MhoxnXHnI/AAAAAAAAAp4/MAcUlMbPT24/S220/2108287763_d7e562d049.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-9117442876284981323.post-5828193448917827919</id><published>2009-06-22T04:29:00.000-07:00</published><updated>2009-06-22T04:43:23.944-07:00</updated><title type='text'>PHP'n Rio 09</title><content type='html'>&lt;div style="text-align: left;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.phprio.org/phpnrio09"&gt;&lt;img style="border: 0pt none ; margin: 0pt 0pt 10px 10px; float: right; cursor: pointer; width: 258px; height: 126px;" src="http://phprio.org/data/files/phpnrio09.png" alt="" border="0" /&gt;&lt;/a&gt;The PHP Local User Group of Rio de Janeiro - &lt;a href="http://www.phprio.org/"&gt;PHP Rio&lt;/a&gt; are pleased to announce their &lt;a href="http://www.phprio.org/phpnrio09"&gt;1st PHP'n Rio&lt;/a&gt; conference. It will be held July 03rd at the&lt;br /&gt;&lt;/div&gt;&lt;a href="http://www.infnet.edu.br/"&gt; Infnet Institute&lt;/a&gt;, Rio de Janeiro. It is a one day mini conference, aimed on providing experienced developers and beginners a chance to learn more about PHP frameworks, web&lt;br /&gt;applications built in PHP and testing code.&lt;br /&gt;&lt;br /&gt;The keynote speaker is &lt;a href="http://www.janschneider.de/"&gt;Jan Schneider&lt;/a&gt; that will talk about the &lt;a href="http://www.horde.org/"&gt;Horde&lt;/a&gt; project. We will also have sessions about other frameworks and a PHP TestFest.&lt;br /&gt;&lt;br /&gt;PHP'n Rio sessions goes from 6pm to 9pm. Then PHP TestFest follows up&lt;br /&gt;to 10pm. No fees or subscription required. Participation is entirely&lt;br /&gt;free !&lt;br /&gt;&lt;br /&gt;Whether you live here or are around just enjoying the marvelous city,&lt;br /&gt;come and join us :)&lt;br /&gt;&lt;br /&gt;For more information please visit the official &lt;a href="http://www.phprio.org/phpnrio09"&gt;site&lt;/a&gt; (portuguese only).&lt;br /&gt;&lt;br /&gt;We are looking for sponsors so we can bring even more speakers from&lt;br /&gt;around the country while keeping a great conference for free. If you&lt;br /&gt;see your company fits as our partner, please email Igor Feghali &amp;lt;ifeghali at phprio.org&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/9117442876284981323-5828193448917827919?l=ifeghali.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://ifeghali.blogspot.com/feeds/5828193448917827919/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=9117442876284981323&amp;postID=5828193448917827919' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/5828193448917827919'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/5828193448917827919'/><link rel='alternate' type='text/html' href='http://ifeghali.blogspot.com/2009/06/phpn-rio-09.html' title='PHP&apos;n Rio 09'/><author><name>iGor Feghali</name><uri>http://www.blogger.com/profile/16943173973806079281</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp3.blogger.com/_mEndU8JPa2c/R9MhoxnXHnI/AAAAAAAAAp4/MAcUlMbPT24/S220/2108287763_d7e562d049.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-9117442876284981323.post-7502430397736152717</id><published>2009-03-07T04:07:00.000-08:00</published><updated>2009-03-07T04:44:05.606-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='qa'/><category scheme='http://www.blogger.com/atom/ns#' term='svg'/><category scheme='http://www.blogger.com/atom/ns#' term='test fest'/><category scheme='http://www.blogger.com/atom/ns#' term='php'/><title type='text'>PHP Test Fest 2009</title><content type='html'>&lt;h1&gt;What is it ?&lt;/h1&gt;The TestFest is an event that aims at improving the                   &lt;a href="http://gcov.php.net/"&gt;code coverage&lt;/a&gt; of the                   &lt;a href="http://qa.php.net/running-tests.php"&gt;test suite&lt;/a&gt; for the PHP language                   itself. As part of this event, local User Groups (UG) are invited to                   join the TestFest. These UGs can meet physically or come together                   virtually.&lt;br /&gt;&lt;h1&gt;When is it going to happen?&lt;/h1&gt;UGs are free to pick any timeframe in April - June 2009. Each local TestFest             can last a day, a week or any other timeframe.          &lt;br /&gt;&lt;h1&gt;Where do I get more info?&lt;/h1&gt;At the &lt;a href="http://qa.php.net/testfest.php"&gt;official site&lt;/a&gt; of the event.&lt;br /&gt;&lt;h1&gt;Scalable logo for advertising&lt;/h1&gt;I used Inkscape to vectorize the official logo designed by &lt;em&gt;Vincent Pontier&lt;/em&gt;, so you can make smaller/bigger bitmaps while keeping the good quality.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.novadevel.com/m/ifeghali/files/testfest_scalable.svg"&gt;&lt;img style="border: 1px solid rgb(0, 0, 0); margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 220px; height: 239px;" src="http://1.bp.blogspot.com/_mEndU8JPa2c/SDLDH5dtKvI/AAAAAAAAArw/VFPB-IkBpt0/S1600-R/testfest_big_frame.png" alt="" border="0" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/9117442876284981323-7502430397736152717?l=ifeghali.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://ifeghali.blogspot.com/feeds/7502430397736152717/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=9117442876284981323&amp;postID=7502430397736152717' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/7502430397736152717'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/7502430397736152717'/><link rel='alternate' type='text/html' href='http://ifeghali.blogspot.com/2009/03/php-test-fest-2009.html' title='PHP Test Fest 2009'/><author><name>iGor Feghali</name><uri>http://www.blogger.com/profile/16943173973806079281</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp3.blogger.com/_mEndU8JPa2c/R9MhoxnXHnI/AAAAAAAAAp4/MAcUlMbPT24/S220/2108287763_d7e562d049.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_mEndU8JPa2c/SDLDH5dtKvI/AAAAAAAAArw/VFPB-IkBpt0/s72-Rc/testfest_big_frame.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-9117442876284981323.post-3324285241600253900</id><published>2008-12-21T12:42:00.000-08:00</published><updated>2008-12-21T13:43:47.630-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sqlite'/><category scheme='http://www.blogger.com/atom/ns#' term='leopard'/><category scheme='http://www.blogger.com/atom/ns#' term='osx'/><category scheme='http://www.blogger.com/atom/ns#' term='macosx'/><category scheme='http://www.blogger.com/atom/ns#' term='apple'/><title type='text'>Compiling SQLite 2 on Mac OS X 10.5 Leopard (for x86_64)</title><content type='html'>&lt;span style="font-style:italic;"&gt;Mac OS X 10.5 Leopard&lt;/span&gt; comes with &lt;span style="font-style:italic;"&gt;SQLite v3&lt;/span&gt; bundled. But many times having &lt;span style="font-style:italic;"&gt;SQLite v2&lt;/span&gt; can be handy, given that version 3 is not backwards compatible. The hardest step here is to find the download link for version 2 in the official &lt;a href="http://www.sqlite.org/"&gt;SQLite site&lt;/a&gt;. Don't ask me how did I achieve that... I don't remember ;) Fortunately I wrote down the link so you don't have to bother digging the web again :)&lt;br /&gt;&lt;br /&gt;So we start with:&lt;br /&gt;&lt;blockquote&gt;$ wget http://www.sqlite.org/sqlite-2.8.17.tar.gz&lt;br /&gt;$ tar -zxf sqlite-2.8.17.tar.gz&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;The next big problem comes with &lt;span style="font-weight:bold;"&gt;CFLAGS&lt;/span&gt;. The package we are about to install comes with a pre-made &lt;span style="font-weight:bold;"&gt;configure&lt;/span&gt; script that doesn't respects the &lt;span style="font-weight:bold;"&gt;CFLAGS&lt;/span&gt; environment variable when creating the dynamic library. It took me a while but I have the patch for you, too.&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;--- configure.old       2008-12-21 18:50:24.000000000 -0200&lt;br /&gt;+++ configure   2008-12-21 18:57:11.000000000 -0200&lt;br /&gt;@@ -8253,7 +8253,7 @@&lt;br /&gt;       ;;&lt;br /&gt;     esac&lt;br /&gt;     output_verbose_link_cmd='echo'&lt;br /&gt;-    archive_cmds='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring'&lt;br /&gt;+    archive_cmds='$CC '$CFLAGS' -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring'&lt;br /&gt;     module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'&lt;br /&gt;     # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's&lt;br /&gt;     archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&amp;," &lt; $export_symbols &gt; $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag  -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;After applying the patch to the &lt;span style="font-weight:bold;"&gt;configure&lt;/span&gt; file we can proceed as usual:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;$ ./configure --prefix=/usr/local LDFLAGS="-arch i686 -arch x86_64" CFLAGS="-arch i686 -arch x86_64"&lt;br /&gt;$ make&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;I like to take full advantage of my system so I like to have things working at 64 bits. Just for the case I ever need a tool that won't go 64, I keep a fat binary with both archs 32 and 64. At this point we should check our work:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;$ file .libs/libsqlite.0.8.6.dylib &lt;br /&gt;.libs/libsqlite.0.8.6.dylib: Mach-O universal binary with 2 architectures&lt;br /&gt;.libs/libsqlite.0.8.6.dylib (for architecture i386):    Mach-O dynamically linked shared library i386&lt;br /&gt;.libs/libsqlite.0.8.6.dylib (for architecture x86_64):  Mach-O 64-bit dynamically linked shared library x86_64&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;Everything seems fine. So we finally install it:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;$ sudo make install&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/9117442876284981323-3324285241600253900?l=ifeghali.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://ifeghali.blogspot.com/feeds/3324285241600253900/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=9117442876284981323&amp;postID=3324285241600253900' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/3324285241600253900'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/3324285241600253900'/><link rel='alternate' type='text/html' href='http://ifeghali.blogspot.com/2008/12/compiling-sqlite-2-on-mac-os-x-105.html' title='Compiling SQLite 2 on Mac OS X 10.5 Leopard (for x86_64)'/><author><name>iGor Feghali</name><uri>http://www.blogger.com/profile/16943173973806079281</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp3.blogger.com/_mEndU8JPa2c/R9MhoxnXHnI/AAAAAAAAAp4/MAcUlMbPT24/S220/2108287763_d7e562d049.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-9117442876284981323.post-3301722337825577962</id><published>2008-05-19T07:22:00.000-07:00</published><updated>2008-05-19T07:49:46.253-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='nokia'/><category scheme='http://www.blogger.com/atom/ns#' term='macosx'/><category scheme='http://www.blogger.com/atom/ns#' term='isync'/><category scheme='http://www.blogger.com/atom/ns#' term='apple'/><title type='text'>How to sync your Nokia 5200 with your Mac OS 10.5 Leopard</title><content type='html'>&lt;ol&gt;&lt;li&gt;Download the following plugin:&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.novadevel.com/m/ifeghali/files/Nokia-5200.phoneplugin.zip"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://3.bp.blogspot.com/_mEndU8JPa2c/SDGQQpdtKsI/AAAAAAAAArY/BOrkiyu4CII/s320/plugin.png" alt="" id="BLOGGER_PHOTO_ID_5202097660272388802" border="0" /&gt;&lt;/a&gt;&lt;/li&gt;&lt;li&gt;Go to your Applications folder, look for iSync.&lt;/li&gt;&lt;li&gt;Right click iSync, click "Show Package Contents"&lt;/li&gt;&lt;li&gt;Navigate thru Contents\PlugIns\ApplePhoneConduit.syncdevice\Contents\PlugIns&lt;/li&gt;&lt;li&gt;Extract here the zip you just got&lt;/li&gt;&lt;li&gt;Enable bluetooth on your computer and phone&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Open iSync&lt;/li&gt;&lt;li&gt;Press Command+N to configure your phone settings and you are done&lt;/li&gt;&lt;/ol&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_mEndU8JPa2c/SDGS6pdtKtI/AAAAAAAAArg/EQhe6e3X7wQ/s1600-h/isync.png"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://3.bp.blogspot.com/_mEndU8JPa2c/SDGS6pdtKtI/AAAAAAAAArg/EQhe6e3X7wQ/s320/isync.png" alt="" id="BLOGGER_PHOTO_ID_5202100580850150098" border="0" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/9117442876284981323-3301722337825577962?l=ifeghali.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://ifeghali.blogspot.com/feeds/3301722337825577962/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=9117442876284981323&amp;postID=3301722337825577962' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/3301722337825577962'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/3301722337825577962'/><link rel='alternate' type='text/html' href='http://ifeghali.blogspot.com/2008/05/how-to-sync-your-nokia-5200-with-your.html' title='How to sync your Nokia 5200 with your Mac OS 10.5 Leopard'/><author><name>iGor Feghali</name><uri>http://www.blogger.com/profile/16943173973806079281</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp3.blogger.com/_mEndU8JPa2c/R9MhoxnXHnI/AAAAAAAAAp4/MAcUlMbPT24/S220/2108287763_d7e562d049.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_mEndU8JPa2c/SDGQQpdtKsI/AAAAAAAAArY/BOrkiyu4CII/s72-c/plugin.png' height='72' width='72'/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-9117442876284981323.post-7894836366290978436</id><published>2008-05-07T07:20:00.000-07:00</published><updated>2008-05-19T07:51:44.744-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='swf'/><category scheme='http://www.blogger.com/atom/ns#' term='vine'/><category scheme='http://www.blogger.com/atom/ns#' term='gtk+'/><category scheme='http://www.blogger.com/atom/ns#' term='vnc'/><category scheme='http://www.blogger.com/atom/ns#' term='python'/><category scheme='http://www.blogger.com/atom/ns#' term='macosx'/><category scheme='http://www.blogger.com/atom/ns#' term='apple'/><title type='text'>How to record your Mac OS 10.5 Leopard screen to SWF</title><content type='html'>Sometimes when you want to demo an application or even create a step by step tutorial on something, there is nothing better then a live recording of the action. In those cases &lt;a href="http://www.unixuser.org/%7Eeuske/vnc2swf/"&gt;vnc2swf&lt;/a&gt; is a small and very handy python script able to help you on that job.&lt;br /&gt;&lt;br /&gt;I am not very sure on what it depends, but you would need X11, Freetype 2, jpeg and Python Imaging Library (&lt;a href="http://www.pythonware.com/products/pil/#pil116"&gt;PIL&lt;/a&gt;) at least. Python of course, but Leopard already comes with version 2.5. I am not sure about GTK, I already had that on my system. If you don't, please take a look at &lt;a href="http://ifeghali.blogspot.com/2008/03/compiling-gtk-on-mac-os-x-105-leopard.html"&gt;Compiling GTK+ on Mac OS X 10.5 Leopard&lt;/a&gt; and get it to your system. That same post would help you setup all the dependencies but PIL, that we are going to cover now.&lt;br /&gt;&lt;br /&gt;Download &lt;a href="http://effbot.org/downloads/Imaging-1.1.6.tar.gz"&gt;PIL&lt;/a&gt; source code to /usr/src. I assume all your own compiled libraries are installed to /usr/local and you used architecture i686.&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;cd /usr/src&lt;br /&gt;wget http://effbot.org/downloads/Imaging-1.1.6.tar.gz&lt;br /&gt;tar -zxf Imaging-1.1.6.tar.gz&lt;br /&gt;cd Imaging-1.1.6&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;Now you need to hack setup.py accoding to that diff:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;--- setup.py.orig   2006-12-03 09:37:29.000000000 -0200&lt;br /&gt;+++ setup.py    2008-05-06 21:13:29.000000000 -0300&lt;br /&gt;@@ -131,14 +131,10 @@&lt;br /&gt;&lt;br /&gt;     elif sys.platform == "darwin":&lt;br /&gt;         # attempt to make sure we pick freetype2 over other versions&lt;br /&gt;-            add_directory(include_dirs, "/sw/include/freetype2")&lt;br /&gt;-            add_directory(include_dirs, "/sw/lib/freetype2/include")&lt;br /&gt;+            add_directory(include_dirs, "/usr/local/include/freetype2")&lt;br /&gt;         # fink installation directories&lt;br /&gt;-            add_directory(library_dirs, "/sw/lib")&lt;br /&gt;-            add_directory(include_dirs, "/sw/include")&lt;br /&gt;-            # darwin ports installation directories&lt;br /&gt;-            add_directory(library_dirs, "/opt/local/lib")&lt;br /&gt;-            add_directory(include_dirs, "/opt/local/include")&lt;br /&gt;+            add_directory(library_dirs, "/usr/local/lib")http://www.blogger.com/img/gl.link.gif&lt;a href="http://www.unixuser.org/%7Eeuske/vnc2swf/pyvnc2swf.html"&gt;&lt;/a&gt;&lt;br /&gt;+            add_directory(include_dirs, "/usr/local/include")&lt;br /&gt;&lt;br /&gt;     add_directory(library_dirs, "/usr/local/lib")&lt;br /&gt;     # FIXME: check /opt/stuff directories here?&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;Then you are done to build:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;export ARCHFLAGS="-arch i686"&lt;br /&gt;export CFLAGS="-arch i686"&lt;br /&gt;python setup.py build&lt;br /&gt;sudo python setup.py install&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;Now you would just unzip and go vnc2swf but I couldn't make it work with Leopard's built-in VNC server (Screen Sharing) so you first need &lt;a href="http://www.redstonesoftware.com/products/vine_server/OS_X"&gt;OSXVnc&lt;/a&gt;. Download the &lt;a href="http://www.redstonesoftware.com/downloads/Vine3.0.dmg"&gt;disc image&lt;/a&gt;, mount it and copy Vine Server to your Applications folder. Run and start the server.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_mEndU8JPa2c/SCHChyg8-pI/AAAAAAAAArI/HWxmrx7IoCc/s1600-h/vine.png"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://3.bp.blogspot.com/_mEndU8JPa2c/SCHChyg8-pI/AAAAAAAAArI/HWxmrx7IoCc/s320/vine.png" alt="" id="BLOGGER_PHOTO_ID_5197649330713721490" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;You are now ready to go vnc2swf:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;cd /usr/src&lt;br /&gt;wget http://www.unixuser.org/~euske/vnc2swf/pyvnc2swf-0.9.3.tar.gz&lt;br /&gt;tar -zxf pyvnc2swf-0.9.3.tar.gz&lt;br /&gt;cd pyvnc2swf-0.9.3/pyvnc2swf/&lt;br /&gt;./vnc2swf.py -n -o /tmp/myMovie.swf&lt;br /&gt;&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/9117442876284981323-7894836366290978436?l=ifeghali.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://ifeghali.blogspot.com/feeds/7894836366290978436/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=9117442876284981323&amp;postID=7894836366290978436' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/7894836366290978436'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/7894836366290978436'/><link rel='alternate' type='text/html' href='http://ifeghali.blogspot.com/2008/05/how-to-record-your-mac-os-105-leopard.html' title='How to record your Mac OS 10.5 Leopard screen to SWF'/><author><name>iGor Feghali</name><uri>http://www.blogger.com/profile/16943173973806079281</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp3.blogger.com/_mEndU8JPa2c/R9MhoxnXHnI/AAAAAAAAAp4/MAcUlMbPT24/S220/2108287763_d7e562d049.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_mEndU8JPa2c/SCHChyg8-pI/AAAAAAAAArI/HWxmrx7IoCc/s72-c/vine.png' height='72' width='72'/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-9117442876284981323.post-1964989833998480072</id><published>2008-03-27T20:32:00.000-07:00</published><updated>2008-03-29T05:30:20.806-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='internationalization'/><category scheme='http://www.blogger.com/atom/ns#' term='unicode'/><category scheme='http://www.blogger.com/atom/ns#' term='locale'/><category scheme='http://www.blogger.com/atom/ns#' term='iphone'/><category scheme='http://www.blogger.com/atom/ns#' term='icu'/><category scheme='http://www.blogger.com/atom/ns#' term='macosx'/><category scheme='http://www.blogger.com/atom/ns#' term='apple'/><title type='text'>How to hack iphone locales</title><content type='html'>You may already seen out there some projects that translates the iPhone user interface to many different languages. Locale strings are stored in a totally different way though. Things like "Monday" and the Portuguese equivalent "Segunda-Feira" are stored in a &lt;a href="http://www.icu-project.org/"&gt;ICU&lt;/a&gt; (International Components for Unicode) data file.&lt;br /&gt;&lt;br /&gt;For 12 mondays I had to stand looking at "Segunda-Feira" being printed out of the bounds of &lt;span style="font-style: italic;"&gt;iCal&lt;/span&gt; icon. Until today. I tried &lt;span style="font-style: italic;"&gt;fgrep&lt;/span&gt;'ng the whole iPhone for the string "segunda" with no luck. Then I tried converting all the plists from binaries to XML and &lt;span style="font-style: italic;"&gt;fgrep&lt;/span&gt;'ng again and still no luck. Doing some research I found that apple uses ICU on iPhone, which drove me to find our target: &lt;span style="font-weight: bold;"&gt;/usr/share/icu/icudt34l.dat&lt;/span&gt;. This is a 8.5MB file bundled with all the locales (timezones, region formats, etc.).&lt;br /&gt;&lt;br /&gt;To start playing with it, the first thing we will need is obviously the file itself:&lt;br /&gt;&lt;blockquote&gt;cd /tmp&lt;br /&gt;ssh root@iPhone cp /usr/share/icu/icudt34l.dat /usr/share/icu/icudt34l.dat.bak&lt;br /&gt;scp root@iPhone:/usr/share/icu/icudt34l.dat .&lt;br /&gt;&lt;/blockquote&gt;Now we need the &lt;a href="ftp://ftp.software.ibm.com/software/globalization/icu/3.4.1/icu-3.4.1.tgz"&gt;ICU version 3.4 tools&lt;/a&gt;. Again, I don't like macports or fink so I had a bad time trying to compile it myself (remember I am on a Mac OS X Leopard). You have now the cake recipe:&lt;br /&gt;&lt;blockquote&gt;cd /usr/src&lt;br /&gt;wget ftp://ftp.software.ibm.com/software/globalization/icu/3.4.1/icu-3.4.1.tgz&lt;br /&gt;tar -zxf icu-3.4.1.tgz&lt;br /&gt;mv icu icu-3.4.1&lt;br /&gt;cd icu-3.4.1/source&lt;br /&gt;&lt;/blockquote&gt;For some weird reason the configure script for darwin is broken, so I had to fix that with the following patch:&lt;br /&gt;&lt;blockquote&gt;--- config/mh-darwin   2004-05-18 18:54:24.000000000 -0300&lt;br /&gt;+++ config/mh-darwin.new    2008-03-27 23:48:45.000000000 -0300&lt;br /&gt;@@ -58,6 +58,7 @@&lt;br /&gt;@echo "generating dependency information for $&lt;"         @$(GEN_DEPS.c) $&lt; &gt; /dev/null&lt;br /&gt;@mv $@ $@~&lt;br /&gt;-       @echo -n "$@ " &gt; $@&lt;br /&gt;@cat &lt; $@~ &gt;&gt; $@&lt;br /&gt;@-rm $@~&lt;br /&gt;&lt;br /&gt;@@ -65,6 +66,7 @@&lt;br /&gt;@echo "generating dependency information for $&lt;"         @$(GEN_DEPS.cc) $&lt; &gt;/dev/null&lt;br /&gt;@mv $@ $@~&lt;br /&gt;-       @echo -n "$@ " &gt; $@&lt;br /&gt;@cat &lt; $@~ &gt;&gt; $@&lt;br /&gt;@-rm $@~&lt;br /&gt;&lt;/blockquote&gt;Now we can run configure:&lt;br /&gt;&lt;blockquote&gt;./runConfigureICU MacOSX --disable-samples --disable-draft --disable-extras --disable-tracing --disable-tests&lt;br /&gt;&lt;/blockquote&gt;and make it:&lt;br /&gt;&lt;blockquote&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;I couldn't manage to get file from bin/ installed on my system, but anyway I wasn't really interested on going deeply on that. Heck, I want to get rid of that "Segunda-Feira" thing !&lt;br /&gt;&lt;br /&gt;Lets extract our package now:&lt;br /&gt;&lt;blockquote&gt;cd /tmp&lt;br /&gt;/usr/src/icu-3.4.1/source/bin/decmn icudt34l.dat --pkgdata &gt; out.lst&lt;br /&gt;cd icudt34l&lt;br /&gt;&lt;/blockquote&gt;boom ! we got a lot of files... and look who is laying around:&lt;br /&gt;&lt;blockquote&gt;-rw-r--r--  1 igor  wheel    51K Mar 28 00:14 pt.res&lt;br /&gt;-rw-r--r--  1 igor  wheel   496B Mar 27 23:06 pt_BR.res&lt;br /&gt;-rw-r--r--  1 igor  wheel   3.7K Mar 27 23:06 pt_PT.res&lt;br /&gt;&lt;/blockquote&gt;The file we want is pt.res, but its a binary file. I couldn't manage to convert it back to something readable but again I am more interested in the quickest solution possible. Just download the pt.txt &lt;a href="http://source.icu-project.org/repos/icu/icu/tags/release-3-4-1/source/data/locales/pt.txt"&gt;here&lt;/a&gt;. Near to the end you will find the calendar day names. Edit accordingly. &lt;span style="font-weight: bold;"&gt;Important: &lt;/span&gt;remember to use UTF-8.&lt;br /&gt;&lt;br /&gt;Now its time to generate our new &lt;a href="http://www.icu-project.org/userguide/ResourceManagement.html"&gt;resource&lt;/a&gt;:&lt;br /&gt;&lt;blockquote&gt;/usr/src/icu-3.4.1/source/bin/genrb pt.txt&lt;br /&gt;&lt;/blockquote&gt;and re-package:&lt;br /&gt;&lt;blockquote&gt;/usr/src/icu-3.4.1/source/bin/gencmn -v -n icudt34l 0 &lt; ../out.lst &lt;/blockquote&gt;At this point you cross your fingers and hope this works... worked for me :)&lt;br /&gt;&lt;blockquote&gt;scp icudt34l.dat root@iPhone:/usr/share/icu&lt;br /&gt;&lt;/blockquote&gt;reboot and you are all set.&lt;br /&gt;&lt;br /&gt;If you can read Portuguese you might find this &lt;a href="http://right-it.blogspot.com/2007/10/como-gerar-o-arquivo-icu-no-mac-os-x.html"&gt;entry&lt;/a&gt; interesting as well. It describes the similar process of updating Mac OS X timezone. It makes use of `&lt;span style="font-style: italic;"&gt;icupkg&lt;/span&gt;` though, that is not available on ICU version 3.4.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/9117442876284981323-1964989833998480072?l=ifeghali.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://ifeghali.blogspot.com/feeds/1964989833998480072/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=9117442876284981323&amp;postID=1964989833998480072' title='7 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/1964989833998480072'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/1964989833998480072'/><link rel='alternate' type='text/html' href='http://ifeghali.blogspot.com/2008/03/how-to-hack-iphone-locales.html' title='How to hack iphone locales'/><author><name>iGor Feghali</name><uri>http://www.blogger.com/profile/16943173973806079281</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp3.blogger.com/_mEndU8JPa2c/R9MhoxnXHnI/AAAAAAAAAp4/MAcUlMbPT24/S220/2108287763_d7e562d049.jpg'/></author><thr:total>7</thr:total></entry><entry><id>tag:blogger.com,1999:blog-9117442876284981323.post-1816261435443686368</id><published>2008-03-26T09:17:00.000-07:00</published><updated>2008-05-19T07:54:19.220-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='macports'/><category scheme='http://www.blogger.com/atom/ns#' term='gtk+'/><category scheme='http://www.blogger.com/atom/ns#' term='umit'/><category scheme='http://www.blogger.com/atom/ns#' term='pygobject'/><category scheme='http://www.blogger.com/atom/ns#' term='python'/><category scheme='http://www.blogger.com/atom/ns#' term='pygtk'/><category scheme='http://www.blogger.com/atom/ns#' term='leopard'/><category scheme='http://www.blogger.com/atom/ns#' term='pycairo'/><category scheme='http://www.blogger.com/atom/ns#' term='macosx'/><category scheme='http://www.blogger.com/atom/ns#' term='apple'/><title type='text'>GTK Python bindings for Mac OS X 10.5 Leopard</title><content type='html'>Following my previous post we are now ready to compile and install the python bindings in order to have &lt;a href="http://www.umitproject.org/"&gt;UMIT&lt;/a&gt; ready to go.&lt;br /&gt;&lt;br /&gt;we start with &lt;span style="font-style: italic;"&gt;pygobject&lt;/span&gt; which is cursed by &lt;a href="http://en.wikipedia.org/wiki/Murphy%27s_law"&gt;Murphy's law&lt;/a&gt;. At the first attempt I got &lt;span style="font-style: italic;"&gt;make&lt;/span&gt; stopped by an error message, that could be fixed by telling which python version we would like to use (one more time thanks to &lt;a href="http://trac.macports.org/projects/macports/ticket/13337"&gt;macports&lt;/a&gt;).&lt;br /&gt;&lt;blockquote&gt;wget http://ftp.gnome.org/pub/GNOME/sources/pygobject/2.14/pygobject-2.14.1.tar.bz2&lt;br /&gt;tar -jxf pygobject-2.14.1.tar.bz2&lt;br /&gt;cd pygobject-2.14.1&lt;br /&gt;./configure --prefix=/usr/local --disable-glibtest CFLAGS="-arch i686" PYTHON=/usr/bin/python2.5&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;next &lt;span style="font-style: italic;"&gt;pycairo&lt;/span&gt;:&lt;br /&gt;&lt;blockquote&gt;wget http://cairographics.org/releases/pycairo-1.4.12.tar.gz&lt;br /&gt;tar -zxf pycairo-1.4.12.tar.gz&lt;br /&gt;./configure --prefix=/usr/local CFLAGS="-arch i686" PYTHON=/usr/bin/python2.5&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;and finally &lt;span style="font-style: italic;"&gt;pygtk:&lt;/span&gt;&lt;br /&gt;&lt;blockquote&gt;wget http://ftp.gnome.org/pub/GNOME/sources/pygtk/2.12/pygtk-2.12.1.tar.bz2&lt;br /&gt;tar -jxf pygtk-2.12.1.tar.bz2&lt;br /&gt;cd pygtk-2.12.1&lt;br /&gt;./configure --prefix=/usr/local CFLAGS="-arch i686" PYTHON=/usr/bin/python2.5&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;that's the end of our saga. You can now enjoy &lt;span style="font-style: italic;"&gt;UMIT&lt;/span&gt; on your Mac OS :)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/9117442876284981323-1816261435443686368?l=ifeghali.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://ifeghali.blogspot.com/feeds/1816261435443686368/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=9117442876284981323&amp;postID=1816261435443686368' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/1816261435443686368'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/1816261435443686368'/><link rel='alternate' type='text/html' href='http://ifeghali.blogspot.com/2008/03/gtk-python-bindings-for-mac-os-x-105.html' title='GTK Python bindings for Mac OS X 10.5 Leopard'/><author><name>iGor Feghali</name><uri>http://www.blogger.com/profile/16943173973806079281</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp3.blogger.com/_mEndU8JPa2c/R9MhoxnXHnI/AAAAAAAAAp4/MAcUlMbPT24/S220/2108287763_d7e562d049.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-9117442876284981323.post-3670614048867122995</id><published>2008-03-06T18:21:00.000-08:00</published><updated>2011-01-25T13:19:51.271-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='gettext'/><category scheme='http://www.blogger.com/atom/ns#' term='gtk+'/><category scheme='http://www.blogger.com/atom/ns#' term='glib'/><category scheme='http://www.blogger.com/atom/ns#' term='pango'/><category scheme='http://www.blogger.com/atom/ns#' term='nmap'/><category scheme='http://www.blogger.com/atom/ns#' term='libtiff'/><category scheme='http://www.blogger.com/atom/ns#' term='cairo'/><category scheme='http://www.blogger.com/atom/ns#' term='macosx'/><category scheme='http://www.blogger.com/atom/ns#' term='apple'/><category scheme='http://www.blogger.com/atom/ns#' term='pkg_config'/><category scheme='http://www.blogger.com/atom/ns#' term='macsaber'/><category scheme='http://www.blogger.com/atom/ns#' term='freetype'/><category scheme='http://www.blogger.com/atom/ns#' term='umit'/><category scheme='http://www.blogger.com/atom/ns#' term='pixman'/><category scheme='http://www.blogger.com/atom/ns#' term='expat'/><category scheme='http://www.blogger.com/atom/ns#' term='libjpeg'/><category scheme='http://www.blogger.com/atom/ns#' term='atk'/><category scheme='http://www.blogger.com/atom/ns#' term='leopard'/><category scheme='http://www.blogger.com/atom/ns#' term='fontconfig'/><category scheme='http://www.blogger.com/atom/ns#' term='libpng'/><title type='text'>Compiling GTK+ on Mac OS X 10.5 Leopard</title><content type='html'>&lt;a href="http://www.umitproject.org/"&gt;UMIT&lt;/a&gt; is an awesome graphical frontend for &lt;a href="http://www.nmap.org/"&gt;nmap&lt;/a&gt;. It works out of the box, that is, unzip and go. But, it requires &lt;a href="http://www.gtk.org/"&gt;GTK+2&lt;/a&gt;, which is a totally different history...&lt;br /&gt;&lt;br /&gt;Compiling GTK+ on &lt;a href="http://www.apple.com/macosx/"&gt;Mac OS X&lt;/a&gt; can be a time consuming task, specially if you don't want to use tools like Fink or MacPorts. Obviously I don't keep backup of my libs so after my last HDD crash (less than a year brand new MacBook, thanks to &lt;a href="http://code.google.com/p/macsaber/"&gt;MacSaber&lt;/a&gt;) I had to redo all the GTK saga again. This time I am going to record the whole process to the history, so I can drastically reduce the efforts on future attempts.&lt;br /&gt;&lt;br /&gt;Yes, GTK has a million dependencies that have a million dependencies themselves leaving us with a gazillion libraries to take care of. While I was going forward and back across the dependencies I wrote down what depends on what. That's what I came up with:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;gtk&lt;br /&gt;&lt;/li&gt;&lt;ul&gt;&lt;li&gt;glib&lt;/li&gt;&lt;ul&gt;&lt;li&gt;pkg_config&lt;/li&gt;&lt;li&gt;gettext&lt;/li&gt;&lt;ul&gt;&lt;li&gt;expat&lt;/li&gt;&lt;/ul&gt;&lt;li&gt;libpng&lt;/li&gt;&lt;/ul&gt;&lt;li&gt;atk&lt;/li&gt;&lt;li&gt;pango&lt;br /&gt;&lt;ul&gt;&lt;li&gt;cairo&lt;/li&gt;&lt;ul&gt;&lt;li&gt;pixman&lt;/li&gt;&lt;li&gt;freetype&lt;/li&gt;&lt;li&gt;fontconfig&lt;/li&gt;&lt;/ul&gt;&lt;/ul&gt;&lt;/li&gt;&lt;li&gt;libtiff&lt;br /&gt;&lt;ul&gt;&lt;li&gt;libjpeg&lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;/ul&gt;&lt;/ul&gt;Easy, huh ? No its not what it looks like. It took me a whole day and a half to fix every little issue that kept me from going ahead during the process. For each library, there is a special trick you have to learn.&lt;br /&gt;&lt;br /&gt;For the architecture I decided to go with &lt;span style="font-style: italic;"&gt;i686&lt;/span&gt; after &lt;span style="font-style: italic;"&gt;gettext&lt;/span&gt; complained about &lt;span style="font-style: italic;"&gt;x86_64&lt;/span&gt;. Yes, I had to go back and re-compile everything that was already done until that step.&lt;br /&gt;&lt;br /&gt;I like to install everything on &lt;span style="font-style: italic;"&gt;/usr/local&lt;/span&gt; so I know where my stuff is laying around. Also, I tried to find the latest version of each package in the time this blog entry was written. Some stuff is hosted on more than one "official" place and not always it is updated everywhere. So I could fail on finding the state of the art for everything here but I am probably close to that.&lt;br /&gt;&lt;br /&gt;I am not going to report any error message or to detail any problem that I faced during the process. Instead I will go direct to the point.&lt;br /&gt;&lt;h1&gt;GLIB&lt;/h1&gt;we start with &lt;span style="font-style: italic;"&gt;pkg_config&lt;/span&gt;:&lt;br /&gt;&lt;blockquote&gt;wget http://pkgconfig.freedesktop.org/releases/pkg-config-0.23.tar.gz&lt;br /&gt;tar -zxf pkg-config-0.23.tar.gz&lt;br /&gt;cd pkg-config-0.23&lt;br /&gt;./configure --prefix=/usr/local CFLAGS="-arch i686"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;then we move to &lt;span style="font-style: italic;"&gt;gettext&lt;/span&gt;, that requires &lt;span style="font-style: italic;"&gt;expat&lt;/span&gt;:&lt;br /&gt;&lt;blockquote&gt;wget http://ufpr.dl.sourceforge.net/sourceforge/expat/expat-2.0.1.tar.gz&lt;br /&gt;tar -zxf expat-2.0.1.tar.gz&lt;br /&gt;cd expat-2.0.1&lt;br /&gt;./configure --prefix=/usr/local CFLAGS="-arch i686"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;before going to &lt;span style="font-style: italic;"&gt;gettext&lt;/span&gt; we need to hack &lt;span style="font-style: italic;"&gt;emacs&lt;/span&gt; as found &lt;a href="http://blog.erikdhansen.com/"&gt;here&lt;/a&gt;:&lt;br /&gt;&lt;blockquote&gt;sudo mv /usr/bin/emacs-i386 /usr/bin/emacs-i386.backup&lt;br /&gt;sudo /usr/libexec/dumpemacs -d&lt;br /&gt;&lt;/blockquote&gt;finally &lt;span style="font-style: italic;"&gt;gettext&lt;/span&gt;:&lt;br /&gt;&lt;blockquote&gt;wget ftp://ftp.unicamp.br/pub/gnu/gettext/gettext-0.17.tar.gz&lt;br /&gt;tar -zxf gettext-0.17.tar.gz&lt;br /&gt;cd gettext-0.17&lt;br /&gt;./configure --prefix=/usr/local CFLAGS="-arch i686"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;and the last item on &lt;span style="font-style: italic;"&gt;glib&lt;/span&gt;, &lt;span style="font-style: italic;"&gt;libpng&lt;/span&gt;:&lt;br /&gt;&lt;blockquote&gt;wget http://ufpr.dl.sourceforge.net/sourceforge/libpng/libpng-1.2.25.tar.bz2&lt;br /&gt;tar -jxf libpng-1.2.25.tar.bz2&lt;br /&gt;cd libpng-1.2.25&lt;br /&gt;./configure --prefix=/usr/local CFLAGS="-arch i686"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;now &lt;span style="font-style: italic;"&gt;glib&lt;/span&gt; itself, that is by far more problematic than the libs above:&lt;br /&gt;&lt;blockquote&gt;wget http://ftp.gnome.org/pub/gnome/sources/glib/2.14/glib-2.14.6.tar.bz2&lt;br /&gt;tar -jxf glib-2.14.6.tar.bz2&lt;br /&gt;cd glib-2.14.6&lt;br /&gt;&lt;/blockquote&gt;at this point we have to &lt;a href="http://svn.macports.org/repository/macports/trunk/dports/devel/glib2/files/patch-glib_gutils.h.diff"&gt;patch&lt;/a&gt; &lt;span style="font-style: italic;"&gt;glib/gutils.h&lt;/span&gt; as seen &lt;a href="http://trac.macosforge.org/projects/macports/ticket/13006"&gt;here&lt;/a&gt;:&lt;br /&gt;&lt;blockquote&gt;--- gutils.h    2008-02-07 03:24:59.000000000 -0200&lt;br /&gt;+++ /usr/src/glib-2.14.6/glib/gutils.h  2008-03-06 16:43:34.000000000 -0300&lt;br /&gt;@@ -108,6 +108,8 @@&lt;br /&gt;#ifdef G_IMPLEMENT_INLINES&lt;br /&gt;#  define G_INLINE_FUNC&lt;br /&gt;#  undef  G_CAN_INLINE&lt;br /&gt;+#elif defined (__APPLE__)&lt;br /&gt;+#  define G_INLINE_FUNC static inline&lt;br /&gt;#elif defined (__GNUC__)&lt;br /&gt;#  if __GNUC_PREREQ (4,2) &amp;amp;&amp;amp; defined (__STDC_VERSION__) \&lt;br /&gt;&amp;amp;&amp;amp; __STDC_VERSION__ &gt;= 199901L&lt;br /&gt;&lt;/blockquote&gt;also the C compiler need some special flags. the SSE instructions have to be enabled with &lt;span style="font-style: italic;"&gt;-msse2&lt;/span&gt; which is mandatory here. I copied the other flags from the &lt;a href="http://trac.macports.org/projects/macports/browser/trunk/dports/devel/glib2/Portfile"&gt;portfile&lt;/a&gt; at MacPorts. Finally:&lt;br /&gt;&lt;blockquote&gt;./configure --prefix=/usr/local --enable-static CFLAGS="-arch i686 -msse2 -funroll-loops -fstrict-aliasing -finline-functions" LDFLAGS="-bind_at_load"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;&lt;h1&gt;GTK&lt;/h1&gt;the next is &lt;span style="font-style: italic;"&gt;atk&lt;/span&gt;:&lt;br /&gt;&lt;blockquote&gt;wget http://ftp.gnome.org/pub/gnome/sources/atk/1.21/atk-1.21.92.tar.bz2&lt;br /&gt;tar -jxf atk-1.21.92.tar.bz2&lt;br /&gt;cd atk-1.21.92&lt;br /&gt;./configure --prefix=/usr/local CFLAGS="-arch i686"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;and following &lt;span style="font-style: italic;"&gt;cairo&lt;/span&gt; deps, &lt;span style="font-style: italic;"&gt;pixman&lt;/span&gt;:&lt;br /&gt;&lt;blockquote&gt;wget http://cairographics.org/releases/pixman-0.9.6.tar.gz&lt;br /&gt;tar -zxf pixman-0.9.6.tar.gz&lt;br /&gt;cd pixman-0.9.6&lt;br /&gt;./configure --prefix=/usr/local CFLAGS="-arch i686"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;&lt;span style="font-style: italic;"&gt;freetype&lt;/span&gt;:&lt;br /&gt;&lt;blockquote&gt;wget http://download.savannah.gnu.org/releases/freetype/freetype-2.3.5.tar.bz2&lt;br /&gt;tar -jxf freetype-2.3.5.tar.bz2&lt;br /&gt;cd freetype-2.3.5&lt;br /&gt;./configure --prefix=/usr/local CFLAGS="-arch i686 -msse2"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;&lt;span style="font-style: italic;"&gt;fontconfig&lt;/span&gt;:&lt;br /&gt;&lt;blockquote&gt;wget http://fontconfig.org/release/fontconfig-2.4.92.tar.gz&lt;br /&gt;tar -zxf fontconfig-2.4.92.tar.gz&lt;br /&gt;cd fontconfig-2.4.92&lt;br /&gt;./configure --prefix=/usr/local CFLAGS="-arch i686"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;and finally &lt;span style="font-style: italic;"&gt;cairo&lt;/span&gt;. note we need again the SSE instructions plus we have to specify the location of the X development libraries. If you don't have it, refer to apple support on how to install Xcode tools and X11.&lt;br /&gt;&lt;blockquote&gt;wget http://cairographics.org/releases/cairo-1.4.14.tar.gz&lt;br /&gt;tar -zxf cairo-1.4.14.tar.gz&lt;br /&gt;cd cairo-1.4.14&lt;br /&gt;./configure --prefix=/usr/local --enable-xlib --x-includes=/usr/X11/include --x-libraries=/usr/X11/lib CFLAGS="-arch i686 -msse2"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;now that we have &lt;span style="font-style: italic;"&gt;cairo&lt;/span&gt; done, we can do &lt;span style="font-style: italic;"&gt;pango&lt;/span&gt;:&lt;br /&gt;&lt;blockquote&gt;wget http://ftp.gnome.org/pub/GNOME/sources/pango/1.19/pango-1.19.4.tar.bz2&lt;br /&gt;tar -jxf pango-1.19.4.tar.bz2&lt;br /&gt;cd pango-1.19.4&lt;br /&gt;./configure --prefix=/usr/local CFLAGS="-arch i686 -msse2"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;&lt;span style="font-style: italic;"&gt;libjpeg&lt;/span&gt; has a special rule hidden inside the &lt;span style="font-style: italic;"&gt;makefile&lt;/span&gt;, that you don't want to miss:&lt;br /&gt;&lt;blockquote&gt;wget http://www.ijg.org/files/jpegsrc.v6b.tar.gz&lt;br /&gt;tar -zxf jpegsrc.v6b.tar.gz&lt;br /&gt;cd jpeg-6b&lt;br /&gt;./configure --prefix=/usr/local CFLAGS="-arch i686"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;sudo make install-lib&lt;br /&gt;&lt;/blockquote&gt;and the last one, &lt;span style="font-style: italic;"&gt;libtiff&lt;/span&gt;:&lt;br /&gt;&lt;blockquote&gt;wget ftp://ftp.remotesensing.org/pub/libtiff/tiff-3.8.2.tar.gz&lt;br /&gt;tar -zxf tiff-3.8.2.tar.gz&lt;br /&gt;cd tiff-3.8.2&lt;br /&gt;./configure --prefix=/usr/local --with-apple-opengl-framework CFLAGS="-arch i686"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;we are now all ready to the big guy:&lt;br /&gt;&lt;blockquote&gt;wget http://ftp.gnome.org/pub/gnome/sources/gtk+/2.12/gtk+-2.12.8.tar.bz2&lt;br /&gt;tar -jxf gtk+-2.12.8.tar.bz2&lt;br /&gt;cd gtk+-2.12.8&lt;br /&gt;./configure --prefix=/usr/local --x-includes=/usr/X11/include --x-libraries=/usr/X11/lib CFLAGS="-arch i686 -msse2"&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;&lt;/blockquote&gt;and voilá ! it took me many hours to get here, I hope you can do it in minutes ;)&lt;br /&gt;&lt;br /&gt;We are not ready for &lt;span style="font-style: italic;"&gt;UMIT&lt;/span&gt; yet. We need the python bindings still. see you in the next adventure.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;update: thanks to Gregory and Antoine for pointing out the typos&lt;/b&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/9117442876284981323-3670614048867122995?l=ifeghali.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://ifeghali.blogspot.com/feeds/3670614048867122995/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=9117442876284981323&amp;postID=3670614048867122995' title='14 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/3670614048867122995'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/9117442876284981323/posts/default/3670614048867122995'/><link rel='alternate' type='text/html' href='http://ifeghali.blogspot.com/2008/03/compiling-gtk-on-mac-os-x-105-leopard.html' title='Compiling GTK+ on Mac OS X 10.5 Leopard'/><author><name>iGor Feghali</name><uri>http://www.blogger.com/profile/16943173973806079281</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp3.blogger.com/_mEndU8JPa2c/R9MhoxnXHnI/AAAAAAAAAp4/MAcUlMbPT24/S220/2108287763_d7e562d049.jpg'/></author><thr:total>14</thr:total></entry></feed>
