I have a Debian 8 Jessie server and I've compiled Ruby sources (https://www.ruby-lang.org/en/documentation/installation/#building-from-source).
When I check the version of ruby with ruby -v, I have a correct output
ruby 2.4.0p0 (2016-12-24 revision 57164) [x86_64-linux]
However, when I run the following command:
gem install rails, I have the following error message:
ERROR: Loading command: install (LoadError)
cannot load such file -- zlib
ERROR: While executing gem ... (NoMethodError)
undefined method `invoke_with_build_args' for nil:NilClass
Does anyone have the solution?
Related
I had installed Ruby at the version of 2.7.0 and Gem at the version of 3.1.2 when I used the command " gem install rails " it shows an error like this..
Log:
ax#shivvv:~$ sudo gem install rails
[sudo] password for ax:
ERROR: Loading command: install (LoadError)
cannot load such file -- zlib
ERROR: While executing gem ... (NoMethodError)
undefined method `invoke_with_build_args' for nil:NilClass
ax#shivvv:~$
Help me to find it..
I have Ruby 5.2.3, Homebrew, Xcode, and zlib 1.2.11 installed but I am still running into this error:
ERROR: Loading command: install (LoadError)
cannot load such file -- zlib
ERROR: While executing gem ... (NoMethodError)
undefined method `invoke_with_build_args' for nil:NilClass
I've tried running
gem install rails -v 5.2.3
gem install rails
and
sudo gem install rails
and all give the same error.
I installed Ruby 2.3.3, DevKit and OpenSSL on Windows 7. I followed the instruction to install puma, but I'm getting the error:
C:\Ruby23>gem install puma -- --with-opt-dir=c:\Ruby23\openssl
ERROR: Loading command: install (LoadError)
127: The specified procedure could not be found. - C:/Ruby23/lib/ruby/2.3.0/i386-mingw32/openssl.so
ERROR: While executing gem ... (NoMethodError)
undefined method `invoke_with_build_args' for nil:NilClass
openssl.so is not compatible?
I am trying to install Rails on my Mac. I keep getting a Jruby error or something of the sort:
gem install rails
Loading jruby-openssl in a non-JRuby interpreter
Error loading RubyGems plugin "/Users/User/.rvm/gems/ruby-2.4.0#global/gems/executable-hooks-1.3.2/lib/rubygems_plugin.rb": cannot load such file -- jruby (LoadError)
Loading jruby-openssl in a non-JRuby interpreter
Error loading RubyGems plugin "/Users/User/.rvm/gems/ruby-2.4.0#global/gems/gem-wrappers-1.2.7/lib/rubygems_plugin.rb": cannot load such file -- jruby (LoadError)
Loading jruby-openssl in a non-JRuby interpreter
ERROR: Loading command: install (LoadError)
cannot load such file -- jruby
ERROR: While executing gem ... (NoMethodError)
undefined method `invoke_with_build_args' for nil:NilClass
It looks like I have JRuby installed, which I think happened after I installed Java to install Netbeans. I used RVM to update ruby to 2.4. How do I get back to installing gems?
Thanks
rvm get stable --auto-dotfiles
Using bash on windows. I'm stuck at configuring my environment to get started with ruby on rails. I've installed the ruby and rails but still caught in problems. Details mentioned below
Executed commands and their result is pasted below.
ruby -v
ruby 2.4.0p0 (2016-12-24 revision 57164) [x86_64-linux]
gem install bundler
ERROR: While executing gem ... (TypeError)
no implicit conversion of nil into String
gem update --system
ERROR: While executing gem ... (TypeError)
no implicit conversion of nil into String
rails s
Rails 2.4.0 `<main>': undefined method `activate_bin_path' for Gem:Module (NoMethodError)**
So actually what is the problem?