mysql gem: better native extension error than this?

Discussion in 'Ruby' started by Tony Arcieri, Feb 4, 2010.

  1. Tony Arcieri

    Tony Arcieri Guest

    [Note: parts of this message were removed to make it a legal post.]

    uninitialized constant MysqlCompat::MysqlRes

    ...surely the error can be better than this. The meaning of this error is
    "the native extension failed to load", however the error does not convey
    this whatsoever. Can't this be:

    NativeExtensionError: couldn't load libmysqlclient.so

    Or something slightly more informative?

    --
    Tony Arcieri
    Medioh! A Kudelski Brand
    Tony Arcieri, Feb 4, 2010
    #1
    1. Advertising

  2. Tony Arcieri

    Luis Lavena Guest

    On Feb 4, 1:38 am, Tony Arcieri <> wrote:
    > [Note:  parts of this message were removed to make it a legal post.]
    >
    > uninitialized constant MysqlCompat::MysqlRes
    >
    > ..surely the error can be better than this.  The meaning of this error is
    > "the native extension failed to load", however the error does not convey
    > this whatsoever.  Can't this be:
    >
    > NativeExtensionError: couldn't load libmysqlclient.so
    >
    > Or something slightly more informative?
    >


    When are you getting this?

    A sample script that can reproduce it? Or is a Rails application?

    Definitely things could be better, also world peace can be achieved if
    humans weren't so greedy and help each other instead.

    The repository used to build the gem is here:

    http://github.com/luislavena/mysql-gem

    Feel free to fork it, adjust what is needed and ensure tests works
    prior sending a pull request.

    Regards,
    --
    Luis Lavena
    Luis Lavena, Feb 4, 2010
    #2
    1. Advertising

  3. Tony Arcieri

    Tony Arcieri Guest

    [Note: parts of this message were removed to make it a legal post.]

    On Thu, Feb 4, 2010 at 5:44 AM, Luis Lavena <> wrote:

    > When are you getting this?
    >


    Installing the mysql gem, under Snow Leopard unless ARCHFLAGS=-arch x86_64
    is set.

    The repository used to build the gem is here:
    >
    > http://github.com/luislavena/mysql-gem
    >
    > Feel free to fork it, adjust what is needed and ensure tests works
    > prior sending a pull request.
    >


    Ok

    --
    Tony Arcieri
    Medioh! A Kudelski Brand
    Tony Arcieri, Feb 4, 2010
    #3
  4. Tony Arcieri

    Luis Lavena Guest

    On Feb 4, 6:07 pm, Tony Arcieri <> wrote:
    > [Note:  parts of this message were removed to make it a legal post.]
    >
    > On Thu, Feb 4, 2010 at 5:44 AM, Luis Lavena <> wrote:
    > > When are you getting this?

    >
    > Installing the mysql gem, under Snow Leopard unless ARCHFLAGS=-arch x86_64
    > is set.
    >


    The offending code is here:

    http://github.com/luislavena/mysql-gem/blob/master/ext/mysql_api/extconf.rb#L1-8

    Since I haven't upgraded my Leopard installation to Slow Leopard, I
    cannot test all these details.

    I've that *cough* feature *cough* from DataObjects, which got removed
    after SL release.

    Since I don't have a spare Mac for work, couldn't afford the time will
    take to rebuild my whole environment due the craziness of mixed 64/32
    bits applications and libraries.

    If you take a look to current DataObjects, maybe you can bring these
    changes in:

    http://github.com/datamapper/do/blob/master/do_mysql/ext/do_mysql/extconf.rb

    --
    Luis Lavena
    Luis Lavena, Feb 4, 2010
    #4
    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. Peter Bencsik
    Replies:
    2
    Views:
    814
  2. jyzhang
    Replies:
    0
    Views:
    117
    jyzhang
    Dec 1, 2006
  3. David Southwell
    Replies:
    4
    Views:
    136
    Eric Hodel
    Aug 11, 2008
  4. kungfu-free
    Replies:
    0
    Views:
    440
    kungfu-free
    Feb 9, 2009
  5. Iñaki Baz Castillo
    Replies:
    1
    Views:
    147
    Iñaki Baz Castillo
    Feb 28, 2011
Loading...

Share This Page