Craig Beck
2005-Sep-22 02:46 UTC
problems installing mysql native extensions in mac os x 10.4 tiger
My hard drive died the other week in my powerbook, and now I''m trying to get everything up and running again... however, after installing gem fixrbconfig, and running it, I was able to install gem sqlite3-ruby, but still cannot install the mysql gem. What''s up? any ideas? Mysql was installed via the mysql.com installer for 10.4 Attempting remote installation of ''mysql'' Updating Gem source index for: http://gems.rubyforge.org 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/lib/ruby/gems/1.8/gems/ mysql-2.6 for inspection. ruby extconf.rb install mysql --remote\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 -- Craig Beck http://www.luckybonza.com AIM: kreiggers
Ryan Raaum
2005-Sep-22 03:41 UTC
Re: problems installing mysql native extensions in mac os x 10.4 tiger
gem install mysql -- --with-mysql-config=/usr/local/mysql/bin/mysql-config (check the path, but that should be pretty close) On 9/21/05, Craig Beck <craigbeck-sUNYKzuJffo33s2pWanAEQ@public.gmane.org> wrote:> My hard drive died the other week in my powerbook, and now I''m trying > to get everything up and running again... > > however, after installing gem fixrbconfig, and running it, I was able > to install gem sqlite3-ruby, but still cannot install the mysql gem. > What''s up? any ideas? > > Mysql was installed via the mysql.com installer for 10.4 > > Attempting remote installation of ''mysql'' > Updating Gem source index for: http://gems.rubyforge.org > 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/lib/ruby/gems/1.8/gems/ > mysql-2.6 for inspection. > ruby extconf.rb install mysql --remote\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 > > -- > Craig Beck > http://www.luckybonza.com > AIM: kreiggers > > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >-- Ryan Raaum http://www.rockefeller.edu -- Bacterial Pathogenesis and Immunology http://www.worldmartial.com -- Black Belt Instructor http://locomotive.sourceforge.net -- Self contained one-click Rails for Mac OS X
Alison Rowland
2005-Sep-22 05:14 UTC
Re: problems installing mysql native extensions in mac os x 10.4 tiger
I was getting the same error in Tiger. Nothing I tried would let the mysql gem install. Then I followed the directions at the link below, and compiled the mysql-ruby extensions myself. That worked like a charm. http://www.juju.org/articles/2005/08/06/ruby-on-rails-mysql-and-osx-tiger-woes> On 9/21/05, Craig Beck <craigbeck-sUNYKzuJffo33s2pWanAEQ@public.gmane.org> wrote: > > My hard drive died the other week in my powerbook, and now I''m trying > > to get everything up and running again... > > > > however, after installing gem fixrbconfig, and running it, I was able > > to install gem sqlite3-ruby, but still cannot install the mysql gem. > > What''s up? any ideas? > > > > Mysql was installed via the mysql.com <http://mysql.com> installer for > 10.4 > > > > Attempting remote installation of ''mysql'' > > Updating Gem source index for: http://gems.rubyforge.org > > 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/lib/ruby/gems/1.8/gems/ > > mysql-2.6 for inspection. > > ruby extconf.rb install mysql --remote\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 > > > > -- > > Craig Beck > > http://www.luckybonza.com > > AIM: kreiggers > > > > > > _______________________________________________ > > Rails mailing list > > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > > http://lists.rubyonrails.org/mailman/listinfo/rails > > > > > -- > Ryan Raaum > http://www.rockefeller.edu -- Bacterial Pathogenesis and Immunology > http://www.worldmartial.com -- Black Belt Instructor > http://locomotive.sourceforge.net -- Self contained one-click Rails for > Mac OS X > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >_______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails
Craig Beck
2005-Sep-23 02:42 UTC
Re: problems installing mysql native extensions in mac os x 10.4 tiger
no dice. Still didn''t work. I got the result below... $ sudo gem install mysql --with-mysql-config=/usr/local/mysql/bin/ mysql-config ERROR: While executing gem ... (OptionParser::InvalidOption) invalid option: --with-mysql-config=/usr/local/mysql/bin/mysql- config On Sep 21, 2005, at 8:41 PM, Ryan Raaum wrote:> gem install mysql -- --with-mysql-config=/usr/local/mysql/bin/mysql- > config > > (check the path, but that should be pretty close) > > > -- > Ryan Raaum > http://www.rockefeller.edu -- Bacterial Pathogenesis and Immunology > http://www.worldmartial.com -- Black Belt Instructor > http://locomotive.sourceforge.net -- Self contained one-click Rails > for Mac OS X-- Craig Beck http://www.luckybonza.com AIM: kreiggers
Matthew Newhook
2005-Sep-23 03:00 UTC
Re: problems installing mysql native extensions in mac os x 10.4 tiger
I went through this yesterday. Basically what I did was to do: sudo gem install -r mysql -- --with-mysql-dir=/usr/local/mysql this would fail to install, the primary reason being that I had installed fixrbconfig, but had forgot to run it (doh!). After I had done this it would build with gcc 3.3, however, the extension would not work (some error to do with _sprintf not being found). After that I did a "sudo gcc-select 4.0". In order to get the source to compile I had to move a couple of function definitions around in the file. Once I had done that everything worked nicely. Regards, Matthew On 23-Sep-05, at 10:42 AM, Craig Beck wrote:> no dice. Still didn''t work. I got the result below... > > > $ sudo gem install mysql --with-mysql-config=/usr/local/mysql/bin/ > mysql-config > ERROR: While executing gem ... (OptionParser::InvalidOption) > invalid option: --with-mysql-config=/usr/local/mysql/bin/mysql- > config > > > > > On Sep 21, 2005, at 8:41 PM, Ryan Raaum wrote: > > >> gem install mysql -- --with-mysql-config=/usr/local/mysql/bin/ >> mysql-config >> >> (check the path, but that should be pretty close) >> >> >> -- >> Ryan Raaum >> http://www.rockefeller.edu -- Bacterial Pathogenesis and Immunology >> http://www.worldmartial.com -- Black Belt Instructor >> http://locomotive.sourceforge.net -- Self contained one-click >> Rails for Mac OS X >> > > -- > Craig Beck > > http://www.luckybonza.com > AIM: kreiggers > > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
Ezra Zygmuntowicz
2005-Sep-23 05:01 UTC
Re: problems installing mysql native extensions in mac os x 10.4 tiger
You need to do it like this:> $ sudo gem install mysql -- --with-mysql-config=/usr/local/mysql/ > bin/mysql-config^^^^^ note the extra -- between the flags and the command. You need this in order for gems to pass the with-mysql-config part to the gcc configure But I have had much better luck installing mysql-ruby from source on Tiger. This one works every time: curl -O http://www.tmtm.org/en/mysql/ruby/mysql-ruby-2.7.tar.gz tar zxvf mysql-ruby-* cd mysql-ruby-* ruby extconf.rb --with-mysql-config make sudo make install HTH -Ezra On Sep 22, 2005, at 7:42 PM, Craig Beck wrote:> no dice. Still didn''t work. I got the result below... > > > $ sudo gem install mysql --with-mysql-config=/usr/local/mysql/bin/ > mysql-config > ERROR: While executing gem ... (OptionParser::InvalidOption) > invalid option: --with-mysql-config=/usr/local/mysql/bin/mysql- > config > > > > > On Sep 21, 2005, at 8:41 PM, Ryan Raaum wrote: > > >> gem install mysql -- --with-mysql-config=/usr/local/mysql/bin/ >> mysql-config >> >> (check the path, but that should be pretty close) >> >> >> -- >> Ryan Raaum >> http://www.rockefeller.edu -- Bacterial Pathogenesis and Immunology >> http://www.worldmartial.com -- Black Belt Instructor >> http://locomotive.sourceforge.net -- Self contained one-click >> Rails for Mac OS X >> > > -- > Craig Beck > > http://www.luckybonza.com > AIM: kreiggers > > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >-Ezra Zygmuntowicz WebMaster Yakima Herald-Republic Newspaper ezra-gdxLOakOTQ9oetBuM9ipNAC/G2K4zDHf@public.gmane.org 509-577-7732
Craig Beck
2005-Sep-23 06:07 UTC
Re: problems installing mysql native extensions in mac os x 10.4 tiger
I just did the install from source and it worked like a charm! Thanks, -- craig On Sep 22, 2005, at 10:01 PM, Ezra Zygmuntowicz wrote:> You need to do it like this: > >> $ sudo gem install mysql -- --with-mysql-config=/usr/local/mysql/ >> bin/mysql-config >> > ^^^^^ note the extra -- > between the flags and the command. You need this in order for gems > to pass the with-mysql-config part to the gcc configure > > But I have had much better luck installing mysql-ruby from source > on Tiger. This one works every time: > > curl -O http://www.tmtm.org/en/mysql/ruby/mysql-ruby-2.7.tar.gz > tar zxvf mysql-ruby-* > cd mysql-ruby-* > ruby extconf.rb --with-mysql-config > make > sudo make install > > HTH > -Ezra > On Sep 22, 2005, at 7:42 PM, Craig Beck wrote: > > >> no dice. Still didn''t work. I got the result below... >> >> >> $ sudo gem install mysql --with-mysql-config=/usr/local/mysql/bin/ >> mysql-config >> ERROR: While executing gem ... (OptionParser::InvalidOption) >> invalid option: --with-mysql-config=/usr/local/mysql/bin/mysql- >> config >> >> >> >> >> On Sep 21, 2005, at 8:41 PM, Ryan Raaum wrote: >> >> >> >>> gem install mysql -- --with-mysql-config=/usr/local/mysql/bin/ >>> mysql-config >>> >>> (check the path, but that should be pretty close) >>> >>> >>> -- >>> Ryan Raaum >>> http://www.rockefeller.edu -- Bacterial Pathogenesis and Immunology >>> http://www.worldmartial.com -- Black Belt Instructor >>> http://locomotive.sourceforge.net -- Self contained one-click >>> Rails for Mac OS X >>> >>> >> >> -- >> Craig Beck >> >> http://www.luckybonza.com >> AIM: kreiggers >> >> >> _______________________________________________ >> Rails mailing list >> Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org >> http://lists.rubyonrails.org/mailman/listinfo/rails >> >> > > -Ezra Zygmuntowicz > WebMaster > Yakima Herald-Republic Newspaper > ezra-gdxLOakOTQ9oetBuM9ipNAC/G2K4zDHf@public.gmane.org > 509-577-7732 > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >-- Craig Beck http://www.luckybonza.com AIM: kreiggers