Weird error on installing mysql DataObjects - any ideas?

0 views
Skip to first unread message

Zack Chandler

unread,
Jan 9, 2008, 2:10:57 AM1/9/08
to DataMapper
$ sudo gem install datamapper
Successfully installed datamapper-0.2.5
1 gem installed
Installing ri documentation for datamapper-0.2.5...
Installing RDoc documentation for datamapper-0.2.5...
$ sudo gem install do_mysql
Building native extensions. This could take a while...
ERROR: Error installing do_mysql:
ERROR: Failed to build gem native extension.

/usr/local/bin/ruby extconf.rb install do_mysql
checking for mysql_query() in -lmysqlclient... yes
creating Makefile

make
gcc -I. -I. -I/usr/local/lib/ruby/1.8/i686-darwin8.10.1 -I. -I/usr/
local/mysql/include -fno-common -g -O2 -fno-common -pipe -fno-common
-Wall -c mysql_c.c
mysql_c.c: In function '_wrap_mysql_get_ssl_cipher':
mysql_c.c:8963: warning: implicit declaration of function
'mysql_get_ssl_cipher'
mysql_c.c: In function '_wrap_MYSQL_METHODS_advanced_command_set':
mysql_c.c:13715: warning: assignment from incompatible pointer type
mysql_c.c: In function 'Init_mysql_c':
mysql_c.c:16079: error: 'MYSQL_OPT_SSL_VERIFY_SERVER_CERT' undeclared
(first use in this function)
mysql_c.c:16079: error: (Each undeclared identifier is reported only
once
mysql_c.c:16079: error: for each function it appears in.)
make: *** [mysql_c.o] Error 1


Gem files will remain installed in /usr/local/lib/ruby/gems/1.8/gems/
do_mysql-0.2.3 for inspection.
Results logged to /usr/local/lib/ruby/gems/1.8/gems/do_mysql-0.2.3/ext/
gem_make.out

Kevin Bullock

unread,
Jan 9, 2008, 10:36:46 AM1/9/08
to datam...@googlegroups.com
Are you on OS X using fink or on Debian or Ubuntu? If so, you probably
need to install the mysql-dev package (might be named mysql-5.1-dev or
something similar for whichever version you're using).

Zack Chandler

unread,
Jan 9, 2008, 11:34:39 AM1/9/08
to datam...@googlegroups.com

Kevin,

Yeah I guess my post should have included my arch and mysql version :)

$ mysql --version
mysql Ver 14.12 Distrib 5.0.21, for apple-darwin8.5.1 (i686) using readline 5.0

I installed mysql through the standard dmg. I suppose then I'll
reinstall using fink with the mysql-dev package unless there is an
easier way.

Zack

Kevin Bullock

unread,
Jan 9, 2008, 12:07:39 PM1/9/08
to datam...@googlegroups.com
Zack Chandler wrote:
> I installed mysql through the standard dmg. I suppose then I'll
> reinstall using fink with the mysql-dev package unless there is an
> easier way.
>

Oh, I've never used the dmg they provide. I would think it would come
with the dev headers, but maybe not. I've always used fink to install
it, with good results.

--
pacem in terris / mir / shanti / salaam / heiwa
Kevin R. Bullock

Nicolás Sanguinetti

unread,
Jan 9, 2008, 12:14:32 PM1/9/08
to datam...@googlegroups.com
You don't need to do that. If mysql is installed into /usr/local (I
don't remember what does the DMG do, I installed it thru ports), then
you can do

$ PATH=/usr/local/mysql/bin:$PATH sudo gem install do_mysql

(If there's nothing at /usr/local/mysql then use `locate mysql_config`
to find the directory)
This works for me ok on Leopard and mysql "Ver 14.12 Distrib 5.0.45,


for apple-darwin8.5.1 (i686) using readline 5.0"

Best,
-Nicolas

Zack Chandler

unread,
Jan 10, 2008, 11:13:51 AM1/10/08
to datam...@googlegroups.com
On Jan 9, 2008 9:07 AM, Kevin Bullock <kbull...@ringworld.org> wrote:
>
> Zack Chandler wrote:
> > I installed mysql through the standard dmg. I suppose then I'll
> > reinstall using fink with the mysql-dev package unless there is an
> > easier way.
> >
>
> Oh, I've never used the dmg they provide. I would think it would come
> with the dev headers, but maybe not. I've always used fink to install
> it, with good results.

Thanks for all the help. In case anyone else runs into the same
thing... I just installed from source via the excellent
http://hivelogic.com/articles/installing-mysql-on-mac-os-x and that fixed it.

Best,

Zack

Reply all
Reply to author
Forward
0 new messages