<?xml version="1.0" encoding="UTF-8"?>
<feed xml:lang="en-US" xmlns="http://www.w3.org/2005/Atom">
  <title>UK Ruby on Rails, Exalead, AWS, Consultancy - Using SQLite3 and MySQL on Windows Comments</title>
  <id>tag:thewebfellas.com,2011:/blog/2009/4/18/using-sqlite3-and-mysql-on-windows/comments</id>
  <generator version="0.7.3" uri="http://mephistoblog.com">Mephisto Noh-Varr</generator>
  <link href="http://thewebfellas.com/blog/2009/4/18/using-sqlite3-and-mysql-on-windows/comments.xml" rel="self" type="application/atom+xml"/>
  <link href="/blog/2009/4/18/using-sqlite3-and-mysql-on-windows" rel="alternate" type="text/html"/>
  <updated>2009-07-25T21:59:05Z</updated>
  <entry xml:base="http://thewebfellas.com/">
    <author>
      <name>Rob Anderton</name>
    </author>
    <id>tag:thewebfellas.com,2009-04-18:3671:7852</id>
    <published>2009-07-25T21:59:05Z</published>
    <updated>2009-07-25T21:59:05Z</updated>
    <category term="Blog"/>
    <link href="http://thewebfellas.com/blog/2009/4/18/using-sqlite3-and-mysql-on-windows" rel="alternate" type="text/html"/>
    <title>Comment on 'Using SQLite3 and MySQL on Windows' by Rob Anderton</title>
<content type="html">&lt;p&gt;Luis has just released version 1.2.5 of the SQLite gem with added Windows goodness: you can take a look &lt;a href=&quot;http://blog.mmediasys.com/2009/07/25/sqlite3-ruby-1-2-5-released/&quot; title=&quot;Check it out&quot;&gt;here&lt;/a&gt;.&lt;/p&gt;</content>  </entry>
  <entry xml:base="http://thewebfellas.com/">
    <author>
      <name>will</name>
    </author>
    <id>tag:thewebfellas.com,2009-04-18:3671:7342</id>
    <published>2009-07-07T08:15:15Z</published>
    <updated>2009-07-07T08:15:15Z</updated>
    <category term="Blog"/>
    <link href="http://thewebfellas.com/blog/2009/4/18/using-sqlite3-and-mysql-on-windows" rel="alternate" type="text/html"/>
    <title>Comment on 'Using SQLite3 and MySQL on Windows' by will</title>
<content type="html">&lt;p&gt;Greetings ...&lt;/p&gt;

&lt;p&gt;Yes I has that same problem with SQLite compile and later with ParseTree, not to mention several other gem packages that I didn't/couldn't bother investigate because of the C broken c compile.&lt;/p&gt;

&lt;p&gt;Fortunately Tim on merb-talk pointed me to this blog on here:&lt;/p&gt;

&lt;p&gt;http://thewebfellas.com/blog/2007/12/2/imagescience-and-rubyinline-on-windows
   ~ Rob Anderton&lt;/p&gt;

&lt;p&gt;It is a good start to get a compile, and not the whole story.  In my book there are two responsible chunks of code here.  The ruby platform config targets machines, it needs to target compilers.  I spent the better part of my life ensuring code worked on 4 or 5 Pascal, C, and C++ compilers,  for different platforms and operating systems.  Targeting an operating system as if it is a static entity is not practical &lt;em&gt;imho&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;The helpful bit is to look at your ruby config file and the config.h files (per Rob Anderton blog).&lt;/p&gt;

&lt;p&gt;The second bit is the RubyInline code itself.  The diagnostics can be more helpful to figure out what is happening, &lt;em&gt;imho&lt;/em&gt;.  As a general aside on a lot of code, closed and open source.  My distinction between 'a-programmer' and 'a-coder' is that coders are optimistic and programmers consider what goes wrong first; they don't simply write code as-if it will &lt;em&gt;&lt;strong&gt;just work&lt;/strong&gt;&lt;/em&gt; all the time.  &lt;/p&gt;

&lt;p&gt;That later point includes these problematic Gems that optimistically look at the C compile working, instead of finding a way to test it works.  I can paraphrase one bug response that said, &lt;em&gt;not interested in wasting time supporting a brain-dead windows&lt;/em&gt; for that gem.  Which is fair enough.  Everyone volunteers time on Open Source, ... It is that person's right.  &lt;/p&gt;

&lt;p&gt;Why not include &quot;might not work on Windows&quot; in the manifest? If that's the contract with the 'consuming' developer public.  &lt;/p&gt;

&lt;p&gt;On the helpful side, RubyInline (&lt;em&gt;internally&lt;/em&gt;) seem have old-fashioned ideas on the compile and link requirements.  In my case I'm still working out the parameters for MS Express 2008 that work for the gems.  The RubyInline test cases work OK.  Unfortunately all I can say for now, is if your problem isn't solved with Rob Anderton's blog and a few updates on compile switches; make a copy of RubyInline.rb and add some &lt;em&gt;puts&lt;/em&gt; lines to figure out what you need to do (or email me, in case I got lucky and things compile for me).&lt;/p&gt;

&lt;p&gt;One 'more' thing.  I almost forgot why I took time-out of a very frustrating day to comment.  I use the ...&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;gem install sqlite3-ruby -v1.2.3
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;v1.2.3 gem myself, and I worked that out almost by accident.  However, given my other challenges, I took at look at the SQLite v1.2.3 gem '&lt;em&gt;make&lt;/em&gt;', the reason it works is because it doesn't compile, it uses the Windows dynamic library infrastructure the way it was meant to work.&lt;/p&gt;

&lt;p&gt;Also, there's no functional difference between 1.2.3 and 1.2.4.  It is all cosmetic.&lt;/p&gt;

&lt;p&gt;I'd like to encourage readers to lobby for a &quot;&lt;strong&gt;--nomake&lt;/strong&gt;&quot; gem option that will probably allow most of us to get on with out lives, reducing the unnecessary compile stages to a number approaching zero.&lt;/p&gt;

&lt;p&gt;Plan B in my &lt;em&gt;world domination&lt;/em&gt; by good practice is to encourage gem builders to compile in the sensible DLL-s or lib.a for the target machine (rubyconfig).&lt;/p&gt;

&lt;p&gt;Argue the point with your friends.  On my side of &quot;&lt;em&gt;life&lt;/em&gt;&quot; I took up marketing to learn how, among other things, &quot;how come open source sells less than &lt;em&gt;you know who&lt;/em&gt;?&quot;  This example and Rob A's blog are good example '&lt;em&gt;of why&lt;/em&gt;'.&lt;/p&gt;

&lt;p&gt;AND gentle reader, I leave that riddle for you to ponder.  Before answering it later.  If you want my opinion or even what the research shows, visit my blog and ask questions.&lt;/p&gt;

&lt;p&gt;Aloha,
       Will&lt;/p&gt;</content>  </entry>
  <entry xml:base="http://thewebfellas.com/">
    <author>
      <name>Toni</name>
    </author>
    <id>tag:thewebfellas.com,2009-04-18:3671:4403</id>
    <published>2009-04-30T12:34:45Z</published>
    <updated>2009-04-30T12:34:45Z</updated>
    <category term="Blog"/>
    <link href="http://thewebfellas.com/blog/2009/4/18/using-sqlite3-and-mysql-on-windows" rel="alternate" type="text/html"/>
    <title>Comment on 'Using SQLite3 and MySQL on Windows' by Toni</title>
<content type="html">&lt;p&gt;Hi Michael,&lt;/p&gt;

&lt;p&gt;I am running now Rails 2.3.2 on Ruby 1.8.7-p72 for Windows Vista-32 with MySQL 5.1.34 with the mysql-gem 2.7.3.&lt;/p&gt;

&lt;p&gt;I have been running also into the same problems as you did and solved it also with this older version of the client library DLL. During the installation of mysql I told him to configure the PATH environment variable.
I just made a little application with the scaffold and everything seems now to work. Hopefully it stays like that.
I didnt installed again the GUI Tools of MySQL, because there is also the DLL included. I will install the GUI Tool later to see if it irritates my system.&lt;/p&gt;

&lt;p&gt;Sometimes the Rails Installation can give you a hard time :-)&lt;/p&gt;

&lt;p&gt;Cheers&lt;/p&gt;</content>  </entry>
  <entry xml:base="http://thewebfellas.com/">
    <author>
      <name>Luis Lavena</name>
    </author>
    <id>tag:thewebfellas.com,2009-04-18:3671:4150</id>
    <published>2009-04-18T15:16:01Z</published>
    <updated>2009-04-18T15:16:01Z</updated>
    <category term="Blog"/>
    <link href="http://thewebfellas.com/blog/2009/4/18/using-sqlite3-and-mysql-on-windows" rel="alternate" type="text/html"/>
    <title>Comment on 'Using SQLite3 and MySQL on Windows' by Luis Lavena</title>
<content type="html">&lt;p&gt;Good post Michael!&lt;/p&gt;

&lt;p&gt;Work has been made in this front, for those bugs and compilation issues. See both forks of mysql-gem and sqlite3-ruby at GitHub:&lt;/p&gt;

&lt;p&gt;http://github.com/luislavena/sqlite3-ruby/tree/master&lt;/p&gt;

&lt;p&gt;http://github.com/luislavena/mysql-gem/tree/master&lt;/p&gt;

&lt;p&gt;Cheers,
Luis Lavena&lt;/p&gt;</content>  </entry>
</feed>

