MySQL Bindings, Pather Server, existing MySQL - help

Discussion in 'Ruby' started by Brian Ablaza, Feb 26, 2006.

  1. Brian Ablaza

    Brian Ablaza Guest

    I'm trying to install Ruby with the MySQL bindings via Darwinports on a
    Panther Server with an existing MySQL install. I've used Darwinports to
    install Ruby, Gems, and Rails, all went OK.

    Now I'm trying to install the MySQL bindings without success. I've tried
    using Gems and extconf.rb, but both fail:

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

    I think this is because on Panther server, the directories for lib and
    include are in non-standard locations (/usr/include/mysql,
    /usr/lib/mysql instead of /usr/local/mysql and /usr/local/lib). I've
    tried specifying these locations (--with-mysql-include, etc.) but it
    seems that the build script tries to add "include" and "lib" to the end
    of the directory specification, so it fails.

    I also tried to use Darwinports to install the bindings, but it has
    MySQL as a dependency. It doesn't find MySQL (since it's previously
    installed at the standard location and not by Darwinports), so it wants
    to install it. I say no, of course, but then the port won't install.
    There doesn't seem to be a way to specify an alternate location for
    MySQL to get the port to install.

    I've tried everything I can think of. Any ideas?

    --
    Posted via http://www.ruby-forum.com/.
     
    Brian Ablaza, Feb 26, 2006
    #1
    1. Advertising

  2. Brian Ablaza

    zakifataya Guest

    In the interests of helping others (since I couldn't find the answer to
    this myself) here's how I was able to accomplish this.

    Per directions here

    http://www.kitebird.com/articles/ruby-mysql.html

    I was changing to the mysql-2.7 directory and running

    ruby extconf.rb --with-mysql-config=/usr/include/mysql
    --with-mysql-lib=/usr/lib/mysql

    but it was failing (see previous post).

    I know that you often have to run the "make" and "make install" commands
    as root, but what fixed my problem was running extconf.rb as root. Don't
    know if that will be a problem later, or a security risk, but it works
    now.

    Brian Ablaza wrote:
    > I'm trying to install Ruby with the MySQL bindings via Darwinports on a
    > Panther Server with an existing MySQL install. I've used Darwinports to
    > install Ruby, Gems, and Rails, all went OK.
    >
    > Now I'm trying to install the MySQL bindings without success. I've tried
    > using Gems and extconf.rb, but both fail:
    >
    > checking for mysql_ssl_set()... no
    > checking for mysql.h... no
    > checking for mysql/mysql.h... no
    >
    > I think this is because on Panther server, the directories for lib and
    > include are in non-standard locations (/usr/include/mysql,
    > /usr/lib/mysql instead of /usr/local/mysql and /usr/local/lib). I've
    > tried specifying these locations (--with-mysql-include, etc.) but it
    > seems that the build script tries to add "include" and "lib" to the end
    > of the directory specification, so it fails.
    >
    > I also tried to use Darwinports to install the bindings, but it has
    > MySQL as a dependency. It doesn't find MySQL (since it's previously
    > installed at the standard location and not by Darwinports), so it wants
    > to install it. I say no, of course, but then the port won't install.
    > There doesn't seem to be a way to specify an alternate location for
    > MySQL to get the port to install.
    >
    > I've tried everything I can think of. Any ideas?


    --
    Posted via http://www.ruby-forum.com/.
     
    zakifataya, Feb 27, 2006
    #2
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. nrm
    Replies:
    3
    Views:
    534
  2. Carla
    Replies:
    3
    Views:
    625
  3. Shalev NessAiver

    mysql/ruby bindings (GEM Issue)

    Shalev NessAiver, Feb 17, 2005, in forum: Ruby
    Replies:
    2
    Views:
    115
    Chad Fowler
    Feb 18, 2005
  4. Replies:
    0
    Views:
    190
  5. Iain Barnett
    Replies:
    2
    Views:
    131
    Iain Barnett
    Apr 28, 2011
Loading...

Share This Page