I'm trying to install the FXRuby gem. I've installed Ruby and Fox with Homebrew on Mac OS 10.7 and I can't figure out how to make it work. Has anyone?
Heres the error print out I have received:
gem install fxruby
Building native extensions. This could take a while...
ERROR: Error installing fxruby:
ERROR: Failed to build gem native extension.
/usr/local/Cellar/ruby/1.9.2-p290/bin/ruby extconf.rb
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of
necessary libraries and/or headers. Check the mkmf.log file for more
details. You may need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/usr/local/Cellar/ruby/1.9.2-p290/bin/ruby
--with-fox-dir
--without-fox-dir
--with-fox-include
--without-fox-include=${fox-dir}/include
--with-fox-lib
--without-fox-lib=${fox-dir}/lib
--with-fxscintilla-dir
--without-fxscintilla-dir
--with-fxscintilla-include
--without-fxscintilla-include=${fxscintilla-dir}/include
--with-fxscintilla-lib
--without-fxscintilla-lib=${fxscintilla-dir}/lib
extconf.rb:31:in `find_installed_fox_version': couldn't find FOX header files (RuntimeError)
from extconf.rb:125:in `<main>'
The error was occurring because the FOX toolkit was not installed on Your machine. FXRuby is a Ruby interface to the FOX graphical toolkit, so therefore requires FOX to be installed on the machine first. For Mac OS X execute
brew install fox
This will install dependencies:
libpng, freetype, jpeg, libtiff
Then install fxruby gem
gem install fxruby
I am using yosemite (OS X 10.10) and fxruby gem version 1.6.28 get installed successfully on my system
I had the same problem and this command fixed it:
sudo apt-get install libfox-1.6-dev
Related
I am trying to install Github Linguist ruby gem through terminal in Mac .
I don't have enough points to upload image so please bear with me.
This is error it is showing when I install it in terminal :-
bash-3.2# gem install github-linguist
Building native extensions. This could take a while...
ERROR: Error installing github-linguist:
ERROR: Failed to build gem native extension.
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby -r ./siteconf20150321-444-15aw05d.rb extconf.rb
checking for gmake... no
checking for make... yes
checking for cmake... no
ERROR: CMake is required to build Rugged.
* extconf.rb failed *
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers. Check the mkmf.log file for more details. You may
need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby
--use-system-libraries
extconf failed, exit code 1
Gem files will remain installed in /Library/Ruby/Gems/2.0.0/gems/rugged-0.22.1b1 for inspection.
Results logged to /Library/Ruby/Gems/2.0.0/extensions/universal-darwin-14/2.0.0/rugged-0.22.1b1/gem_make.out
brew install cmake should do the trick
I know you are not asking how to manager Ruby's versions.
but starting to use RVM will help a lot.
I am trying to install ruby on rails (v4.0) using ruby installer. It is throwing me this error. I am brand new to RoR and some websites told me to install devkit. I have done that. I ran gem install thin
C:\Users\shashid\Downloads>gem install rails
Temporarily enhancing PATH to include DevKit...
Building native extensions. This could take a while...
ERROR: Error installing rails:
ERROR: Failed to build gem native extension.
C:/RubyRails/bin/ruby.exe extconf.rb
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers. Check the mkmf.log file for more details. You may
need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=C:/RubyRails/bin/ruby
--with-atomic_reference-dir
--without-atomic_reference-dir
--with-atomic_reference-include
--without-atomic_reference-include=${atomic_reference-dir}/include
--with-atomic_reference-lib
--without-atomic_reference-lib=${atomic_reference-dir}/
C:/RubyRails/lib/ruby/2.0.0/mkmf.rb:431:in `try_do': The compiler failed to gene
rate an executable file. (RuntimeError)
You have to install development tools first.
from C:/RubyRails/lib/ruby/2.0.0/mkmf.rb:516:in `try_link0'
from C:/RubyRails/lib/ruby/2.0.0/mkmf.rb:814:in `try_run'
from extconf.rb:22:in `<main>'
Gem files will remain installed in C:/RubyRails/lib/ruby/gems/2.0.0/gems/atomic-
1.1.10 for inspection.
Results logged to C:/RubyRails/lib/ruby/gems/2.0.0/gems/atomic-1.1.10/ext/gem_ma
ke.out
Thank you in advance for your help
You need to install Ruby DevKit if on windows, get it from: http://rubyinstaller.org/downloads/ (scroll down a little).
Same story here deleting ruby and installing:
Ruby 2.0.0-p247
DevKit-mingw64-32-4.7.2-20130224-1151-sfx.exe
from http://rubyinstaller.org/downloads/ solved the problem.
Try to use railsinstaller from http://railsinstaller.org/
it will install follwing
Ruby 1.9.3-p392
Rails 4
Bundler
Git
Sqlite
TinyTDS
SQL Server Support
DevKit
The same can happen when you try to combine 32-bit Ruby and 64-bit DevKit.
The solution is to use same-bit versions.
For instance current versions:
rubyinstaller-2.0.0-p247-x64.exe
DevKit-mingw64-64-4.7.2-20130224-1432-sfx.exe
I am trying to install augeas on Ubuntu.
sudo gem install ruby-augeas
This gives me the error:
Building native extensions. This could take a while...
ERROR: Error installing ruby-augeas:
ERROR: Failed to build gem native extension.
/usr/bin/ruby1.9.1 extconf.rb
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of
necessary libraries and/or headers. Check the mkmf.log file for more
details. You may need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/usr/bin/ruby1.9.1
--with-augeas-config
--without-augeas-config
--with-pkg-config
--without-pkg-config
extconf.rb:27:in `<main>': augeas-devel not installed (RuntimeError)
I had
sudo apt-get install ruby1.8-dev ruby1.9.1-dev augeas-tools libaugeas-dev
Btw, where is the mkmf.log file?
How should I install augeas? I need to install it using gem as this will be used for Puppet's version of Ruby.
you need at least build-essential package to compile native extensions. Also make sure you have all the ruby base libraries precompiled (or in the rvm).
Try to install rvm itself, it will give you a list of required packages just after installation.
Having problems installing hpricot on Mac OS X. I suspect it might be an issue between rvm and brew?
rvm 1.0.5
brew 0.7
Thoughts? Suggestions? Thanks!
$ gem install hpricot
Building native extensions. This could take a while...
ERROR: Error installing hpricot:
ERROR: Failed to build gem native extension.
/Users/dhaskin/.rvm/rubies/ruby-1.8.7-p302/bin/ruby extconf.rb
checking for stdio.h... no
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of
necessary libraries and/or headers. Check the mkmf.log file for more
details. You may need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/Users/dhaskin/.rvm/rubies/ruby-1.8.7-p302/bin/ruby
Gem files will remain installed in /Users/dhaskin/.rvm/gems/ruby-1.8.7-p302/gems/hpricot-0.8.2 for inspection.
Results logged to /Users/dhaskin/.rvm/gems/ruby-1.8.7-p302/gems/hpricot-0.8.2/ext/fast_xs/gem_make.out
ERROR: Failed to build gem native extension. and checking for stdio.h... no are suspicious. Hpricot, along with many other Ruby gems, needs to compile some code and will fail if the development package is missing.
You are running RVM and 1.8.7 is in ~/.rvm on your machine, so it looks like it is because RVM would have to compile Ruby, but the failure sounds like it isn't. Do you have Apple's XCode installed in the /Developer directory? If you didn't install it and/or the directory isn't there, you can find the installer on your MacOS install discs, or at Apple's Developer site: http://developer.apple.com/technologies/xcode.html
That aside, I'd recommend using Nokogiri over Hpricot. I ran into several bugs in Hpricot a while back that made it unusable for my needs, and switched to Nokogiri. You'll find the two gems have similar syntax. http://nokogiri.org/
Turns out this was an XCode version dependency. Updating XCode to 3.2.4 resolved this.
I am trying to install sqlite3 and sqlite-ruby (ruby 1.8.6) on a linux box where I do not have root.
I downloaded the sqlite3 source, binaries, and shared library and placed them all in a directory called sqlite3
I then try to install sqlite-ruby using
gem install sqlite-ruby --with-sqlite-dir=the_path_sqlite/sqlite3
but I keep getting the error...
checking for main() in -lsqlite... no
checking for sqlite.h... no
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of
necessary libraries and/or headers. Check the mkmf.log file for more
details. You may need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/data/scratch/bettbra/common/packages/ruby-1.8.6/bin/ruby
--with-sqlite-dir
--with-sqlite-include
--without-sqlite-include=${sqlite-dir}/include
--with-sqlite-lib
--without-sqlite-lib=${sqlite-dir}/lib
--with-sqlitelib
--without-sqlitelib
You specify where the development files (headers & lib) are using the following syntax:
gem install sqlite3 -- --with-sqlite3-include=$HOME/include --with-sqlite3-lib=$HOME/lib
Notice the -- that mark the end of gem options. After them, the options are passed to the extension compiling process.
However, I second Reuben's advice; you should really consider using RVM. It is a blessing for this kind of situations AND to smooth your migration to Ruby 1.9.
i'm using ubuntu (debain type linux). i managed to resolve it the following way:
sudo apt-get install sqlite3 libsqlite3-dev
sudo gem install sqlite3-ruby
Can you install RVM (Ruby Version Manager) ?
https://rvm.io/rvm/install/
With RVM you install gems etc. as a user without sudo/root privileges.