I borrow this thread because I have the same problem but with sqlite3.
... checking for sqlite3.h... no *** extconf.rb failed *** Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. ...
I tried to fix it by downloading the source code for sqlite from http://www.sqlite.org/ and installing it. Now i have the sqlite3.h header file and tried again with
gem install sqlite3-ruby -- --with-sqlite3-dir=/my/sqlite/path/sqlite-3.6.17
The sqlite3.h file is in that directory but I get the same errors again..