Arthur
12/9/2004 3:44:00 PM
Steven Marcus wrote:
> Not sure if this is a darwinports or a rubygems problem:
>
> After an install of darwinports, I installed ruby +preview and
rb-rubygems.
>
> Unfortunately,
> $ gem help
> did not work, complaining about an invalid path to the ruby
interpreter.
>
> I found that the path to the ruby interpreter specified in
>
> /opt/local/bin/gem
> /opt/local/bin/gem_server
> /opt/local/bin/update_rubygems
>
> were all bogus. Instead of pointing to /opt/local/bin/ruby, they were
> pointing to my somewhere deep inside the original darwinports source
> installation directory outside the /opt/local subtree.
>
This is very interesting. I just found the same error, when I tried to
install rubygems using darwinports. I made sure to synch up to the
darwinports tree before I tried installing
rb-rubygems
For those interested, the first line in each of those 3 files read:
#!/Users/arthur8/darwinports/dports/ruby/rb-rubygems/work/destroot/opt/local/bin/ruby
rather than the appropriate path:
#!/opt/local/bin/ruby
> I manually patched the files and things appear to be working.
> Anyone know how to go about getting the fix in?
I also editted each of thosee files to alter the ruby executable path,
but a then different problem appeared. Typing
gem
threw an exception:
/opt/local/lib/ruby/1.8/fileutils.rb:181:in `mkdir': Permission denied
- /opt/local/lib/ruby/gems/1.8/doc (Errno::EACCES)
from /opt/local/lib/ruby/1.8/fileutils.rb:181:in `mkdir_p'
from /opt/local/lib/ruby/1.8/fileutils.rb:179:in `reverse_each'
from /opt/local/lib/ruby/1.8/fileutils.rb:179:in `mkdir_p'
from /opt/local/lib/ruby/1.8/fileutils.rb:173:in `each'
from /opt/local/lib/ruby/1.8/fileutils.rb:173:in `mkdir_p'
from /opt/local/lib/ruby/vendor_ruby/1.8/rubygems.rb:272:in
`ensure_gem_subdirectories'
from /opt/local/lib/ruby/vendor_ruby/1.8/rubygems.rb:268:in
`each'
from /opt/local/lib/ruby/vendor_ruby/1.8/rubygems.rb:268:in
`ensure_gem_subdirectories'
.... 17 levels...
from
/opt/local/lib/ruby/vendor_ruby/1.8/rubygems/loadpath_manager.rb:5:in
`require__'
from
/opt/local/lib/ruby/vendor_ruby/1.8/rubygems/loadpath_manager.rb:5:in
`require'
from /opt/local/lib/ruby/vendor_ruby/1.8/rubygems.rb:58:in
`manage_gems'
from /opt/local/bin/gem:4
Evidently, the rb-rubygems darwinports fails to create the doc
directory in
/opt/local/lib/ruby/gems/1.8
Manually creating that doc directory seems to get gem working.
The version of rb-rubygems in darwinports is 0.8.1, but rubygems is now
at 0.8.3. Perhaps the lateset version of rubygems with these fixes in
place can be put into darwinports?
Arthur