<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>. cassianoleal .</title>
	<atom:link href="http://cassianoleal.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://cassianoleal.wordpress.com</link>
	<description>tech notes of a Debian user</description>
	<lastBuildDate>Wed, 10 Aug 2011 17:35:31 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='cassianoleal.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>. cassianoleal .</title>
		<link>http://cassianoleal.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://cassianoleal.wordpress.com/osd.xml" title=". cassianoleal ." />
	<atom:link rel='hub' href='http://cassianoleal.wordpress.com/?pushpress=hub'/>
		<item>
		<title>TOra with Oracle support on Debian squeeze</title>
		<link>http://cassianoleal.wordpress.com/2011/02/21/tora-with-oracle/</link>
		<comments>http://cassianoleal.wordpress.com/2011/02/21/tora-with-oracle/#comments</comments>
		<pubDate>Mon, 21 Feb 2011 22:38:04 +0000</pubDate>
		<dc:creator>cl</dc:creator>
				<category><![CDATA[Debian]]></category>
		<category><![CDATA[Free Software]]></category>
		<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://cassianoleal.wordpress.com/?p=36</guid>
		<description><![CDATA[This is a situation that I have faced more than once: new computer, new OS install, new job, or just something that broke and I needed to start over. It happened again around september last year, when I joined ThoughtWorks: I had to compile TOra from sources to get Oracle support in it. I am [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=36&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>This is a situation that I have faced more than once: new computer, new OS install, new job, or just something that broke and I needed to start over.</p>
<p>It happened again around september last year, when I joined <a href="http://www.thoughtworks.com/">ThoughtWorks</a>: I had to compile <a href="http://torasql.com/">TOra</a> from sources to get <a href="http://www.oracle.com/index.html">Oracle</a> support in it. I am a <a href="http://www.debian.org/">Debian</a> user, so the TOra that can be installed from the repositories does not offer native support for Oracle for licensing (and <a href="http://www.debian.org/intro/free">freedom</a>) reasons. The same feature is present in the package distributed by <a href="http://www.ubuntu.com/">Ubuntu</a>.</p>
<p>If you are also trying to get Oracle support in TOra, bear with me. But before I get to the actual compilation walkthrough, note that I am running Debian squeeze 64-bit, so you may need to adapt some paths if you&#8217;re running 32-bit.</p>
<p>Also, whenever I post commands to be issued, pay attention to the prompt character. If it&#8217;s a <em>dollar sign</em> (<strong>$</strong>), the command can be run as a normal user; if it&#8217;s a <em>pound sign</em> (<strong>#</strong>), then that command must be run as <strong>root</strong>.</p>
<p>Ready? Let&#8217;s get our hands dirty, then.</p>
<h3>1. Getting and installing the Oracle software</h3>
<p>The first step is to actually get a basic Oracle client and sdk installed. Head over to the Instant Client download page (<a href="http://www.oracle.com/technetwork/topics/linuxx86-64soft-092277.html">64-bit</a>|<a href="http://www.oracle.com/technetwork/topics/linuxsoft-082809.html">32-bit</a>). You might need to create a user before downloading anything from there.</p>
<p>To me, the easiest way to get these installed is to download the RPMs and converting them with alien. The packages you&#8217;ll need are:</p>
<ul>
<li><strong>Instant Client Package &#8211; Basic</strong> or <strong>Basic Lite</strong> (This is the client that will handle the connections to the server. The difference between the versions is that the <strong>Basic Lite</strong> one is only in English and its filesize is smaller);</li>
<li><strong>Instant Client Package &#8211; SQL*Plus</strong> (Excellent for testing the installation and running PL/SQL scripts from the CLI);</li>
<li><strong>Instant Client Package &#8211; SDK</strong> (Needed for compiling TOra).</li>
</ul>
<p>Once you have downloaded the packages, head to the directory where you saved them and execute the following line of code (you need to have <strong>fakeroot</strong>, <strong>alien</strong> and <strong>rpm</strong> installed beforehand):</p>
<p><code>$ for n in $(ls oracle-*.rpm); do fakeroot alien $n; done;</code></p>
<p>Then, as root (or using <strong>sudo</strong>):</p>
<p><code># dpkg -i *.deb</code></p>
<p>The installation will be split into two separate trees: one for the binary blobs, and one for the SDK. The binaries are placed under <strong>/usr/lib/oracle/&lt;version&gt;/client[64]</strong>, while the SDK is under <strong>/usr/include/oracle/&lt;version&gt;/client[64]</strong>. I am using Oracle version 11.2 64-bit, so my dirs are:</p>
<ul>
<li>/usr/lib/oracle/11.2/client64</li>
<li>/usr/include/oracle/11.2/client64</li>
</ul>
<p>From now on, these are the directories that I will be using on the post. Please adapt whenever necessary.</p>
<p>Next step is to create a symbolic link inside the libs dir that will point to the SDK:</p>
<p><code style="white-space:nowrap;"># ln -s /usr/include/oracle/11.2/client64 /usr/lib/oracle/11.2/client64/include</code></p>
<p>Now, add some environment variables to your <strong>~/.bashrc</strong> file:</p>
<p><code style="white-space:nowrap;">export ORACLE_BASE=/usr/lib/oracle/11.2<br />
export ORACLE_HOME=$ORACLE_BASE/client64<br />
export PATH=$PATH:$ORACLE_HOME/bin<br />
export TNS_ADMIN=/etc/oracle<br />
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/include/oracle/11.2/client64:/usr/lib/oracle/11.2/client64/lib</code></p>
<p>Note that the last variable is pointing to <strong>/etc/oracle</strong>. You can point this to whatever directory you want. This variable tells the Oracle client where your <strong>TNSNAMES.ORA</strong> file is located (if you have one), so point it to wherever you will put the file.</p>
<p>Now, either open a new bash session, or just <em>source</em> your <strong>.bashrc</strong> file to initialise the variables:</p>
<p><code>$ source ~/.bashrc</code></p>
<h3>2. Getting, building and installing TOra</h3>
<p>Now you&#8217;ll probably want to get the TOra sources from your package manager, so first create a directory where the sources will be downloaded to and enter it. Then get the sources and dependencies:</p>
<p><code>$ apt-get source tora<br />
(...) Sources downloaded</code></p>
<p>And as root:</p>
<p><code># apt-get build-dep tora</code></p>
<p>Debian squeeze has TOra version 2.1.2, so:</p>
<p><code>$ cd tora-2.1.2<br />
$ dpkg-buildpackage -us -uc -rfakeroot</code></p>
<p>Wait until compilation finishes. If all goes well, you&#8217;ll find a <strong>.deb</strong> package waiting to be installed in the parent directory:</p>
<p><code style="white-space:nowrap;">$ cd ..<br />
# dpkg -i tora_2.1.2-1_amd64.deb <span style="color:#808080;">## as root!</span></code></p>
<p>After installing the package, it&#8217;s time to try out and see if you have Oracle support. Run the software</p>
<p><code>$ tora</code></p>
<p>If it complains about not being able to load <strong>libaio.so.1</strong>, you have to install the package <strong>libaio1</strong> and try again.</p>
<p>Now, check that you see <em>Oracle</em> in the <em>Connection Provider</em> dropdown:</p>
<p><img title="Oracle Connection Provider" src="http://cassianoleal.files.wordpress.com/2011/02/tora_with_oracle.png?w=510" alt="" /></p>
<p>If so, compilation and installation is finished. Now it&#8217;s time to put a <strong>TNSNAMES.ORA</strong> in the <strong>$TNS_ADMIN</strong> directory and restart the software.</p>
<p>It&#8217;s also a good idea to put the package <em>on hold</em>, so that it does not get overwritten by the distro package during your next update:</p>
<p><code># echo "tora hold" | dpkg --set-selections</code></p>
<p style="padding-left:30px;"><strong>Update per Matt Fischer&#8217;s suggestion:</strong> If <em>aptitude</em> is ignoring the &#8220;hold&#8221; command given to dpkg above, try</p>
<p style="padding-left:30px;"><code># aptitude hold tora<br />
</code></p>
<p style="padding-left:30px;"><strong>Update:</strong> If you get complaints about <strong>missing dependencies on libclntsh.so</strong>, please refer to the comment by <strong>mehturt</strong> on August 10 2011 below.</p>
<p>You&#8217;re ready to rock!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/cassianoleal.wordpress.com/36/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/cassianoleal.wordpress.com/36/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/cassianoleal.wordpress.com/36/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/cassianoleal.wordpress.com/36/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/cassianoleal.wordpress.com/36/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/cassianoleal.wordpress.com/36/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/cassianoleal.wordpress.com/36/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/cassianoleal.wordpress.com/36/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/cassianoleal.wordpress.com/36/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/cassianoleal.wordpress.com/36/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/cassianoleal.wordpress.com/36/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/cassianoleal.wordpress.com/36/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/cassianoleal.wordpress.com/36/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/cassianoleal.wordpress.com/36/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=36&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://cassianoleal.wordpress.com/2011/02/21/tora-with-oracle/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">cassiano leal</media:title>
		</media:content>

		<media:content url="http://cassianoleal.files.wordpress.com/2011/02/tora_with_oracle.png" medium="image">
			<media:title type="html">Oracle Connection Provider</media:title>
		</media:content>
	</item>
		<item>
		<title>pdo_oci the Debian way (as much as possible)</title>
		<link>http://cassianoleal.wordpress.com/2009/03/31/pdo_oci-the-debian-way-almost/</link>
		<comments>http://cassianoleal.wordpress.com/2009/03/31/pdo_oci-the-debian-way-almost/#comments</comments>
		<pubDate>Tue, 31 Mar 2009 22:22:56 +0000</pubDate>
		<dc:creator>cl</dc:creator>
				<category><![CDATA[Debian]]></category>

		<guid isPermaLink="false">http://cassianoleal.wordpress.com/?p=22</guid>
		<description><![CDATA[If you need generic instructions on how to compile a PHP5 module on Debian, please follow this link. For pdo_oci you need to depart a bit from the canonical way. Follow these instructions in order to get a nicely built and installable debian package for it. Note that you need to have an Oracle client [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=22&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>If you need generic instructions on how to compile a PHP5 module on Debian, please follow <a href="http://cassianoleal.wordpress.com/2009/01/14/compiling-php5-modules-in-debian/">this link</a>.</p>
<p>For pdo_oci you need to depart a bit from the canonical way. Follow these instructions in order to get a nicely built and installable debian package for it. Note that you need to have an Oracle client properly installed and configured for this module to be useful.</p>
<p>Below is a simple cake recipe for achieving that. Please modify according to your needs.</p>
<p><code>mkdir -p ~/src/php5<br />
cd ~/src/php5<br />
apt-get source php5<br />
cd php5-5.2.6.dfsg.1/ext/pdo_oci<br />
pecl package package2.xml</code></p>
<p>These steps will have generated a PDO_OCI-1.0.1.tgz archive. Now you want to make this package debian-ready. Begin by issuing the following command (found in the package dh-make-php):</p>
<p><code>dh-make-pecl --only 5 PDO_OCI-1.0.1.tgz</code></p>
<p>Now comes the magic. Enter the newly created directory php-pdo-oci-1.0.1 and edit the file debian/rules:</p>
<p><code>cd php-pdo-oci-1.0.1<br />
vi debian/rules</code></p>
<p>Find the line that declares the constant PECL_PKG_NAME and change it from</p>
<p><code>PECL_PKG_NAME=pdo-oci</code></p>
<p>to</p>
<p><code>PECL_PKG_NAME=pdo_oci</code></p>
<p>Now look for the block</p>
<p><code>configure-stamp-v4 configure-stamp-v5:</code></p>
<p>There, right after the line that says</p>
<p><code>$(PHPIZE)$*; \</code></p>
<p>insert these lines:</p>
<p><code>sed -e 's/prefix\/include\/php\/ext/prefix\/include\/php5\/ext/' configure &gt; /tmp/pdo_oci-configure; \<br />
cp /tmp/pdo_oci-configure ./configure; \</code></p>
<p>Save the file and proceed with package creation:</p>
<p><code>dpkg-buildpackage -rfakeroot -us -uc</code></p>
<p>If no errors are reported, you will have just created a debian package into .. for pdo_oci ready to be installed by dpkg.</p>
<p><strong>UPDATE</strong>: If you are having problems with your Oracle libs and/or includes not being found, try installing the instantclient packages (alien them from the RPMs found on Oracle&#8217;s downloads website). Here I am using the 11.2 x86_64 client. If yours differ, please adjust the paths accordingly.</p>
<p>First, make a symbolic link:</p>
<p><code># cd /usr/lib/oracle/11.2/client64<br />
# ln -s /usr/include/oracle/11.2/client64 ./include</code></p>
<p>Then, set some environment variables:</p>
<p><code>export ORACLE_BASE=/usr/lib/oracle/11.2<br />
export ORACLE_HOME=$ORACLE_BASE/client64</code></p>
<p>And you should be good to go!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/cassianoleal.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/cassianoleal.wordpress.com/22/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/cassianoleal.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/cassianoleal.wordpress.com/22/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/cassianoleal.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/cassianoleal.wordpress.com/22/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/cassianoleal.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/cassianoleal.wordpress.com/22/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/cassianoleal.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/cassianoleal.wordpress.com/22/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/cassianoleal.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/cassianoleal.wordpress.com/22/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/cassianoleal.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/cassianoleal.wordpress.com/22/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=22&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://cassianoleal.wordpress.com/2009/03/31/pdo_oci-the-debian-way-almost/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">cassiano leal</media:title>
		</media:content>
	</item>
		<item>
		<title>Ardour in need of support from the community</title>
		<link>http://cassianoleal.wordpress.com/2009/02/08/ardour-in-need-of-support-from-the-community/</link>
		<comments>http://cassianoleal.wordpress.com/2009/02/08/ardour-in-need-of-support-from-the-community/#comments</comments>
		<pubDate>Sun, 08 Feb 2009 14:57:36 +0000</pubDate>
		<dc:creator>cl</dc:creator>
				<category><![CDATA[Free Software]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Music]]></category>

		<guid isPermaLink="false">http://cassianoleal.wordpress.com/?p=18</guid>
		<description><![CDATA[This will be a quick post on a subject that I think needs great attention from the music and the FOSS communities. Ardour (http://www.ardour.org/) is a fantastic free DAW (Digital Audio Workstation) software. It aims to meet and supercede commercial DAW features, like Cubase, Logic and others. It already is a great tool (the latest [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=18&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>This will be a quick post on a subject that I think needs great attention from the music and the FOSS communities.</p>
<p>Ardour (<a href="http://www.ardour.org/">http://www.ardour.org/</a>) is a fantastic free DAW (Digital Audio Workstation) software. It aims to meet and supercede commercial DAW features, like Cubase, Logic and others. It already is a great tool (the latest one that I have used was 2.0 &#8212; current stable release is 2.7.1 while 3.0 is already in the works) and many people of the FOSS community benefit from it.</p>
<p>It just came to me today as sad news that the company that was supporting the project, SAE, is now discontinuing this much needed support, leaving Paul, Ardour’s lead developer, in <a href="http://www.ardour.org/node/2406">need for a job</a> and thus less attentious to the project.</p>
<p>Many people are already moving fingers to help the project, but it certainly needs much more help. One way to help is to spread the word (like I am doing, as I currently don&#8217;t have the means to support financially the project), another is to make donations or to subscribe to their donation plan. More info can be found in their <a href="http://www.ardour.org/">home page</a>.</p>
<p>Please do not let the best FOSS DAW die.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/cassianoleal.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/cassianoleal.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/cassianoleal.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/cassianoleal.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/cassianoleal.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/cassianoleal.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/cassianoleal.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/cassianoleal.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/cassianoleal.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/cassianoleal.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/cassianoleal.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/cassianoleal.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/cassianoleal.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/cassianoleal.wordpress.com/18/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=18&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://cassianoleal.wordpress.com/2009/02/08/ardour-in-need-of-support-from-the-community/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">cassiano leal</media:title>
		</media:content>
	</item>
		<item>
		<title>Compiling PHP5 modules in Debian</title>
		<link>http://cassianoleal.wordpress.com/2009/01/14/compiling-php5-modules-in-debian/</link>
		<comments>http://cassianoleal.wordpress.com/2009/01/14/compiling-php5-modules-in-debian/#comments</comments>
		<pubDate>Wed, 14 Jan 2009 17:12:29 +0000</pubDate>
		<dc:creator>cl</dc:creator>
				<category><![CDATA[Debian]]></category>
		<category><![CDATA[lenny]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[oracle]]></category>
		<category><![CDATA[pdo]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://cassianoleal.wordpress.com/?p=15</guid>
		<description><![CDATA[Hey! This post explains my first attempts in getting PDO_OCI installed in Debian. Even though it works and has served me quite well for some time, now I&#8217;ve found a way to make actual .deb packages of these modules so I can save them for later use (or distribution, as long as their source code [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=15&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Hey!</p>
<p><a href="http://cassianoleal.wordpress.com/2008/03/03/how-i-managed-to-install-pdo_oci-under-debianlenny/" target="_self">This post</a> explains my first attempts in getting PDO_OCI installed in Debian. Even though it works and has served me quite well for some time, now I&#8217;ve found a way to make actual .deb packages of these modules so I can save them for later use (or distribution, as long as their source code goes along) and have them installed in a sane way via the package manager.</p>
<p>So, first things first. You have to download php5 source (apt-get source php5) and its build dependencies (apt-get build-dep php5). Next thing is to build the extension you need.</p>
<p>I&#8217;ll take PDO for an example.</p>
<p>First, enter the extension&#8217;s directory:<br />
<code>cd php5-5.2.6.dfsg.1/ext/pdo</code><br />
Now, look for a .xml file in this directory. In this case, it is called package2.xml. It contains the extension&#8217;s package description. Now, build a .tgz of the extension:<br />
<code>pecl package package2.xml</code><br />
It will generate a PDO-1.0.3.tgz file. Now, create a Debian package source for this archive:<br />
<code>dh-make-pecl --only 5 PDO-1.0.3.tgz</code><br />
The &#8211;only 5 parameter tells the script builder to make only the php5 package (not php4). Next step is to build the package:<br />
<code>cd php-pdo-1.0.3<br />
fakeroot debian/rules binary</code><br />
If all goes well, there&#8217;s a ../php5-pdo_1.0.3-1_i386.deb file, ready to be installed!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/cassianoleal.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/cassianoleal.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/cassianoleal.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/cassianoleal.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/cassianoleal.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/cassianoleal.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/cassianoleal.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/cassianoleal.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/cassianoleal.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/cassianoleal.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/cassianoleal.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/cassianoleal.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/cassianoleal.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/cassianoleal.wordpress.com/15/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=15&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://cassianoleal.wordpress.com/2009/01/14/compiling-php5-modules-in-debian/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">cassiano leal</media:title>
		</media:content>
	</item>
		<item>
		<title>One more try on the mach64</title>
		<link>http://cassianoleal.wordpress.com/2008/03/08/one-more-try-on-the-mach64/</link>
		<comments>http://cassianoleal.wordpress.com/2008/03/08/one-more-try-on-the-mach64/#comments</comments>
		<pubDate>Sat, 08 Mar 2008 18:15:53 +0000</pubDate>
		<dc:creator>cl</dc:creator>
				<category><![CDATA[Debian]]></category>

		<guid isPermaLink="false">http://cassianoleal.wordpress.com/?p=9</guid>
		<description><![CDATA[Still tryin to get DRI and Composite on my mach64, I bumped on this site: http://ubuntuforums.org/showpost.php?p=3264969&#38;postcount=6. I have somewhat adapted some of the steps to simplify and better organise things. First thing is to get the latest xf86-video-ati driver from http://xorg.freedesktop.org/archive/individual/driver/ and untar it to ~/src. If you have no such directory, create it first. [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=9&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Still tryin to get DRI and Composite on my mach64, I bumped on this site: <a href="http://ubuntuforums.org/showpost.php?p=3264969&amp;postcount=6">http://ubuntuforums.org/showpost.php?p=3264969&amp;postcount=6</a>. I have somewhat adapted some of the steps to simplify and better organise things.</p>
<p>First thing is to get the latest xf86-video-ati driver from <a href="http://xorg.freedesktop.org/archive/individual/driver/">http://xorg.freedesktop.org/archive/individual/driver/</a> and untar it to <strong>~/src</strong>. If you have no such directory, create it first.</p>
<p>Then, get the headers for your running kernel and the build-essential: <strong>apt-get install linux-headers-`uname -r` build-essential</strong>.</p>
<p>Create a <strong>~/src/drm-git</strong> directory and run <strong>git clone git://anongit.freedesktop.org/git/mesa/drm</strong> from inside it. This will get the latest drm drivers from upstream.</p>
<p>$ cd drm/linux-core</p>
<p>$ make DRM_MODULES=&#8221;mach64&#8243; </p>
<p>$ sudo cp *.ko /lib/modules/`uname -r`/kernel/drivers/char/drm/</p>
<p>$ sudo depmod -a</p>
<p>$ sudo modprobe mach64</p>
<p>(&#8230;)</p>
<p>$ cd ~/src/xf86-video-ati-6.8.0</p>
<p>$ ./configure &#8211;prefix=/usr</p>
<p>$ make</p>
<p>$ sudo make install</p>
<p>$ sudo /etc/init.d/gdm restart</p>
<p>(to be continued&#8230;)</p>
<p>$ glxinfo | grep direct<br />
direct rendering: No (If you want to find out why, try setting LIBGL_DEBUG=verbose)</p>
<p>$ LIBGL_DEBUG=verbose glxinfo<br />
name of display: :0.0<br />
libGL: XF86DRIGetClientDriverName: 6.7.0 mach64 (screen 0)<br />
libGL: OpenDriver: trying /usr/X11R6/lib/modules/dri/mach64_dri.so<br />
libGL error: dlopen /usr/X11R6/lib/modules/dri/mach64_dri.so failed (/usr/X11R6/lib/modules/dri/mach64_dri.so: cannot open shared object file: No such file or directory)<br />
libGL error: unable to find driver: mach64_dri.so<br />
display: :0  screen: 0<br />
direct rendering: No (If you want to find out why, try setting LIBGL_DEBUG=verbose)<br />
(&#8230;)</p>
<p>The file mach64_dri.so is in the package <strong>libgl1-mesa-dri</strong>. If you don&#8217;t have it installed, <strong>aptitude install libgl1-mesa-dri</strong>. This might not be enough, though, as the dri libs are not in /usr/X11R6/lib/modules/dri, but rather in /usr/lib/dri. What I did to correct this issue was to check that /usr/X11R6/lib/modules/dri was empty, then:</p>
<p>$ sudo rmdir /usr/X11R6/lib/modules/dri<br />
$ sudo ln -s /usr/lib/dri /usr/X11R6/lib/modules/dri</p>
<p>And finaly:</p>
<p>$ glxinfo | grep direct<br />
DISPATCH ERROR! _glapi_add_dispatch failed to add glAreTexturesResident!<br />
DISPATCH ERROR! _glapi_add_dispatch failed to add glGenTextures!<br />
DISPATCH ERROR! _glapi_add_dispatch failed to add glIsTexture!<br />
do_wait: drmWaitVBlank returned -1, IRQs don&#8217;t seem to be working correctly.<br />
Try running with LIBGL_THROTTLE_REFRESH and LIBL_SYNC_REFRESH unset.<br />
direct rendering: Yes</p>
<p>Yay! That&#8217;s it! Now, to get the transparent terminal&#8230;</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/cassianoleal.wordpress.com/9/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/cassianoleal.wordpress.com/9/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/cassianoleal.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/cassianoleal.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/cassianoleal.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/cassianoleal.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/cassianoleal.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/cassianoleal.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/cassianoleal.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/cassianoleal.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/cassianoleal.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/cassianoleal.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/cassianoleal.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/cassianoleal.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/cassianoleal.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/cassianoleal.wordpress.com/9/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=9&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://cassianoleal.wordpress.com/2008/03/08/one-more-try-on-the-mach64/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">cassiano leal</media:title>
		</media:content>
	</item>
		<item>
		<title>How to get the C-Cedilla on GNOME</title>
		<link>http://cassianoleal.wordpress.com/2008/03/04/how-to-get-the-c-cedilla-on-gnome/</link>
		<comments>http://cassianoleal.wordpress.com/2008/03/04/how-to-get-the-c-cedilla-on-gnome/#comments</comments>
		<pubDate>Tue, 04 Mar 2008 23:41:53 +0000</pubDate>
		<dc:creator>cl</dc:creator>
				<category><![CDATA[Debian]]></category>
		<category><![CDATA[Free Software]]></category>
		<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://cassianoleal.wordpress.com/?p=8</guid>
		<description><![CDATA[I have been through a lot of trouble to get c-cedilla (cê-cedilha, in portuguese) as the default for &#8216; + c (accute accent + c) on GNOME. In case you don&#8217;t know what I am talking about, this is what the character looks like: ç. Turns out that if I set my language to portuguese, [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=8&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I have been through a lot of trouble to get c-cedilla (<em>cê-cedilha</em>, in portuguese) as the default for &#8216; + c (accute accent + c) on GNOME. In case you don&#8217;t know what I am talking about, this is what the character looks like: <strong>ç</strong>.</p>
<p>Turns out that if I set my language to portuguese, I do get the cedilla by default. The problem is that I really prefer to have my system in english, and with this language I get this character by default: <strong>ć</strong>.</p>
<p>After reading a bit, I found the <em>gtk-query-immodules-2.0</em> command, which I have used this way:</p>
<pre>$ gtk-query-immodules-2.0 | grep cedilla
"/usr/lib/gtk-2.0/2.10.0/immodules/im-cedilla.so"
"cedilla" "Cedilla" "gtk20" "/usr/share/locale" "az:ca:co:fr:gv:oc:pt:sq:tr:wa"</pre>
<p>This tells me which languages will have the c-cedilla behaviour by default. After some more research I found <a href="http://ubuntuforums.org/showthread.php?t=594736">this link</a> which pointed me to the file <em>/usr/lib/gtk-2.0/2.10.0/immodule-files.d/libgtk2.0-0.immodules</em>. I have edited the cedilla section of this file by adding<br />
<blockquote>:en</p></blockquote>
<p> to the end of the languages array, like this:</p>
<pre>"/usr/lib/gtk-2.0/2.10.0/immodules/im-cedilla.so"
"cedilla" "Cedilla" "gtk20" "/usr/share/locale" "az:ca:co:fr:gv:oc:pt:sq:tr:wa:en"</pre>
<p>This should be enough. When I restart X I will post the results here.</p>
<p><strong>Update:</strong> Yes, it did! Just as a reminder, it is also necessary to choose the international variant of your keyboard. To do that, go to System / Preferences / Keyboard, open the <em>Layouts</em> tab, click on <em>Add</em> and choose your layout (United Kingdom, in my case) and Variation: <em>International (with dead keys)</em>.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/cassianoleal.wordpress.com/8/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/cassianoleal.wordpress.com/8/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/cassianoleal.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/cassianoleal.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/cassianoleal.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/cassianoleal.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/cassianoleal.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/cassianoleal.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/cassianoleal.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/cassianoleal.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/cassianoleal.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/cassianoleal.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/cassianoleal.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/cassianoleal.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/cassianoleal.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/cassianoleal.wordpress.com/8/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=8&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://cassianoleal.wordpress.com/2008/03/04/how-to-get-the-c-cedilla-on-gnome/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">cassiano leal</media:title>
		</media:content>
	</item>
		<item>
		<title>DRI on an old ATI mach64 card</title>
		<link>http://cassianoleal.wordpress.com/2008/03/04/dri-on-an-old-ati-mach64-card/</link>
		<comments>http://cassianoleal.wordpress.com/2008/03/04/dri-on-an-old-ati-mach64-card/#comments</comments>
		<pubDate>Tue, 04 Mar 2008 11:51:21 +0000</pubDate>
		<dc:creator>cl</dc:creator>
				<category><![CDATA[Debian]]></category>
		<category><![CDATA[Free Software]]></category>
		<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://cassianoleal.wordpress.com/?p=7</guid>
		<description><![CDATA[So, here I go trying to get some transparency on my old laptop. I have done it in the past, so I know it is posible. The laptop is a VM7000 made by RM. It has a Coppermine Celeron 500MHz and it had originally 128MB of RAM. I have recently increased that to 256, which [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=7&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>So, here I go trying to get some transparency on my old laptop. I have done it in the past, so I know it is posible.</p>
<p>The laptop is a VM7000 made by RM. It has a Coppermine Celeron 500MHz and it had originally 128MB of RAM. I have recently increased that to 256, which is the maximum it supports.</p>
<p>The video card, according to lspci, is a &#8220;VGA compatible controller: ATI Technologies Inc 3D Rage LT Pro (rev dc)&#8221;. It uses the mach64 driver. My goal here is to get DRI working on it so I can have drop shadows and real translucency for the terminal windows (I know it is rather useless, but it looks cool).</p>
<p>The system is an up-to-date Debian Lenny. To achieve this objective, I am mostly being guided by this thread on the Ubuntu Forums: <a href="http://ubuntuforums.org/showthread.php?t=7200">http://ubuntuforums.org/showthread.php?t=7200</a>.</p>
<p>So far, I have accomplished steps 1 &#8211; 5. The install.sh script in the mach64 directory has given trouble. First, by looking at the dri.log file generated by the script, I have found that it is trying to find a linux/config.h in the kernel headers directory. It is not there because it has been deprecated. By following <a href="http://www.mail-archive.com/pwc@lists.saillard.org/msg00501.html">this tip</a> I have managed to get past all the config.h errors by substituting it by autoconf.h in all files that were trying to include it.</p>
<p>This, though, has led me to another error, a quite esoteric one: &#8220;error: size of array ‘type name’ is negative&#8221;.</p>
<p>After reading <a href="http://lkml.org/lkml/2007/5/10/461">this</a> I have decided to recompile my kernel with </p>
<blockquote><p>CONFIG_PHYSICAL_START=0&#215;200000</p></blockquote>
<p>I know that the solution mentioned in the link is about x64 and this laptop is definitely not 64 bit, but I guess it&#8217;s worth the shot. It might just work.</p>
<p><strong>Update:</strong> No, it didn&#8217;t. After recompiling the kernel, the install.sh script of mach64 still gave the same error. I&#8217;ll keep trying and will keep posting the results here.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/cassianoleal.wordpress.com/7/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/cassianoleal.wordpress.com/7/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/cassianoleal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/cassianoleal.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/cassianoleal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/cassianoleal.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/cassianoleal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/cassianoleal.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/cassianoleal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/cassianoleal.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/cassianoleal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/cassianoleal.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/cassianoleal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/cassianoleal.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/cassianoleal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/cassianoleal.wordpress.com/7/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cassianoleal.wordpress.com&amp;blog=1005445&amp;post=7&amp;subd=cassianoleal&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://cassianoleal.wordpress.com/2008/03/04/dri-on-an-old-ati-mach64-card/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">cassiano leal</media:title>
		</media:content>
	</item>
	</channel>
</rss>
