Re: Complete Newbie needs help!

Brad
Fri, 11 Sep 2009 12:42:30 -0000

I cant seem to figure this out at the moment, but thank you very much
for your help.

Brad

On Sep 11, 1:32 pm, Abhinav Saxena
<abhinav...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:
> Okay, I suspected that this will be your next question :-) Do you have
mysql
> (as in database) installed? Also, I believe you need to install devel
> packages for mysql. I don''t know how to install packages on a Mac,
so please
> use Internet search.
>
> Thanks,
> Abhinav
> --
> अभिनवhttp://twitter.com/abhinav
>
> On Fri, Sep 11, 2009 at 5:53 PM, Brad
<b...-YQrk2ocFi+e2//VQYe0aCQ@public.gmane.org> wrote:
>
> > I tried your suggestion and got this:
>
> > Building native extensions.  This could take a while...
> > ERROR:  Error installing mysql:
> >        ERROR: Failed to build gem native extension.
>
> > /usr/local/bin/ruby extconf.rb
> > checking 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
> > checking for main() in -lmygcc... no
> > checking for mysql_query() in -lmysqlclient... no
> > *** 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.
>
> > Provided configuration options:
> >        --with-opt-dir
> >        --without-opt-dir
> >        --with-opt-include
> >        --without-opt-include=${opt-dir}/include
> >        --with-opt-lib
> >        --without-opt-lib=${opt-dir}/lib
> >        --with-make-prog
> >        --without-make-prog
> >        --srcdir=.
> >        --curdir
> >        --ruby=/usr/local/bin/ruby
> >        --with-mysql-config
> >        --without-mysql-config
> >        --with-mysql-dir
> >        --without-mysql-dir
> >        --with-mysql-include
> >        --without-mysql-include=${mysql-dir}/include
> >        --with-mysql-lib
> >        --without-mysql-lib=${mysql-dir}/lib
> >        --with-mysqlclientlib
> >        --without-mysqlclientlib
> >        --with-mlib
> >        --without-mlib
> >        --with-mysqlclientlib
> >        --without-mysqlclientlib
> >        --with-zlib
> >        --without-zlib
> >        --with-mysqlclientlib
> >        --without-mysqlclientlib
> >        --with-socketlib
> >        --without-socketlib
> >        --with-mysqlclientlib
> >        --without-mysqlclientlib
> >        --with-nsllib
> >        --without-nsllib
> >        --with-mysqlclientlib
> >        --without-mysqlclientlib
> >        --with-mygcclib
> >        --without-mygcclib
> >        --with-mysqlclientlib
> >        --without-mysqlclientlib
>
> > Gem files will remain installed in /usr/local/lib/ruby/gems/1.8/gems/
> > mysql-2.8.1 for inspection.
> > Results logged to /usr/local/lib/ruby/gems/1.8/gems/mysql-2.8.1/ext/
> > mysql_api/gem_make.out
>
> > is there a specific directory or folder i should be in to do this?
>
> > Sorry, i am very new to this.
>
> > Brad
>
> > On Sep 11, 1:21 pm, Abhinav Saxena
<abhinav...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
> > > Instead of using rake to install mysql gem, use "sudo gem
install mysql".
> > I
> > > think this should work fine.
>
> > > --
> > > Thanks,
> > > Abhinav
>
> > > --
> > > अभिनवhttp://twitter.com/abhinav
>
> > > On Fri, Sep 11, 2009 at 5:40 PM, Brad
<b...-YQrk2ocFi+e2//VQYe0aCQ@public.gmane.org> wrote:
>
> > > > Yeah, i have tried installing the gem but it wont work. it
keeps
> > > > giving me the last error that i posted above.
>
> > > > brad
>
> > > > On Sep 11, 12:59 pm, Abhinav Saxena
<abhinav...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
> > > > > Please do what it says, install mysql gem. Also using
Internet search
> > for
> > > > > such simple problems does help.
>
> > > > > Thanks,
> > > > > Abhinav
> > > > > --
> > > > > अभिनवhttp://twitter.com/abhinav
>
> > > > > On Fri, Sep 11, 2009 at 5:17 PM, Brad
<b...-YQrk2ocFi+e2//VQYe0aCQ@public.gmane.org> wrote:
>
> > > > > > ok, so i entered this sudo gem install -v=2.3.2
rails
>
> > > > > > it gave me this:
>
> > > > > > Successfully installed actionmailer-2.3.2
> > > > > > Successfully installed activeresource-2.3.2
> > > > > > Successfully installed rails-2.3.2
> > > > > > 3 gems installed
> > > > > > Installing ri documentation for
actionmailer-2.3.2...
> > > > > > Installing ri documentation for
activeresource-2.3.2...
> > > > > > Installing ri documentation for rails-2.3.2...
> > > > > > Installing RDoc documentation for
actionmailer-2.3.2...
> > > > > > Installing RDoc documentation for
activeresource-2.3.2...
> > > > > > Installing RDoc documentation for rails-2.3.2...
>
> > > > > > so i then tried this again: rake db:create
>
> > > > > > and it gave me this:
>
> > > > > > (in
/Applications/rubystack-1.6-0/projects/rubystack)
> > > > > > !!! The bundled mysql.rb driver has been removed
from Rails 2.2.
> > > > > > Please install the mysql gem and try again: gem
install mysql.
> > > > > > rake aborted!
> > > > > > no such file to load -- mysql
>
> > > > > > (See full trace by running task with --trace)
>
> > > > > > Brad
>
> > > > > > On Sep 11, 12:23 pm, Abhinav Saxena
<abhinav...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
> > > > > > > You should install any gem with sudo
> > > > > > >   example: sudo gem install rails
>
> > > > > > > Anyway, I guess, you generated the
application you are working
> > one
> > > > with a
> > > > > > > different rails version than it is currently
installed. So I
> > think,
> > > > > > updating
> > > > > > > RAILS_GEM_VERSION with the correct version
will be much simpler.
> > Try
> > > > > > that.
> > > > > > > Or if it is just a sample app, discard it,
and generate a new
> > one.
>
> > > > > > > Thanks,
> > > > > > > Abhinav
> > > > > > > --
> > > > > > > अभिनवhttp://twitter.com/abhinav
>
> > > > > > > On Fri, Sep 11, 2009 at 4:36 PM, Brad
<b...-YQrk2ocFi+e2//VQYe0aCQ@public.gmane.org>
> > wrote:
>
> > > > > > > > Thanks for your reply. I had a look at
my database.yml file and
> > the
> > > > > > > > socket path is correctly referenced.
>
> > > > > > > > i did rake db:create and got this:
>
> > > > > > > > (in
/Applications/rubystack-1.6-0/projects/rubystack)
> > > > > > > > Missing the Rails 2.3.2 gem. Please `gem
install -v=2.3.2
> > rails`,
> > > > > > > > update your RAILS_GEM_VERSION setting in
config/environment.rb
> > for
> > > > the
> > > > > > > > Rails version you do have installed, or
comment out
> > > > RAILS_GEM_VERSION
> > > > > > > > to use the latest version installed.
>
> > > > > > > > so i did what it told me and entered
this: gem install -v=2.3.2
> > > > rails
>
> > > > > > > > and i got this back: WARNING:
 Installing to ~/.gem since
> > > > /usr/local/
> > > > > > > > lib/ruby/gems/1.8 and
> > > > > > > >          /usr/local/bin aren''t
both writable.
> > > > > > > > WARNING:  You don''t have
/Users/bradbucceri/.gem/ruby/1.8/bin
> > in
> > > > your
> > > > > > > > PATH,
> > > > > > > >          gem executables will not run.
>
> > > > > > > > Brad
>
> > > > > > > > On Sep 11, 11:54 am, Abhinav Saxena
<abhinav...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
> > wrote:
>
> > >
>http://rubyresponse.wordpress.com/2006/07/22/cant-find-mysqldsock/
>
> > > > > > > > > Thanks,
> > > > > > > > > Abhinav
> > > > > > > > > --
> > > > > > > > > अभिनवhttp://twitter.com/abhinav
>
> > > > > > > > > On Fri, Sep 11, 2009 at 3:58 PM,
Brad <b...-YQrk2ocFi+fk8qKhOkO7JA@public.gmane.orgm>
> > > > wrote:
>
> > > > > > > > > > Wahey! ok, my server is
running.
>
> > > > > > > > > > I started this tutorial:
>
> >http://guides.rubyonrails.org/getting_started.html#creating-a-new-rai.
> > > > > > > > ..
>
> > > > > > > > > > when i get to rake db:create
 it tells me that the
> > mysql.sock
> > > > (i
> > > > > > think
> > > > > > > > > > thats it) is missing or not
there and to install it.
>
> > > > > > > > > > In my
/Applications/rubystack-1.6-0/mysql/tmp/mysql.sock
> > > > folder,
> > > > > > it''s
> > > > > > > > > > definiteley there.
>
> > > > > > > > > > im still confused but getting
there!
>
> > > > > > > > > > Brad
>
> > > > > > > > > > On Sep 11, 10:06 am, Abhinav
Saxena <abhinav...@gmail.com>
> > > > wrote:
> > > > > > > > > > > RubyGems might be there,
but not the appropriate version
> > > > > > necessarily.
>
> > > > > > > > > > > On command prompt do
this> gem -v
>
> > > > > > > > > > > If its < 1.3.1 then,
install >= 1.3.1 as suggested by the
> > > > error
> > > > > > > > message.
>
> > > > > > > > > > > Thanks,
> > > > > > > > > > > Abhinav
> > > > > > > > > > > --
> > > > > > > > > > >
अभिनवhttp://twitter.com/abhinav
>
> > > > > > > > > > > On Fri, Sep 11, 2009 at
2:15 PM, Brad <
> > b...-YQrk2ocFi+e2//VQYe0aCQ@public.gmane.org>
> > > > > > wrote:
>
> > > > > > > > > > > > Hey,
>
> > > > > > > > > > > > Thanks for your
reply. i just changed it to
> > script/server
> > > > and
> > > > > > got
> > > > > > > > > > > > this: Rails requires
RubyGems >= 1.3.1. Please install
> > > > RubyGems
> > > > > > and
> > > > > > > > > > > > try
again:http://rubygems.rubyforge.org
>
> > > > > > > > > > > > I am pretty sure the
gems were there yesterday and i
> > dont
> > > > think
> > > > > > i
> > > > > > > > did
> > > > > > > > > > > > anything that would
have got rid of them.
>
> > > > > > > > > > > > Brad
>
> > > > > > > > > > > > On Sep 11, 9:36 am,
Abhinav Saxena <
> > abhinav...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
> > > > > > wrote:
> > > > > > > > > > > > > Hi Brad,
>
> > > > > > > > > > > > > I have never
used Mac, so essentially can''t you much.
> > But
> > > > you
> > > > > > > > seem to
> > > > > > > > > > > > > mistyping
"script/server" as "scripts/server", ie,
> > you
> > > > should
> > > > > > use
> > > > > > > > > > script
> > > > > > > > > > > > > (singular)
>
> > > > > > > > > > > > > Thanks,
> > > > > > > > > > > > > Abhinav
> > > > > > > > > > > > > --
> > > > > > > > > > > > >
अभिनवhttp://twitter.com/abhinav
>
> > > > > > > > > > > > > On Fri, Sep 11,
2009 at 1:14 PM, Brad <
> > > > b...-YQrk2ocFi+e2//VQYe0aCQ@public.gmane.org>
> > > > > > > > wrote:
>
> > > > > > > > > > > > > > Hey,
>
> > > > > > > > > > > > > > I am so
stoked to learn rails. i am on an iMac so i
> > > > know
> > > > > > it''s
>
> ...
>
>