Install Bundle Issue

Added by Kirk Fitzgerald over 4 years ago

update, I was able to get nokogiri, but still getting the same error....

I need some help...

I have been following these instructions:

I having an issue with this step:
Install dependencies using the Gem bundler¶
This step will look at the dependencies specified in the Gemfile:
% cd /var/www/redmine
% bundle install

When I run the command, I get this error:

[fit54@u ~]$ cd /var/www/redmine
[fit54@u redmine]$ bundle install
The dependency tzinfo-data (>= 0) will be unused by any of the platforms Bundler is installing for. Bundler is installing for ruby but the dependency is only for x86-mingw32, x64-mingw32, x86-mswin32. To add those platforms to the bundle, run `bundle lock --add-platform x86-mingw32 x64-mingw32 x86-mswin32`.
/usr/share/gems/gems/psych-2.0.0/lib/psych.rb:98: warning: already initialized constant Psych::VERSION
/usr/share/ruby/psych.rb:98: warning: previous definition of VERSION was here
/usr/share/gems/gems/psych-2.0.0/lib/psych.rb:101: warning: already initialized constant Psych::LIBYAML_VERSION
/usr/share/ruby/psych.rb:101: warning: previous definition of LIBYAML_VERSION was here
Fetching gem metadata from https://rubygems.org/..........
Fetching gem metadata from https://rubygems.org/.
Resolving dependencies....
Using rake 12.3.1
Using i18n 0.7.0
Using minitest 5.11.3
Using thread_safe 0.3.6
Using tzinfo 1.2.5
Using activesupport 4.2.8
Using builder 3.2.3
Using erubis 2.7.0
Using mini_portile2 2.1.0
Fetching nokogiri 1.6.8.1
Installing nokogiri 1.6.8.1 with native extensions
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory: /home/fit54/.gem/ruby/gems/nokogiri-1.6.8.1/ext/nokogiri
/usr/bin/ruby -r ./siteconf20180406-9964-oibzlr.rb extconf.rb
--use-system-libraries
mkmf.rb can't find header files for ruby at /usr/share/include/ruby.h

extconf failed, exit code 1

Gem files will remain installed in /home/fit54/.gem/ruby/gems/nokogiri-1.6.8.1
for inspection.
Results logged to
/home/fit54/.gem/ruby/extensions/x86_64-linux/nokogiri-1.6.8.1/gem_make.out

An error occurred while installing nokogiri (1.6.8.1), and Bundler
cannot continue.
Make sure that `gem install nokogiri -v '1.6.8.1'` succeeds before bundling.

In Gemfile:
rails was resolved to 4.2.8, which depends on
actionmailer was resolved to 4.2.8, which depends on
actionpack was resolved to 4.2.8, which depends on
actionview was resolved to 4.2.8, which depends on
rails-dom-testing was resolved to 1.0.9, which depends on
nokogiri

Please let me know what other information I need to provide or what help can be given to me to help resolve this issue.

Replies (6)

RE: Install Bundle Issue - Added by Martin Denizet (redmine.org team member) over 4 years ago

Hello,
Assuming you're running Ubuntu/Debian, please try:

sudo apt-get install build-essential patch ruby-dev zlib1g-dev liblzma-dev
gem install nokogiri

Otherwise please check these instructions: http://www.nokogiri.org/tutorials/installing_nokogiri.html

I suggest the ruby-dev package will solve your problem.

RE: Install Bundle Issue - Added by Kirk Fitzgerald over 4 years ago

Is there a -dev for ruby 2.5.0, I can't seem to find one.

I am using Redhat 7.4, Ruby 2.5.0, and Maipo

RE: Install Bundle Issue - Added by Kirk Fitzgerald over 4 years ago

Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-
: manager
No package build-essential available.
Package patch-2.7.1-8.el7.x86_64 already installed and latest version
No package ruby-dev available.
No package zlib1g-dev available.
No package liblzma-dev available.
Nothing to do

RE: Install Bundle Issue - Added by Martin Denizet (redmine.org team member) over 4 years ago

According to the documentation, you should run:

sudo yum install -y gcc ruby-devel zlib-devel
#sudo dnf install -y rpm-build # This may be required
gem install nokogiri


Cheers,

RE: Install Bundle Issue - Added by Kirk Fitzgerald over 4 years ago

Alright... so, I got that issue taken care of.

Package gcc-4.8.5-16.el7_4.2.x86_64 already installed and latest version
Package ruby-devel-2.0.0.648-33.el7_4.x86_64 already installed and latest version
Package zlib-devel-1.2.7-17.el7.x86_64 already installed and latest version
Nothing to do

The, I try the nokogiri install:
$ sudo gem install nokogiri
ERROR: Error installing nokogiri:
The last version of nokogiri (>= 0) to support your Ruby & RubyGems was 1.8.2. Try installing it with `gem install nokogiri -v 1.8.2`
nokogiri requires Ruby version >= 2.1.0. The current ruby version is .

ruby 2.5.0p0 (2017-12-25 revision 61468) [x86_64-linux]

RE: Install Bundle Issue - Added by Kirk Fitzgerald over 4 years ago

Finally got it!
ran bundle install --without development test

it installed from there.

Now, on to the next step.

Thank you for your help!

(1-6/6)