When I tried to install: gem install sqlite3-ruby it shows:
Building native extensions. This could take a while...
ERROR: Error installing sqlite3-ruby:
ERROR: Failed to build gem native extension.
/usr/bin/ruby1.8 extconf.rb
extconf.rb:3:in `require': no such file to load -- mkmf (LoadError)
from extconf.rb:3
Gem files will remain installed in /usr/lib/ruby/gems/1.8/gems/sqlite3-ruby-1.3.1 for inspection.
Results logged to /usr/lib/ruby/gems/1.8/gems/sqlite3-ruby-1.3.1/ext/sqlite3/gem_make.out
My environment:
sqlite: 2.8.17
rails: 3.0.0
ruby: 1.9.2
ubuntu: 10.04
gem: 1.3.7
I have looking all similiar question in webs and SO, nothing help, what should I do? :(
I had this same problem. I solved it by
sudo apt-get install sqlite3 libsqlite3-dev
Then the following command worked.
sudo gem install sqlite3-ruby
Related
I am trying to install nokogiri on Ubuntu Linux. I am running Ruby-2.1.1. I have installed.
Output:
sudo gem install nokogiri
Building native extensions. This could take a while...
ERROR: Error installing nokogiri:
ERROR: Failed to build gem native extension.
current directory: /var/lib/gems/2.5.0/gems/nokogiri-1.8.5/ext/nokogiri
/usr/bin/ruby2.5 -r ./siteconf20181205-6502-3n3u4g.rb extconf.rb
mkmf.rb can't find header files for ruby at /usr/lib/ruby/include/ruby.h
extconf failed, exit code 1
Gem files will remain installed in /var/lib/gems/2.5.0/gems/nokogiri-1.8.5 for inspection.
Results logged to /var/lib/gems/2.5.0/extensions/x86_64-linux/2.5.0/nokogiri-1.8.5/gem_make.out
Can anyone explain what I am missing?
Try installing Ruby 2.1.1 with rbenv and set it as default version in ubuntu:
rbenv install 2.1.1
rbenv global 2.1.1
After installing ruby, install the following packages:
sudo apt-get install libxslt-dev libxml2-dev zlib1g-dev
And then install nokogiri:
sudo gem install nokogiri
This should do the trick...
When i run:
sudo gem install yajl-ruby
I see errors:
Building native extensions. This could take a while...
ERROR: Error installing yajl-ruby:
ERROR: Failed to build gem native extension.
/usr/bin/ruby extconf.rb
mkmf.rb can't find header files for ruby at /usr/lib/ruby/ruby.h
Gem files will remain installed in /usr/lib/ruby/gems/1.8/gems/yajl-ruby-1.2.1 for inspection.
Results logged to /usr/lib/ruby/gems/1.8/gems/yajl-ruby-1.2.1/ext/yajl/gem_make.out
I have installed yum install ruby rubygems ruby-devel, but still have this problem.
Try:
$ sudo ln -s /usr/bin/llvm-gcc /usr/bin/gcc-4.2
$ sudo gem install yajl-ruby
I run this command, sudo gem install compass --pre
And this give me an error
Fetching: sass-3.3.14.gem (100%)
Building native extensions. This could take a while...
ERROR: Error installing compass:
ERROR: Failed to build gem native extension.
/usr/bin/ruby1.9.1 extconf.rb
/usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file -- mkmf (LoadError)
from /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from extconf.rb:4:in `<main>'
Gem files will remain installed in /var/lib/gems/1.9.1/gems/ffi-1.9.3 for inspection.
Results logged to /var/lib/gems/1.9.1/gems/ffi-1.9.3/ext/ffi_c/gem_make.out
current compass version -
Compass 0.12.7 (Alnilam)
current ruby version -
ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-linux]
sass version -
Sass 3.3.14 (Maptastic Maple)
gem version -
1.8.23
Just incase no one sees #ymonad's comment, for me the fix was:
apt-get update
apt-get install ruby1.9.1-dev
apt-get install ruby-dev
apt-get install build-essential
as in the title, i have problems installing gem RedCloth. i downloaded RubyGems v1.8.24, and use ubuntu 12.04, here is my console log:
kuba#kuba-P5Q-SE:~$ sudo gem install RedCloth
[sudo] password for kuba:
Building native extensions. This could take a while...
ERROR: Error installing RedCloth:
ERROR: Failed to build gem native extension.
/usr/bin/ruby1.9.1 extconf.rb
/usr/local/lib/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file -- mkmf (LoadError)
from /usr/local/lib/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from extconf.rb:1:in `<main>'
Gem files will remain installed in /usr/lib/ruby/gems/1.9.1/gems/RedCloth-4.2.9 for inspection.
Results logged to /usr/lib/ruby/gems/1.9.1/gems/RedCloth- 4.2.9/ext/redcloth_scan/gem_make.out
i tried to look into this last given file, but when i look for it, it opens chrome, and gives me error.:(
Try installing the ruby1.9.1-dev package from Synaptic, or using apt-get.
In a command prompt:
sudo apt-get install ruby1.9.1-dev
mkmf (the module which is failing to load) is only included in the development package for ruby on ubuntu.
From the console:
adelevie#ubuntu:~$ gem install passenger
Building native extensions. This could take a while...
ERROR: Error installing passenger:
ERROR: Failed to build gem native extension.
/usr/bin/ruby1.8 extconf.rb
/usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require': no such file to load -- mkmf (LoadError)
from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require'
from extconf.rb:8
Gem files will remain installed in /home/adelevie/ruby/gems/gems/fastthread-1.0.7 for inspection.
Results logged to /home/adelevie/ruby/gems/gems/fastthread-1.0.7/ext/fastthread/gem_make.out
What does this mean and what are my options?
it's actually
apt-get install ruby1.8-dev
doing this fixed the problem building passenger for me
You need to install the ruby-dev pacakge.
apt-get install ruby-dev1.8