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

<channel>
	<title>Prateek Dayal &#187; error</title>
	<atom:link href="http://www.prateekdayal.net/category/error/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.prateekdayal.net</link>
	<description>Ruby on Rails + Web 2.0 + Life :)</description>
	<lastBuildDate>Fri, 20 May 2011 16:13:31 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Rubyworks on Debian Etch</title>
		<link>http://www.prateekdayal.net/2007/10/13/rubyworks-on-debian-etch/</link>
		<comments>http://www.prateekdayal.net/2007/10/13/rubyworks-on-debian-etch/#comments</comments>
		<pubDate>Sat, 13 Oct 2007 08:26:20 +0000</pubDate>
		<dc:creator>Prateek Dayal</dc:creator>
				<category><![CDATA[debian]]></category>
		<category><![CDATA[error]]></category>
		<category><![CDATA[etch]]></category>
		<category><![CDATA[muziboo]]></category>
		<category><![CDATA[rmagick]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[rubyonrails]]></category>
		<category><![CDATA[rubyworks]]></category>

		<guid isPermaLink="false">http://prateekdayal.net/blog/2007/10/13/rubyworks-on-debian-etch/</guid>
		<description><![CDATA[I recently got a new VPS account and it runs 64 bit Debain Etch (4.0). I installed rubyworks on it and the installation went pretty smooth. After that, I tried to move muziboo.com files to this server and a lot of error started happening in trying to get the app up. First one was muziboo@debian:~/muziboo/muz$ [...]]]></description>
			<content:encoded><![CDATA[<p>I recently got a new VPS account and it runs 64 bit Debain Etch (4.0). I installed rubyworks on it and the installation went pretty smooth. After that, I tried to move muziboo.com files to this server and a lot of error started happening in trying to get the app up.</p>
<p>First one was</p>
<p><code><br />
muziboo@debian:~/muziboo/muz$ rake db:migrate<br />
(in /home/muziboo/muziboo/muz)<br />
rake aborted!<br />
no such file to load -- hpricot<br />
</code></p>
<p>When I tried to install hpricot and that resulted in the following</p>
<p><code><br />
muziboo@debian:~/muziboo/muz$ gem install hpricot<br />
ERROR:  While executing gem ... (RuntimeError)<br />
Unsupported architecture: x86_64<br />
</code></p>
<p>To get rid of this error, I downloaded the latest rubygems package from rubyforge and the gem command started working fine. However I ran into this error now</p>
<p><code><br />
debian:~/Softwares/rubygems-0.9.4# gem install hpricot --source http://code.whytheluckystiff.net<br />
Bulk updating Gem source index for: http://code.whytheluckystiff.net<br />
Select which gem to install for your platform (x86_64-linux)<br />
1. hpricot 0.6 (mswin32)<br />
2. hpricot 0.6 (jruby)<br />
3. hpricot 0.6 (ruby)<br />
4. hpricot 0.6 (jruby)<br />
5. hpricot 0.6 (mswin32)<br />
6. hpricot 0.6 (ruby)<br />
7. Skip this gem<br />
8. Cancel installation<br />
&gt; 3<br />
Building native extensions.  This could take a while...<br />
ERROR:  While executing gem ... (Gem::Installer::ExtensionBuildError)<br />
ERROR: Failed to build gem native extension.</p>
<p>ruby extconf.rb install hpricot --source http://code.whytheluckystiff.net<br />
extconf.rb:1:in `require': no such file to load -- mkmf (LoadError)<br />
from extconf.rb:1</p>
<p>Gem files will remain installed in /usr/lib/ruby/gems/1.8/gems/hpricot-0.6 for inspection.<br />
Results logged to /usr/lib/ruby/gems/1.8/gems/hpricot-0.6/ext/hpricot_scan/gem_make.out</p>
<p></code></p>
<p>I googled around a bit and then followed <a href="http://spew.whalespine.org/tech/linux/debian/mkmfrb-on-debian/" onclick="javascript:pageTracker._trackPageview('/outbound/article/spew.whalespine.org');">this</a> post and the error disappeared but I started getting a new error about gcc missing on the system (during native extensions building stage). I installed that with apt-get install gcc-* (doing just apt-get install gcc resulted in header files missing error message).   This time the native extensions were built properly and the gem was installed.</p>
<p><!--adsense--></p>
<p>The next problem came with rmagick. I installed imagemagick and libmagick9-dev (to avoid getting a missing Magick-config error).</p>
<p>Once everything was working, I could run the app using mongrel_rails start but I could still not get it up in the rubyworks framework. I would always get a 500 error. I had symlinked /usr/rails to my app&#8217;s directory.</p>
<p>After lots of tests and experiments, I found out that rubyworks runs the processes as user rails and therefore your app&#8217;s directory should be writeable by user rails. I don&#8217;t know what is a good way to do that but I tried to make rails the owner of the app&#8217;s directory, the application started running all fine.</p>
<p>So these are some of the steps where i faced some problems and thought of writing about it. I hope someone will save some time because of this. If you do, please let me know :)</p>
<script type="text/javascript">
  addthis_url    = 'http%3A%2F%2Fwww.prateekdayal.net%2F2007%2F10%2F13%2Frubyworks-on-debian-etch%2F';
  addthis_title  = 'Rubyworks+on+Debian+Etch';
  addthis_pub    = 'prateek';
</script><script type="text/javascript" src="http://s7.addthis.com/js/addthis_widget.php?v=12" ></script>
]]></content:encoded>
			<wfw:commentRss>http://www.prateekdayal.net/2007/10/13/rubyworks-on-debian-etch/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>

