Hi,
I am trying to use Ruby on OS X. I installed libnet4r using gem and then
when I try to do *require ‘libnet4r’ *in a script, I get a LoadError. I have
added the path to libnet4r to LOAD_PATH. Still it does not work. What might
be the problem?
Thanks
···
--
Abhishek
I used to hit that all the time cuz I'd forget one minor detail... try adding the following before your require statements:
require 'rubygems'
···
-----Original Message-----
From: Abhishek Chanda [mailto:rony358@gmail.com]
Sent: Thursday, July 14, 2011 6:14 PM
To: ruby-talk ML
Subject: Problem with Ruby on OS X
Hi,
I am trying to use Ruby on OS X. I installed libnet4r using gem and then when I try to do *require 'libnet4r' *in a script, I get a LoadError. I have added the path to libnet4r to LOAD_PATH. Still it does not work. What might be the problem?
Thanks
--
Abhishek
require 'rubygems' first?
···
--
Posted via http://www.ruby-forum.com/.
Thanks for the replies.
I got the same error for rubygems! The output of gem environment is
RubyGems Environment:
- RUBYGEMS VERSION: 1.8.5
- RUBY VERSION: 1.8.7 (2009-06-12 patchlevel 174) [universal-darwin10.0]
- INSTALLATION DIRECTORY: /Library/Ruby/Gems/1.8
- RUBY EXECUTABLE:
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
- EXECUTABLE DIRECTORY: /usr/bin
- RUBYGEMS PLATFORMS:
- ruby
- universal-darwin-10
- GEM PATHS:
- /Library/Ruby/Gems/1.8
- /Users/rony/.gem/ruby/1.8
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :benchmark => false
- :backtrace => false
- :bulk_threshold => 1000
- REMOTE SOURCES:
- http://rubygems.org/
I added /Library/Ruby/Gems/1.8 to LOAD_PATH in irb and tried the same, but
got LoadError.
Thanks
···
On Thu, Jul 14, 2011 at 9:38 PM, Alex Stahl <astahl@hi5.com> wrote:
I used to hit that all the time cuz I'd forget one minor detail... try
adding the following before your require statements:
require 'rubygems'
-----Original Message-----
From: Abhishek Chanda [mailto:rony358@gmail.com]
Sent: Thursday, July 14, 2011 6:14 PM
To: ruby-talk ML
Subject: Problem with Ruby on OS X
Hi,
I am trying to use Ruby on OS X. I installed libnet4r using gem and then
when I try to do *require 'libnet4r' *in a script, I get a LoadError. I have
added the path to libnet4r to LOAD_PATH. Still it does not work. What might
be the problem?
Thanks
--
Abhishek
--
Abhishek
Hi,
I figured it out. Gem was using a different ruby. Once I removed the old
Ruby, it worked perfectly.
Thanks all
···
On Thu, Jul 14, 2011 at 9:51 PM, Abhishek Chanda <rony358@gmail.com> wrote:
Thanks for the replies.
I got the same error for rubygems! The output of gem environment is
RubyGems Environment:
- RUBYGEMS VERSION: 1.8.5
- RUBY VERSION: 1.8.7 (2009-06-12 patchlevel 174) [universal-darwin10.0]
- INSTALLATION DIRECTORY: /Library/Ruby/Gems/1.8
- RUBY EXECUTABLE:
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
- EXECUTABLE DIRECTORY: /usr/bin
- RUBYGEMS PLATFORMS:
- ruby
- universal-darwin-10
- GEM PATHS:
- /Library/Ruby/Gems/1.8
- /Users/rony/.gem/ruby/1.8
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :benchmark => false
- :backtrace => false
- :bulk_threshold => 1000
- REMOTE SOURCES:
- http://rubygems.org/
I added /Library/Ruby/Gems/1.8 to LOAD_PATH in irb and tried the same, but
got LoadError.
Thanks
On Thu, Jul 14, 2011 at 9:38 PM, Alex Stahl <astahl@hi5.com> wrote:
> I used to hit that all the time cuz I'd forget one minor detail... try
> adding the following before your require statements:
>
> require 'rubygems'
>
>
> -----Original Message-----
> From: Abhishek Chanda [mailto:rony358@gmail.com]
> Sent: Thursday, July 14, 2011 6:14 PM
> To: ruby-talk ML
> Subject: Problem with Ruby on OS X
>
> Hi,
>
> I am trying to use Ruby on OS X. I installed libnet4r using gem and then
> when I try to do *require 'libnet4r' *in a script, I get a LoadError. I
have
> added the path to libnet4r to LOAD_PATH. Still it does not work. What
might
> be the problem?
>
> Thanks
>
> --
> Abhishek
>
>
--
Abhishek
--
Abhishek