Re: Whither site_ruby?

Shugo Maeda <[email protected]> Wed, 19 Jan 2005 11:25:52 +0900
Newsgroups gmane.comp.apache.mod-ruby
Message-ID <[email protected]>
Hi,

Dan Cross wrote:
> This works reasonably well, and when I built Ruby, I configured it with
> the ``--with-sitedir=/sw/lib/ruby/1.8'' option, so the Ruby interpreter
> itself will look for modules in the right place, despite being
> installed elsewhere.

If you specify `--with-sitedir=/sw/lib/ruby/1.8', ruby will
search libraries in /sw/lib/ruby/1.8/1.8,
/sw/lib/ruby/1.8/1.8/i686-linux, and /sw/lib/ruby/1.8.
``--with-sitedir=/sw/lib/ruby'' is what you want, isn't it?

> However, when I run ``make site-install'' for mod_ruby, it installs it
> directly into /sw/lib/ruby/site_ruby/1.8, which isn't where I want it.
> Using either `make install' or `make site-install', mod_ruby.so is
> installed directly into the Apache libexec directory, though I can work
> around that with a make variable specified on the command line.

``make site-install'' installs libraries into /sw/lib/ruby/1.8/1.8 on my
machine.
Did you run configure.rb with the right Ruby interpreter?
Please check $sitelibdir by the Ruby interpreter which ran configure.rb

$ ruby -r mkmf -e 'p $sitelibdir'
"$(sitedir)/$(ruby_version)"
$ ruby -r mkmf -e 'p $sitedir'
"$(DESTDIR)/tmp/ruby/1.8"

Then, where do you want to install mod_ruby.so?

Shugo