I am trying to switch from sqllite3 to mysql on Ruby on Rails. Whenever I try to install the mysql gem, i get an error: *** extconf.rb failed *** Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the mkmf.log file for more details. You may need configuration options. I cd''d into my usr/local/bin directory and saw i have several mysql installs, and am thinking i''ve probably removed something along the way, and this it the problem. Please can someone explain how to delete all instances of mysql so I can re-install? Or - does someone know what i need to do to avoid this error? I have installed mysql-5.1.37-osx10.5-x86 as I am running Leopard 10.5.7 ANy ideas to get me running on mysql? Many Thanks
Frederick Cheung
2009-Aug-18 19:50 UTC
Re: ** Removing all instances of mysql on mac osx **
On Aug 18, 7:43 pm, Craig Westmoreland <craigwest...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote:> I am trying to switch from sqllite3 to mysql on Ruby on Rails. > > Whenever I try to install the mysql gem, i get an error:when you ran gem install mysql did you tell it where to find mysql (eg with -- --with-mysql-config=/path/to/mysql_config ) ? Fred> > *** extconf.rb failed *** > Could not create Makefile due to some reason, probably lack of > necessary libraries and/or headers. Check the mkmf.log file for more > details. You may need configuration options. > > I cd''d into my usr/local/bin directory and saw i have several mysql > installs, and am thinking i''ve probably removed something along the > way, and this it the problem. > > Please can someone explain how to delete all instances of mysql so I > can re-install? > > Or - does someone know what i need to do to avoid this error? > > I have installed mysql-5.1.37-osx10.5-x86 as I am running Leopard > 10.5.7 > > ANy ideas to get me running on mysql? > > Many Thanks
Craig Westmoreland
2009-Aug-19 07:54 UTC
Re: ** Removing all instances of mysql on mac osx **
No i didnt do that - the tutorial i followed (hivelogic) never mentioned that. Does anyone know the command(s) i need to completely remove all mysql references on my mac? I think i''ll follow that route then just start again. Cheers On 18 Aug, 20:50, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> On Aug 18, 7:43 pm, Craig Westmoreland <craigwest...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> > wrote: > > > I am trying to switch from sqllite3 to mysql on Ruby on Rails. > > > Whenever I try to install the mysql gem, i get an error: > > when you ran gem install mysql did you tell it where to find mysql (eg > with -- --with-mysql-config=/path/to/mysql_config ) ? > > Fred > > > > > > > *** extconf.rb failed *** > > Could not create Makefile due to some reason, probably lack of > > necessary libraries and/or headers. Check the mkmf.log file for more > > details. You may need configuration options. > > > I cd''d into my usr/local/bin directory and saw i have several mysql > > installs, and am thinking i''ve probably removed something along the > > way, and this it the problem. > > > Please can someone explain how to delete all instances of mysql so I > > can re-install? > > > Or - does someone know what i need to do to avoid this error? > > > I have installed mysql-5.1.37-osx10.5-x86 as I am running Leopard > > 10.5.7 > > > ANy ideas to get me running on mysql? > > > Many Thanks- Hide quoted text - > > - Show quoted text -
Frederick Cheung
2009-Aug-19 08:29 UTC
Re: ** Removing all instances of mysql on mac osx **
On Aug 19, 8:54 am, Craig Westmoreland <craigwest...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote:> No i didnt do that - the tutorial i followed (hivelogic) never > mentioned that. >It does (well it gives one of the many ways of doing something equivalent, telling you to pass --with-mysql-dir instead)> Does anyone know the command(s) i need to completely remove all mysql > references on my mac?I think mysql doesn''t drop files out of /usr/local/mysq-... so just blowing away those folders should be enough. the mysql docs may have specific uninstall instructions. You might want to note that there will always be at least 2 mysql things in /usr/local, /usr/local/mysql is just a symlink to a specific version Fred> > I think i''ll follow that route then just start again. > > Cheers > > On 18 Aug, 20:50, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > > On Aug 18, 7:43 pm, Craig Westmoreland <craigwest...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> > > wrote: > > > > I am trying to switch from sqllite3 to mysql on Ruby on Rails. > > > > Whenever I try to install the mysql gem, i get an error: > > > when you ran gem install mysql did you tell it where to find mysql (eg > > with -- --with-mysql-config=/path/to/mysql_config ) ? > > > Fred > > > > *** extconf.rb failed *** > > > Could not create Makefile due to some reason, probably lack of > > > necessary libraries and/or headers. Check the mkmf.log file for more > > > details. You may need configuration options. > > > > I cd''d into my usr/local/bin directory and saw i have several mysql > > > installs, and am thinking i''ve probably removed something along the > > > way, and this it the problem. > > > > Please can someone explain how to delete all instances of mysql so I > > > can re-install? > > > > Or - does someone know what i need to do to avoid this error? > > > > I have installed mysql-5.1.37-osx10.5-x86 as I am running Leopard > > > 10.5.7 > > > > ANy ideas to get me running on mysql? > > > > Many Thanks- Hide quoted text - > > > - Show quoted text -
On OS-X, you do need to install mysql gem with sudo gem install mysql -- --with-mysql-config = /usr/local/mysql/bin/ mysql_config See if that works before blowing away MySQL. On Aug 19, 12:54 pm, Craig Westmoreland <craigwest...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote:> No i didnt do that - the tutorial i followed (hivelogic) never > mentioned that. > > Does anyone know the command(s) i need to completely remove all mysql > references on my mac? > > I think i''ll follow that route then just start again. > > Cheers > > On 18 Aug, 20:50, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > > On Aug 18, 7:43 pm, Craig Westmoreland <craigwest...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> > > wrote: > > > > I am trying to switch from sqllite3 to mysql on Ruby on Rails. > > > > Whenever I try to install the mysql gem, i get an error: > > > when you ran gem install mysql did you tell it where to find mysql (eg > > with -- --with-mysql-config=/path/to/mysql_config ) ? > > > Fred > > > > *** extconf.rb failed *** > > > Could not create Makefile due to some reason, probably lack of > > > necessary libraries and/or headers. Check the mkmf.log file for more > > > details. You may need configuration options. > > > > I cd''d into my usr/local/bin directory and saw i have several mysql > > > installs, and am thinking i''ve probably removed something along the > > > way, and this it the problem. > > > > Please can someone explain how to delete all instances of mysql so I > > > can re-install? > > > > Or - does someone know what i need to do to avoid this error? > > > > I have installed mysql-5.1.37-osx10.5-x86 as I am running Leopard > > > 10.5.7 > > > > ANy ideas to get me running on mysql? > > > > Many Thanks- Hide quoted text - > > > - Show quoted text -
Craig Westmoreland
2009-Aug-19 12:39 UTC
Re: ** Removing all instances of mysql on mac osx **
cheers all, will try that! On 19 Aug, 12:10, Mukund <marut...-/E1597aS9LQAvxtiuMwx3w@public.gmane.org> wrote:> On OS-X, you do need to install mysql gem with > > sudo gem install mysql -- --with-mysql-config = /usr/local/mysql/bin/ > mysql_config > > See if that works before blowing away MySQL. > > On Aug 19, 12:54 pm, Craig Westmoreland <craigwest...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> > wrote: > > > > > No i didnt do that - the tutorial i followed (hivelogic) never > > mentioned that. > > > Does anyone know the command(s) i need to completely remove all mysql > > references on my mac? > > > I think i''ll follow that route then just start again. > > > Cheers > > > On 18 Aug, 20:50, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > On Aug 18, 7:43 pm, Craig Westmoreland <craigwest...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> > > > wrote: > > > > > I am trying to switch from sqllite3 to mysql on Ruby on Rails. > > > > > Whenever I try to install the mysql gem, i get an error: > > > > when you ran gem install mysql did you tell it where to find mysql (eg > > > with -- --with-mysql-config=/path/to/mysql_config ) ? > > > > Fred > > > > > *** extconf.rb failed *** > > > > Could not create Makefile due to some reason, probably lack of > > > > necessary libraries and/or headers. Check the mkmf.log file for more > > > > details. You may need configuration options. > > > > > I cd''d into my usr/local/bin directory and saw i have several mysql > > > > installs, and am thinking i''ve probably removed something along the > > > > way, and this it the problem. > > > > > Please can someone explain how to delete all instances of mysql so I > > > > can re-install? > > > > > Or - does someone know what i need to do to avoid this error? > > > > > I have installed mysql-5.1.37-osx10.5-x86 as I am running Leopard > > > > 10.5.7 > > > > > ANy ideas to get me running on mysql? > > > > > Many Thanks- Hide quoted text - > > > > - Show quoted text -- Hide quoted text - > > - Show quoted text -
Mukund wrote:> On OS-X, you do need to install mysql gem with > > sudo gem install mysql -- --with-mysql-config = /usr/local/mysql/bin/ > mysql_configFrom the header of database.yml # Install the MySQL driver: # gem install mysql # On Mac OS X: # sudo gem install mysql -- --with-mysql-dir=/usr/local/mysql # On Mac OS X Leopard: # sudo env ARCHFLAGS="-arch i386" gem install mysql -- --with-mysql-config=/usr/local/mysql/bin/mysql_config # This sets the ARCHFLAGS environment variable to your native architecture -- Posted via http://www.ruby-forum.com/.
Aldric Giacomoni
2009-Aug-20 16:52 UTC
Re: ** Removing all instances of mysql on mac osx **
If I may suggest this following post from an ignote (whistles innocently) user.. http://trevoke.net/blog/2009/04/17/installing-the-mysql-gem-on-osx/ Let me know if this works or not :) -- Posted via http://www.ruby-forum.com/.