From: Joe Block Date: 2005-05-26T12:15:18+09:00 Subject: Re: Compiling MySQL-Ruby on Tiger In article <1116657333.349832.310430@g49g2000cwa.googlegroups.com>, "rom" wrote: > I might be forking this thread, but I'm having the same problem. I'm > using mySQL 4.1.10 compiled from source via Fink. Don't get me wrong, > if there isn't a fix for this I will definately try the install that > was illustrated earlier using the ServerLogistics install. > > I've been hacking at this for about 2 hours, and it just seems too > close to abandon completely. I found the following in the > documentation for mysql-ruby: > " If you get error like 'libmysqlclient not found' when testing, you > need to specify the directory in which the library is located so that > make can find it. > '% env LD_RUN_PATH=libmysqlclient.so directory make'" > > I used 'mdfind' to find the libmysqlclient at: > '/sw/lib/mysql/libmysqlclient.14.0.0.dylib' > > However, I don't know how to get extconf.rb find it. I'd appreciate > any help with this. I've been working on this so long, I can't see the > forest for the trees, right now. I may not even be grokking the 'env' > command right now... > > Thanks! > > > Pat Allan wrote: > > > I've been trying to compile mysql-ruby on MacOS X 10.4 Tiger, but > having no luck. > > When I run ruby extconf.rb --with-mysql-dir=/usr/local/mysql: > # ruby extconf.rb --with-mysql-dir=/usr/local/mysql > checking for mysql_query() in -lmysqlclient... no > checking for main() in -lm... no > checking for mysql_query() in -lmysqlclient... no > checking for main() in -lz... no > 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 > > Install gem, then: sudo gem install mysql -- --with-mysql-lib=/sw/lib/mysql --with-mysql-include=/sw/include But if you're running 10.4, there are issues with Apple's shipped version of ruby that prevent it from making external libraries properly. A kind soul posted a script that fixes them, though, at: http://tech.rufy.com/entry/46 jpb