gems not recognized -- can't fake fox14

B

bwv549

Some gems, after installation, cannot be found with a "require
<whatever_gem>" statement. Perhaps this is specific to my ruby
install, but I am not sure.

I installed gnuplot.rb and it was not found with a require statement.
So, I made a soft link:
ln -s /usr/local/lib/ruby/gems/1.8/gems/gnuplot-2.1/lib/gnuplot.rb
/usr/local/lib/ruby/site_ruby/1.8/gnuplot.rb

and that solved the problem for gnuplot, although in a somewhat
unsatisfying way.

Now, I installed fxruby with no problems, but again, I try to 'require
fox14' and it fails:
-e:1:in `require': No such file to load -- fox14 (LoadError)

This time, making a soft link to the fox14 directory does NOT fix the
problem:
ln -s /usr/local/lib/ruby/gems/1.8/gems/fxruby-1.4.3/lib/fox14
/usr/local/lib/ruby/site_ruby/1.8/fox14

The output of "ruby -e 'p $LOAD_PATH'" is:
["/usr/local/lib/ruby/site_ruby/1.8",
"/usr/local/lib/ruby/site_ruby/1.8/i686-linux",
"/usr/local/lib/ruby/site_ruby", "/usr/local/lib/ruby/1.8",
"/usr/local/lib/ruby/1.8/i686-linux", "."]
(I am running Mandriva 2005 LE)

Is there a way to permanently add the gems folder to $LOAD_PATH?
Does a require statement have to point to a *.rb file, or can it point
to the directory?

Thank You.
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top