Trouble installing eRuby on MacOS X 10.3

Discussion in 'Ruby' started by Gavin Kistner, Jan 22, 2004.

  1. All day I have been trying to get mod_ruby and eRuby installed on MacOS
    X 10.3 (Panther) with Apache 1.3.
    I'm close, but not yet there.

    (When finished I will post the full details of what I needed to do.)

    mod_ruby and eRuby both claim to have succeeded in the whole
    configure/make/make install steps.

    However, when I uncomment the following line in httpd.conf...
    #RubyRequire apache/eruby-run
    ....Apache fails to start up. (The directive "RubyRequire
    apache/ruby-run" works just fine.)

    I'm assuming that perhaps the problem is that the eRuby installer put
    the library in the wrong location. When I perform "make install" I see:
    liberuby.a -> /usr/local/lib/liberuby.a
    chmod 0644 /usr/local/lib/liberuby.a

    Is this the correct location for it to go? If not, where should it go?
    Apache is a new working install in the standard location of:
    /usr/local/apache/
    And the mod_ruby.so file was correctly installed into:
    /usr/local/apache/libexec/mod_ruby.so


    As more information, following is the output of the configure and 'make
    install' commands for eRuby and mod_ruby, and then the output of the
    error log upon trying to start it with the line uncommented.

    Any pointers on getting this working would be really appreciated.


    [/tmp/ruby/eruby-1.0.5] root# ./configure.rb
    checking whether we are using gcc... yes
    checking Ruby version... 1.8.1
    checking for default charset... iso-8859-1
    checking whether enable shared... no
    creating config.h
    creating Makefile

    ....

    [/tmp/ruby/eruby-1.0.5] root# make install
    liberuby.a -> /usr/local/lib/liberuby.a
    chmod 0644 /usr/local/lib/liberuby.a

    ....

    [/tmp/ruby/mod_ruby-1.0.7] root# ./configure.rb
    --with-apxs=/usr/local/apache/bin/apxs --enable-eruby
    checking for a BSD compatible install... /usr/bin/install -c
    checking whether we are using gcc... yes
    checking Ruby version... 1.8.1
    checking for static Apache module support... no
    checking for dynamic Apache module support... yes
    checking for eruby... yes
    creating Makefile
    creating libruby.module
    creating doc/Makefile

    ....

    [/tmp/ruby/mod_ruby-1.0.7] root# make install
    /usr/bin/install -c -d /usr/local/apache/libexec
    /usr/bin/install -c -m 555 mod_ruby.so /usr/local/apache/libexec
    /usr/bin/install -c -d /usr/local/lib/ruby/1.8/apache
    for file in apache/ruby-run.rb apache/eruby-run.rb apache/erb-run.rb
    apache/rd2html.rb apache/ruby-debug.rb apache/eruby-debug.rb
    auto-reload.rb; do \
    /usr/bin/install -c -m 644
    /private/tmp/ruby/mod_ruby-1.0.7/lib/$file /usr/local/lib/ruby/1.8/$file; \
    done

    ....

    [local/apache/logs] root# cat error_log
    dyld: /usr/local/apache/bin/httpd Undefined symbols:
    _rb_cObject
    _rb_check_type
    _rb_data_object_alloc
    _rb_define_class_under
    _rb_define_method
    _rb_define_module
    _rb_define_singleton_method
    _rb_define_virtual_variable
    _rb_eStandardError
    _rb_eval_string_wrap
    _rb_file_open
    _rb_funcall
    _rb_gc_mark
    _rb_global_variable
    _rb_intern
    _rb_io_close
    _rb_io_gets
    _rb_protect
    _rb_provide
    _rb_raise
    _rb_set_kcode
    _rb_stdin
    _rb_str2cstr
    _rb_str_cat
    _rb_str_freeze
    _rb_str_new
    _rb_str_new2
    _re_mbctab
    _ruby_debug
    _ruby_show_version
    _ruby_top_self
    _ruby_verbose
    _ruby_xmalloc



    --
    (-, /\ \/ / /\/
    Gavin Kistner, Jan 22, 2004
    #1
    1. Advertising

  2. Gavin Kistner

    Gennady Guest

    1. Run configure with option "--enable-shared" where appropriate.
    2. Get mod_ruby version 1.1.1 (development), 1.0.7 is known to have
    problems on Mac OS X.

    Gennady.

    Gavin Kistner wrote:
    > All day I have been trying to get mod_ruby and eRuby installed on MacOS
    > X 10.3 (Panther) with Apache 1.3.
    > I'm close, but not yet there.
    >
    > (When finished I will post the full details of what I needed to do.)
    >
    > mod_ruby and eRuby both claim to have succeeded in the whole
    > configure/make/make install steps.
    >
    > However, when I uncomment the following line in httpd.conf...
    > #RubyRequire apache/eruby-run
    > ....Apache fails to start up. (The directive "RubyRequire
    > apache/ruby-run" works just fine.)
    >
    > I'm assuming that perhaps the problem is that the eRuby installer put
    > the library in the wrong location. When I perform "make install" I see:
    > liberuby.a -> /usr/local/lib/liberuby.a
    > chmod 0644 /usr/local/lib/liberuby.a
    >
    > Is this the correct location for it to go? If not, where should it go?
    > Apache is a new working install in the standard location of:
    > /usr/local/apache/
    > And the mod_ruby.so file was correctly installed into:
    > /usr/local/apache/libexec/mod_ruby.so
    >
    >
    > As more information, following is the output of the configure and 'make
    > install' commands for eRuby and mod_ruby, and then the output of the
    > error log upon trying to start it with the line uncommented.
    >
    > Any pointers on getting this working would be really appreciated.
    >
    >
    > [/tmp/ruby/eruby-1.0.5] root# ./configure.rb
    > checking whether we are using gcc... yes
    > checking Ruby version... 1.8.1
    > checking for default charset... iso-8859-1
    > checking whether enable shared... no
    > creating config.h
    > creating Makefile
    >
    > ....
    >
    > [/tmp/ruby/eruby-1.0.5] root# make install
    > liberuby.a -> /usr/local/lib/liberuby.a
    > chmod 0644 /usr/local/lib/liberuby.a
    >
    > ....
    >
    > [/tmp/ruby/mod_ruby-1.0.7] root# ./configure.rb
    > --with-apxs=/usr/local/apache/bin/apxs --enable-eruby
    > checking for a BSD compatible install... /usr/bin/install -c
    > checking whether we are using gcc... yes
    > checking Ruby version... 1.8.1
    > checking for static Apache module support... no
    > checking for dynamic Apache module support... yes
    > checking for eruby... yes
    > creating Makefile
    > creating libruby.module
    > creating doc/Makefile
    >
    > ....
    >
    > [/tmp/ruby/mod_ruby-1.0.7] root# make install
    > /usr/bin/install -c -d /usr/local/apache/libexec
    > /usr/bin/install -c -m 555 mod_ruby.so /usr/local/apache/libexec
    > /usr/bin/install -c -d /usr/local/lib/ruby/1.8/apache
    > for file in apache/ruby-run.rb apache/eruby-run.rb apache/erb-run.rb
    > apache/rd2html.rb apache/ruby-debug.rb apache/eruby-debug.rb
    > auto-reload.rb; do \
    > /usr/bin/install -c -m 644
    > /private/tmp/ruby/mod_ruby-1.0.7/lib/$file /usr/local/lib/ruby/1.8/$file; \
    > done
    >
    > ....
    >
    > [local/apache/logs] root# cat error_log
    > dyld: /usr/local/apache/bin/httpd Undefined symbols:
    > _rb_cObject
    > _rb_check_type
    > _rb_data_object_alloc
    > _rb_define_class_under
    > _rb_define_method
    > _rb_define_module
    > _rb_define_singleton_method
    > _rb_define_virtual_variable
    > _rb_eStandardError
    > _rb_eval_string_wrap
    > _rb_file_open
    > _rb_funcall
    > _rb_gc_mark
    > _rb_global_variable
    > _rb_intern
    > _rb_io_close
    > _rb_io_gets
    > _rb_protect
    > _rb_provide
    > _rb_raise
    > _rb_set_kcode
    > _rb_stdin
    > _rb_str2cstr
    > _rb_str_cat
    > _rb_str_freeze
    > _rb_str_new
    > _rb_str_new2
    > _re_mbctab
    > _ruby_debug
    > _ruby_show_version
    > _ruby_top_self
    > _ruby_verbose
    > _ruby_xmalloc
    >
    >
    >
    > --
    > (-, /\ \/ / /\/
    >
    Gennady, Jan 22, 2004
    #2
    1. Advertising

  3. Gavin Kistner

    Kevin M Guest

    Gavin Kistner <> wrote in message news:<GoEPb.118161$xy6.376643@attbi_s02>...
    > All day I have been trying to get mod_ruby and eRuby installed on MacOS
    > X 10.3 (Panther) with Apache 1.3.
    > I'm close, but not yet there.


    I had exactly the same problem the other day, and got enough help on
    this newsgroup to solve it. Look back a couple days and you should
    see the thread.

    Basically there's 2 things you need to do: one is to configure ruby
    and eRuby with --enable-shared, and mod_ruby with --with-apxs.

    The second thing is that you'll probably need a newer mod_ruby, as the
    current stable version has some problems on OS X. I ended up using
    the latest dev version (1.1.2 I think) and it's working fine.

    Good luck...

    Kevin
    Kevin M, Jan 22, 2004
    #3
  4. Gennady wrote:
    > 1. Run configure with option "--enable-shared" where appropriate.
    > 2. Get mod_ruby version 1.1.1 (development), 1.0.7 is known to have
    > problems on Mac OS X.
    >
    > Gennady.


    Thanks muchly!

    I haven't tried the --enabled-shared option yet (will have to read about
    it) but getting the latest dev version (which is now 1.1.2) it worked
    perfectly!
    Gavin Kistner, Jan 22, 2004
    #4
  5. Kevin M wrote:

    >>All day I have been trying to get mod_ruby and eRuby installed on MacOS
    >>X 10.3 (Panther) with Apache 1.3.
    >>I'm close, but not yet there.

    >
    >
    > I had exactly the same problem the other day, and got enough help on
    > this newsgroup to solve it. Look back a couple days and you should
    > see the thread.
    >
    > Basically there's 2 things you need to do: one is to configure ruby
    > and eRuby with --enable-shared, and mod_ruby with --with-apxs.


    Heh, thanks. I seem to have learned about this newsgroup 1 day too late.
    Should have searched first :/

    Neither of the install docs I read:
    http://modruby.net/doc/install.en.html
    http://sean.chittenden.org/programming/ruby/mod_ruby/apachecon-2002/mod_ruby_intro.html
    mention the --enable-shared option. I can't seem to find information
    about it online (that actually describes it).

    What does it do? And do I want it on both eRuby and mod_ruby, or only eRuby?



    > The second thing is that you'll probably need a newer mod_ruby, as the
    > current stable version has some problems on OS X. I ended up using
    > the latest dev version (1.1.2 I think) and it's working fine.


    Yup, mine too. Yay!
    Gavin Kistner, Jan 22, 2004
    #5
  6. Gavin Kistner

    Kevin M Guest

    > What does it do? And do I want it on both eRuby and mod_ruby, or only eRuby?

    Um, I'm afraid I don't really know either -- I was just following the
    tips from this group and found that it worked. Do let us know if you
    find out :)

    Kevin
    Kevin M, Jan 22, 2004
    #6
    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. Steven Marcus

    installing ruby on MacOS X

    Steven Marcus, Nov 2, 2004, in forum: Ruby
    Replies:
    4
    Views:
    105
    Robert
    Nov 3, 2004
  2. Jose Marques
    Replies:
    3
    Views:
    358
    Jose Marques
    Apr 21, 2005
  3. Steve M.

    Installing eruby

    Steve M., Oct 10, 2006, in forum: Ruby
    Replies:
    0
    Views:
    94
    Steve M.
    Oct 10, 2006
  4. Dude
    Replies:
    2
    Views:
    95
    John Joyce
    Mar 22, 2007
  5. Franck Ditter
    Replies:
    0
    Views:
    379
    Franck Ditter
    May 1, 2012
Loading...

Share This Page