[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: SQLIte3 DL driver deprecated, how to use native?

Jeremy Hinegardner

8/29/2007 1:44:00 PM

Hi,

On Wed, Aug 29, 2007 at 07:50:33PM +0900, Eddie Catflap wrote:
> Hi.
>
> I'm writing what's pretty much my first piece of code using Ruby. Very happy
> with it so far and have managed to cobble together a bit of code to archive
> a large amount of text (basically a message board archive) into a sqlite
> database. And it works! One thing is intriguing me though. I'm seeing an
> error generated by the line:
>
> db = SQLite3::Database.new( 'test.db' )
>
> The warning message is:
>
> The DL driver for sqlite3-ruby is deprecated and will be removed
> in a future release. Please update your installation to use the
> Native driver.
>
> I've spent the best part of two days looking for how to get the system to
> use the native driver. I'm running on Solaris 10 (sparc). Sqlite3 resides
> under /usr/local/bin (and it's libraries under /usr/local/lib ). I've
> installed SWIG and reinstalled the sqlite3-ruby gem. Nothing seems to make a
> difference. Am I missing a trick here? It may be that this isn't the right
> place to ask a question like this, although there seemed to be a fair amount
> of SQLite3 related queries in the archive. If this is the wrong place, feel
> free to tell me to sod off, I won't be offended ;-)
>
> Here's how I install the sqlite3-ruby gem, and the output - any clues here?
> It would seem the native driver is being compiled, should I be doing
> something other than using SQLite3::Database.new to choose it?

[...]
> Building native extensions. This could take a while...
> make: *** No rule to make target `ruby.h', needed by `sqlite3_api_wrap.o'.
> Stop.
> make: *** No rule to make target `ruby.h', needed by `sqlite3_api_wrap.o'.

It would appear that rubygems cannot find your ruby.h for your ruby
installation, which it needs to build the native driver. I have not
installed ruby on Solaris myself, but is there a ruby.h in the directory
printed out with this:

ruby -rrbconfig -e 'puts ::Config::CONFIG["includedir"]'

enjoy,

-jeremy

--
========================================================================
Jeremy Hinegardner jeremy@hinegardner.org