mysql-ruby help needed please

L

listaction

Hello,

I'm having difficulties trying to install mysql-ruby-2.5.1 on OS X and am
hoping someone can help me.

The problem occurs when running:
ruby extconf.rb (with seemingly any combination of options)

The details are below, thanks very much for any help!

Bests,
Matt



My setup is:

OS X 10.3.7 (Darwin 7.7.0)
mysql-standard-4.1.9-apple-darwin7.7.0-powerpc (the package installer)
Ruby 1.8.2 stable snapshot dmg

I've tried various combinations of the following extconf.rb arguments (which
match my mysql install layout)

--with-mysql-dir=/usr/local/mysql
--with-mysql-lib=/usr/local/mysql/lib
--with-mysql-include=/usr/local/mysql/include
--with-mysql-config=/usr/local/mysql/bin/mysql_config

I've also tried using the full directory name instead of the 'mysql'
symbolic link.


With the first three options I get the following:

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

But with the --with-mysql-config I get this:

checking for mysql_ssl_set()... no
checking for mysql.h... no
checking for mysql/mysql.h... No

And finally, the content of mkmf.log:

have_func: checking for mysql_ssl_set()... -------------------- no

"gcc -o conftest -I/Users/mattj/Desktop/mysql-ruby-2.5.1
-I/usr/local/lib/ruby/1.8/powerpc-darwin7.5.0
-I/usr/local/mysql-standard-4.1.9-apple-darwin7.7.0-powerpc/include
-fno-omit-frame-pointer -g -O2 -fno-common -pipe -fno-common conftest.c
-L"/usr/local/lib"
-L/usr/local/mysql-standard-4.1.9-apple-darwin7.7.0-powerpc/lib
-lmysqlclient -lm -lz -lruby-static
-L/usr/local/mysql-standard-4.1.9-apple-darwin7.7.0-powerpc/lib
-lmysqlclient -lm -lz -ldl -lobjc "
sh: line 1: gcc: command not found
checked program was:
/* begin */

/*top*/
int main() { return 0; }
int t() { mysql_ssl_set(); return 0; }
/* end */

"gcc -o conftest -I/Users/mattj/Desktop/mysql-ruby-2.5.1
-I/usr/local/lib/ruby/1.8/powerpc-darwin7.5.0
-I/usr/local/mysql-standard-4.1.9-apple-darwin7.7.0-powerpc/include
-fno-omit-frame-pointer -g -O2 -fno-common -pipe -fno-common conftest.c
-L"/usr/local/lib"
-L/usr/local/mysql-standard-4.1.9-apple-darwin7.7.0-powerpc/lib
-lmysqlclient -lm -lz -lruby-static
-L/usr/local/mysql-standard-4.1.9-apple-darwin7.7.0-powerpc/lib
-lmysqlclient -lm -lz -ldl -lobjc "
sh: line 1: gcc: command not found
checked program was:
/* begin */


/*top*/
int main() { return 0; }
int t() { void ((*volatile p)()); p = (void ((*)()))mysql_ssl_set; return 0;
}
/* end */

--------------------

have_header: checking for mysql.h... -------------------- no

"gcc -E -I/Users/mattj/Desktop/mysql-ruby-2.5.1
-I/usr/local/lib/ruby/1.8/powerpc-darwin7.5.0
-I/usr/local/mysql-standard-4.1.9-apple-darwin7.7.0-powerpc/include
-fno-omit-frame-pointer -g -O2 -fno-common -pipe -fno-common conftest.c -o
conftest.i"
checked program was:
/* begin */
#include <mysql.h>
/* end */

--------------------

have_header: checking for mysql/mysql.h... -------------------- no

"gcc -E -I/Users/mattj/Desktop/mysql-ruby-2.5.1
-I/usr/local/lib/ruby/1.8/powerpc-darwin7.5.0
-I/usr/local/mysql-standard-4.1.9-apple-darwin7.7.0-powerpc/include
-fno-omit-frame-pointer -g -O2 -fno-common -pipe -fno-common conftest.c -o
conftest.i"
checked program was:
/* begin */
#include <mysql/mysql.h>
/* end */

--------------------
 
L

Lyle Johnson

I'm having difficulties trying to install mysql-ruby-2.5.1 on OS X and am
hoping someone can help me.

The problem occurs when running:
ruby extconf.rb (with seemingly any combination of options)

The details are below, thanks very much for any help!

OK, Matt, I really, *really* hate asking this question, but: Do you
have the Apple Developer tools installed?

The reason I'm asking is that, buried in the mkmf.log contents that
you posted, I see several occurrences of:

sh: line 1: gcc: command not found

and "gcc" is the GNU C/C++ compiler. That's not part of the standard
Mac OS X install, but it is part of the freely available developer
tools. A CD-ROM with this software may have come with your Mac;
otherwise, you'll need to download it from Apple's "Developer
Connection" site.

Hope this helps,

Lyle
 
L

listaction

OK, Matt, I really, *really* hate asking this question, but: Do you
have the Apple Developer tools installed?

The reason I'm asking is that, buried in the mkmf.log contents that
you posted, I see several occurrences of:

sh: line 1: gcc: command not found

and "gcc" is the GNU C/C++ compiler. That's not part of the standard
Mac OS X install, but it is part of the freely available developer
tools. A CD-ROM with this software may have come with your Mac;
otherwise, you'll need to download it from Apple's "Developer
Connection" site.

Hope this helps,

Lyle

Hi Lyle. Thanks for your reply. No need whatsoever to hate asking that
question, at least in this instance - this is my first Mac and I've been on
it a week so far. That's exactly the sort of thing tripping me up at this
point.
Which means the answer to your question is no, no Developer Tools installed,
so I'll be doing that and having another crack at it first thing after work.

Thanks again for your help,

Matt
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,819
Latest member
masterdaster

Latest Threads

Top