[Rails] Image upload problems
Jason Hoffman
jason at one.textdrive.com
Wed Jan 5 09:51:09 GMT 2005
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Jan 5, 2005, at 1:19 AM, Jarkko Laine wrote:
> On 5.1.2005, at 03:53, Tobias Luetke wrote:
>
>> Its the mysql ruby driver and its fixed in the 0.9.3
>> you should do gem update to get the latest rails and then gem install
>> mysql to get the native c based mysql extensions which are faster.
>
> I get this when trying to install the mysql driver:
>
> Jarkko-Laines-Computer:~/ jarkko$ sudo gem install mysql
> Attempting local installation of 'mysql'
> Local gem file not found: mysql*.gem
> Attempting remote installation of 'mysql'
> Building native extensions. This could take a while...
> ERROR: While executing gem ... (RuntimeError)
> ERROR: Failed to build gem native extension.
> Gem files will remain installed in
> /usr/local/lib/ruby/gems/1.8/gems/mysql-2.5.1 for inspection.
> ruby extconf.rb install mysql\nchecking for mysql_query() in
> -lmysqlclient... no
> checking for main() in -lm... yes
> checking for mysql_query() in -lmysqlclient... no
> checking for main() in -lz... yes
> checking for mysql_query() in -lmysqlclient... no
> checking for main() in -lsocket... no
> checking for mysql_query() in -lmysqlclient... no
> checking for main() in -lnsl... no
> checking for mysql_query() in -lmysqlclient... no
It looks like it's not finding where you have mysql libs and h.
Maybe try?
gem install mysql -- --with-mysql-lib=/path/to/lib
- --with-mysql-include=/path/to/include
I used to get a similar error with sqlite and it just took passing the
paths to it,
gem install sqlite -- --with-sqlite-lib=/usr/local/lib
- --with-sqlite-include=/usr/local/include
I've never installed the mysql extensions from gems but with the old
fashion way, it only takes when passing lib and include paths to it:
ruby extconf.rb --with-mysql-include=/usr/local/include/mysql
- --with-mysql-lib=/usr/local/lib/mysql
Same with the fcgi extension:
ruby install.rb config -- --with-fcgi-include=/usr/local/include
- --with-fcgi-lib=/usr/local/lib
- - Jason
-----BEGIN PGP SIGNATURE-----
Version: PGP 8.1
iQA/AwUBQdu4jVUyB+ajXkCLEQKOaACfRYY9MAodQxk49Eua4oYt8dGMcWwAn1S7
nGNPsmFaiF/lHECywQHFVjxA
=0lOf
-----END PGP SIGNATURE-----
More information about the Rails
mailing list