Anyone else having trouble installing cuke4nuke via gem install cuke4nuke?
I'm getting the following error and can't figure out what to do to solve it:
Building native extensions. This could take a while...
ERROR: Error installing cuke4nuke:
ERROR: Failed to build gem native extension.
C:/Ruby/bin/ruby.exe extconf.rb
checking for strncpy_s()... no
creating Makefile
nmake
'nmake' is not recognized as an internal or external command,
operable program or batch file.
I'm running:
Windows 7 32-bit box
Ruby 1.8.6 (2008-08-11 patchlevel 287) [i386-mswin32]
RubyGems 1.3.5
edit I also installed the RubyInstaller's devkit
I have the following gems installed:
actionmailer (2.3.5)
actionpack (2.3.5)
activerecord (2.3.5)
activeresource (2.3.5)
activesupport (2.3.5)
builder (2.1.2)
cucumber (0.6.2, 0.5.0, 0.4.4)
diff-lcs (1.1.2)
fxri (0.3.6)
fxruby (1.6.16)
hpricot (0.6.164)
json (1.2.0)
json_pure (1.2.0)
log4r (1.0.5)
polyglot (0.2.9)
ptools (1.1.6)
rack (1.0.1)
rails (2.3.5)
rake (0.8.7, 0.8.1)
ruby-opengl (0.60.0)
term-ansicolor (1.0.4)
test-unit (2.0.1)
treetop (1.4.3, 1.4.2)
win32-api (1.2.1, 1.2.0)
win32-clipboard (0.4.4)
win32-dir (0.3.2)
win32-eventlog (0.5.0)
win32-file (0.5.5)
win32-file-stat (1.3.1)
win32-process (0.5.9)
win32-sapi (0.1.4)
win32-sound (0.4.1)
win32console (1.2.0)
windows-api (0.2.4)
windows-pr (0.9.3)
You didn't follow the installation instructions.
The installation instructions say to use the MinGW version of MRI, but you are using the MSVC version. Also, you have to install a C compiler and C build environment, again as per the installation instructions. If you use the MinGW version, you can use the Devkit provided by the RubyInstaller authors, if you use the MSVC version, you need to install the same compiler that was used to compile MRI: Microsoft Visual C 6.0 (which is no longer available and hasn't been for years).
I had the same problem with installing watir gem.....I copied all the files from ruby folder that is working fine on a different machine...onto my machine...and that solved the problem. I tried many ways...but this is the only way that worked for me. Hope it helps for somebody! :)
Related
Is there a way to install an earlier version of watir-webdriver including dependencies?
I've been running watir-webdriver for a while now, but just ran into problems today when installing on a new Windows environment.
The error is on the require "watir-webdriver". The first error line indicates that ruby is unable to load ffi
C:/Ruby21/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- ffi_c (LoadError)
It looks like the problem may be with the combination of gems, so am including the versions here:
bigdecimal (1.2.4)
childprocess (0.5.3)
ffi (1.9.5 x86-mingw32)
io-console (0.4.2)
json (1.8.1)
minitest (4.7.5)
multi_json (1.10.1)
psych (2.0.5)
rake (10.1.0)
rdoc (4.1.0)
rubyzip (1.1.6)
selenium-webdriver (2.43.0)
test-unit (2.1.3.0)
watir-webdriver (0.6.11, 0.6.10)
websocket (1.2.1)
If you know of a version that worked in the past, you can simple remove the current version and install an old one with the -v flag for gem install.
For example,
gem uninstall watir-webdriver
gem install watir-webdriver -v '= 0.4.0'
You can find the different available version on rubygems.org It will automatically install the proper dependencies.
I am trying to get my ruby environment properly setup, but keep receiving errors when attempting to bundle install my test app.
I first get an error when trying to bundle install:
$ rails new app
// [...]
run bundle install
Fetching gem metadata from https://rubygems.org/..
Resolving dependencies...
Using rake (10.1.0)
Using i18n (0.6.5)
Using multi_json (1.7.9)
Using activesupport (3.2.9)
Using builder (3.0.4)
Using activemodel (3.2.9)
Using erubis (2.7.0)
Using journey (1.0.4)
Using rack (1.4.5)
Using rack-cache (1.2)
Using rack-test (0.6.2)
Using hike (1.2.3)
Using tilt (1.4.1)
Using sprockets (2.2.2)
Using actionpack (3.2.9)
Using mime-types (1.23)
Using polyglot (0.3.3)
Using treetop (1.4.14)
Using mail (2.4.4)
Using actionmailer (3.2.9)
Using arel (3.0.2)
Using tzinfo (0.3.37)
Using activerecord (3.2.9)
Using activeresource (3.2.9)
Using bundler (1.3.5)
Using coffee-script-source (1.6.3)
Using execjs (1.4.0)
Using coffee-script (2.2.0)
Using rack-ssl (1.3.3)
Installing json (1.8.0)
Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
/Users/ryan/.rvm/rubies/ruby-1.9.3-p327/bin/ruby extconf.rb
creating Makefile
make
compiling generator.c
gcc-4.6: error: x86_64: No such file or directory
gcc-4.6: error: unrecognized option '-arch'
make: *** [generator.o] Error 1
Gem files will remain installed in /Users/ryan/.rvm/gems/ruby-1.9.3-p327/gems/json-1.8.0 for inspection.
Results logged to /Users/ryan/.rvm/gems/ruby-1.9.3-p327/gems/json-1.8.0/ext/json/ext/generator/gem_make.out
An error occurred while installing json (1.8.0), and Bundler cannot continue.
Make sure that `gem install json -v '1.8.0'` succeeds before bundling.
Following the last line of the error message I attempt to gem install json -v '1.8.0' but get the following:
Building native extensions. This could take a while...
ERROR: Error installing json:
ERROR: Failed to build gem native extension.
/Users/ryan/.rvm/rubies/ruby-1.9.3-p327/bin/ruby extconf.rb
creating Makefile
make
compiling generator.c
gcc-4.6: error: x86_64: No such file or directory
gcc-4.6: error: unrecognized option '-arch'
make: *** [generator.o] Error 1
Gem files will remain installed in /Users/ryan/.rvm/gems/ruby-1.9.3-p327/gems/json-1.8.0 for inspection.
Results logged to /Users/ryan/.rvm/gems/ruby-1.9.3-p327/gems/json-1.8.0/ext/json/ext/generator/gem_make.out
Any help would be greatly appreciated... I currently using the following versions of rvm, ruby + rails:
$ ruby -v
ruby 1.9.3p327 (2012-11-10) [x86_64-darwin12.2.0]
$ rails -v
Rails 3.2.9
$ rvm -v
rvm 1.22.1 (stable) by Wayne E. Seguin <wayneeseguin#gmail.com>, Michal Papis <mpapis#gmail.com> [https://rvm.io/]
Please let me know if you need any other information.
sounds like this can be caused by binary ruby, try:
rvm get head
rvm reinstall 1.9.3-p327 --disable-binary
delete gemfile.lock and run bundle
If you have rvm installed, this should work:
rvm reinstall 2.0.0-p247 --disable-binary
If you just updated OS X, you might want to try some other things first. See thoughtbot's guide.
I had this problem, I decided to changing the default version of Ruby for 1.9.3p327.
Leaving the project folder and making the command:
rvm use 1.9.3-P327 --default
I do not know why this, for rvm modifies the version within the project, but after doing it gave no error when doing the 'bundle install'
I think you should set correct version your rvm. for example if your developed your application in ruby 1.9.3, you should set
"rvm use 1.9.3". Then you can enter "bundle install" command. Maybe this will help you.
Thanks
I'm trying to build capybara-webkit on XP. I follow this instruction. I says:
8) Clone latest version of capybara-webkit from Github:
$ git clone git://github.com/thoughtbot/capybara-webkit.git
9) Bundle/Install capybara-webkit version:
$ cd ruby193\capybara-webkit
$ bundle install
I did so at the first time. It installed some gems. Then I followed the instruction steps but couldn't build capybara-webkit. So to begin one more time, I deleted all the gems that were installed manually. Now I follow all the same steps but bundle install doesn't work any more. I says that all the gems are present:
C:\RailsInstaller\Ruby1.9.3\lib\ruby\gems\1.9.1\gems>cd capybara-webkit
C:\RailsInstaller\Ruby1.9.3\lib\ruby\gems\1.9.1\gems\capybara-webkit>bundle install
Resolving dependencies...
Using rake (0.9.2)
Using addressable (2.3.2)
Using bundler (1.3.5)
Using appraisal (0.4.0)
Using mime-types (1.22)
Using nokogiri (1.5.9)
Using rack (1.5.2)
Using rack-test (0.6.2)
Using xpath (2.0.0)
Using capybara (2.1.0)
Using json (1.8.0)
Using capybara-webkit (1.0.0) from source at .
Using ffi (1.2.0)
Using childprocess (0.3.6)
Using diff-lcs (1.1.2)
Using websocket (1.0.6)
Using libwebsocket (0.1.7.1)
Using subexec (0.0.4)
Using mini_magick (3.2.1)
Using multi_json (1.5.0)
Using rack-protection (1.3.2)
Using rspec-core (2.6.4)
Using rspec-expectations (2.6.0)
Using rspec-mocks (2.6.0)
Using rspec (2.6.0)
Using rubyzip (0.9.9)
Using selenium-webdriver (2.27.2)
Using tilt (1.3.3)
Using sinatra (1.3.5)
Your bundle is complete!
Use `bundle show [gemname]` to see where a bundled gem is installed.
But now I check these gems with bundle show but it says they all were deleted:
C:\RailsInstaller\Ruby1.9.3\lib\ruby\gems\1.9.1\gems\capybara-webkit>bundle show sinatra
The gem sinatra has been deleted. It was installed at:
C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/sinatra-1.3.5
C:\RailsInstaller\Ruby1.9.3\lib\ruby\gems\1.9.1\gems\capybara-webkit>bundle show selenium-webdriver
The gem selenium-webdriver has been deleted. It was installed at:
C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2
C:\RailsInstaller\Ruby1.9.3\lib\ruby\gems\1.9.1\gems\capybara-webkit>bundle show mini_magick
The gem mini_magick has been deleted. It was installed at:
C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/mini_magick-3.2.1
How it can be that bundle install says they are present but bundle show says they are deleted? So bundle install doesn't work any more. How may I again use bundle install to install these gems again?
This solved it for me: "gem install" and "bundle install" do not install gem dependencies after manual gem deletion. How to inform Rubygems that gems were deleted manually?
(Delete the .gemspec files for the gems you have removed).
I can´t install the rcov gem ;-(
I use BitNami Redmine, Windows 7.
gem install rcov
Result:
Temporarily enhancing PATH to include DevKit...
Building native extensions. This could take a while...
ERROR: Error installing rcov:
ERROR: Failed to build gem native extension.
"C:/Program Files/BitNami Redmine Stack/ruby/bin/ruby.exe" extconf.rb
creating Makefile
make
Makefile:130: warning: overriding commands for target `C:/Program'
Makefile:124: warning: ignoring old commands for target `C:/Program'
Makefile:130: warning: overriding commands for target `Files/BitNami'
Makefile:124: warning: ignoring old commands for target `Files/BitNami'
Makefile:130: warning: overriding commands for target `Redmine'
Makefile:124: warning: ignoring old commands for target `Redmine'
make: *** No rule to make target `ruby.h', needed by `callsite.o'. Stop.
Gem files will remain installed in C:/Program Files/BitNami Redmine Stack/ruby/l
ib/ruby/gems/1.8/gems/rcov-1.0.0 for inspection.
Results logged to C:/Program Files/BitNami Redmine Stack/ruby/lib/ruby/gems/1.8/
gems/rcov-1.0.0/ext/rcovrt/gem_make.out
Before this message BitNami told me to install the DevKit. I installed the DevKit, did edit the confiy.yml (- C:/Program Files/BitNami Redmine Stack/ruby -- maybe this was my fault because I don´t wrote the "") and startet the DevKit installation. Everything was fine but it´s not possible to install the gem. In my opinion it was a very bad idea to install Redmine into a folder with spaces.
I searched for a solution but none solution did work ;-(
Solution 1: I substed the BitNami path to X, tried the installation but that didn´t work.
Solution 2: Use the Microsoft C++ Express advice (http://minimalbugs.com/questions/how-to-install-gem-rcov-on-windows)
Solution 3: An older version of rcov (like 0.9.11) also didn´t work
If I try to install the rdiscount gem I got a similar error (Makefile 130 / 124 / ... C:/Program/...).
Now I need help ;-)
My gems:
*** LOCAL GEMS ***
actionmailer (3.2.6, 2.3.14)
actionpack (3.2.6, 2.3.14)
activemodel (3.2.6)
activerecord (3.2.6, 2.3.14)
activeresource (3.2.6, 2.3.14)
activesupport (3.2.6, 2.3.14)
addressable (2.2.8)
after_commit (1.0.10)
allison (2.0.3)
arel (3.0.2)
aws-sdk (1.5.5, 1.5.2)
bcrypt-ruby (3.0.1 x86-mingw32)
bluecloth (2.1.0 x86-mingw32)
builder (3.0.0, 2.1.2)
bundler (1.1.4, 1.0.21)
capistrano (2.12.0, 2.9.0)
capybara (1.1.2)
cgi_multipart_eof_fix (2.5.0)
childprocess (0.3.3)
coderay (1.0.7, 1.0.6)
crack (0.3.1)
cucumber (1.2.1, 0.9.4)
cucumber-rails (1.3.0, 0.3.2)
daemons (1.1.8, 1.0.10)
delayed_job (3.0.3, 2.0.7)
diff-lcs (1.1.3, 1.1.2)
echoe (4.5.6)
edavis10-object_daddy (0.4.3)
erubis (2.7.0)
eventmachine (0.12.10)
fastercsv (1.5.5, 1.5.4)
ffi (1.0.9 x86-mingw32)
gem_plugin (0.2.3)
gemcutter (0.7.1)
gherkin (2.11.1 x86-mingw32, 2.2.9 x86-mingw32)
gruff (0.3.6)
highline (1.6.13, 1.6.8)
hike (1.2.1)
hoe (3.0.6, 2.12.4)
hpricot (0.8.5 i386-mswin32)
httparty (0.8.3, 0.8.1)
i18n (0.6.0, 0.4.2)
journey (1.0.4, 1.0.3)
json (1.4.6 x86-mingw32)
json_pure (1.7.3, 1.6.3)
libwebsocket (0.1.3)
mail (2.4.4)
memcache-client (1.8.5)
metaclass (0.0.1)
mime-types (1.19, 1.18)
mini_magick (3.4, 3.3)
mocha (0.11.4, 0.10.5)
mongrel (1.1.5 x86-mingw32)
mongrel_cluster (1.0.5)
mongrel_service (0.4.0)
multi_json (1.3.6, 1.1.0)
multi_xml (0.5.1, 0.4.1)
mysql (2.8.1 x86-mingw32)
needle (1.3.0)
net-ldap (0.3.1)
net-scp (1.0.4)
net-sftp (2.0.5)
net-ssh (2.5.2, 2.2.1)
net-ssh-gateway (1.1.0)
nokogiri (1.5.5 x86-mingw32, 1.5.0 x86-mingw32, 1.4.4 x86-mingw32)
polyglot (0.3.3)
prototype-rails (3.2.1)
rack (1.4.1, 1.1.3)
rack-cache (1.2)
rack-openid (1.3.1)
rack-ssl (1.3.2)
rack-test (0.6.1, 0.5.7)
rails (3.2.6, 2.3.14)
rails_analyzer_tools (1.4.0)
railties (3.2.6)
rake (0.9.2.2)
rake-compiler (0.8.1, 0.7.9)
rdoc (3.12, 3.11)
RedCloth (4.2.9 x86-mingw32)
riddle (1.5.2, 1.5.0)
rmagick (2.12.0)
rspec (2.10.0, 2.7.0)
rspec-core (2.10.1, 2.7.1)
rspec-expectations (2.10.0, 2.7.0)
rspec-mocks (2.10.1, 2.7.0)
ruby-openid (2.1.8)
rubyforge (2.0.4)
rubyzip (0.9.9)
selenium-webdriver (2.24.0)
simplecov (0.6.4)
simplecov-html (0.5.3)
sprockets (2.4.3, 2.1.3, 2.1.2)
sqlite3 (1.3.6 x86-mingw32, 1.3.5 x86-mingw32)
sqlite3-ruby (1.3.2 x86-mingw32)
subexec (0.2.2, 0.1.0)
SyslogLogger (1.4.1, 1.4.0)
term-ansicolor (1.0.7)
thin (1.3.1)
thinking-sphinx (2.0.12, 1.4.10)
thor (0.15.3, 0.14.6)
tilt (1.3.3)
treetop (1.4.10, 1.4.5)
tzinfo (0.3.33)
uuidtools (2.1.2)
webrat (0.7.3)
xpath (0.1.4)
yard (0.8.2.1, 0.8.1)
I had the same error. Everything solved it self by changing the installation location of the Bitnami Redmine Stack. Default location is C:\Program Files\Bitnami Redmine Stack\
The "make" which is included in the DevKit can't handle spaces in the pathname.
I installed the bitnami stack to C:\BitNamiRedmine\ and now everything works perfectly.
Install Bitname Redmine to a path without spaces, e.g. C:\BitNamiRedmine\
Download the Ruby Development Kit -> http://rubyinstaller.org/downloads/
Extract the DevKit to C:\BitNamiRedmine\ruby\devkit\
use_redmine.bat
cd ruby\devkit
run ruby dk.rb init
add »- "C:/BitNamiRedmine/ruby"« (without »«, Important: Forward-Slashes!) to the config.yml in the DevKit folder
run ruby dk.rb install
Done!
Now you can navigate to your apps/redmine/htdocs folder and run gem install rcov.
Tested on Windows Server 2008 R2.
I'm learning to use Sinatra + Datamapper to build a lightweight webapp.
I ran gem install sqlite3 datamapper dm-sqlite-adapter and it seemed to have successfully installed...
I then tried to execute my .rb file which starts with:
require 'sinatra'
require 'datamapper'
and I got an error that it could not find the datamapper file.
C:/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': no such file to load -- datamapper (LoadError)
I also tried with require 'data_mapper' since there is conflicting information on the internetz as to the correct spelling of that gem, but same result.
I then listed all my installed gems (see below) and realilsed that there is no such gem as datamapper or data_mapper. I read so,ewhere that it is a meta-gem, I guess that means it doesn't actually install that one gem but rather all the gems starting with dm- ?
As a last resort I tried gem install data_mapper
and I got the ill fated:
C:\Users\Manu\Sinatra>gem install data_mapper
Building native extensions. This could take a while...
ERROR: Error installing data_mapper:
ERROR: Failed to build gem native extension.
C:/Ruby192/bin/ruby.exe extconf.rb
creating Makefile
make
'make' is not recognized as an internal or external command,operable program or batch file.
Gem files will remain installed in C:/Ruby192/lib/ruby/gems/1.9.1/gems/json-1.6.4 for inspection.
Results logged to C:/Ruby192/lib/ruby/gems/1.9.1/gems/json-1.6.4/ext/json/ext/parser/gem_make.out
I searched all over and just couldn't find anything to help me troubleshoot this, so hopefully there's someone roaming this forum with a magic wand and a pointy hat!
Many thanks
PS: I'm running ruby 1.9.2p0 installed with the installer
* LOCAL GEMS *
abstract (1.0.0)
actionmailer (3.0.3)
actionpack (3.0.3)
activemodel (3.0.3)
activerecord (3.0.3)
activeresource (3.0.3)
activesupport (3.0.3)
addressable (2.2.6)
arel (2.0.6)
backports (2.3.0)
builder (2.1.2)
bundler (1.0.7)
cgi_multipart_eof_fix (2.5.0)
data_objects (0.10.7)
diff-lcs (1.1.3)
dm-aggregates (1.2.0)
dm-constraints (1.2.0)
dm-core (1.2.0)
dm-do-adapter (1.2.0)
dm-migrations (1.2.0)
dm-sqlite-adapter (1.2.0)
dm-transactions (1.2.0)
do_sqlite3 (0.10.7 x86-mingw32)
erubis (2.6.6)
fastercsv (1.5.4)
gem_plugin (0.2.3)
growl (1.0.3)
i18n (0.5.0)
json_pure (1.6.4)
mail (2.2.12)
mime-types (1.16)
minitest (1.6.0)
mongrel (1.1.5 x86-mingw32)
multi_json (1.0.4)
polyglot (0.3.1)
rack (1.4.0, 1.2.1)
rack-mount (0.6.13)
rack-protection (1.2.0)
rack-test (0.5.6)
rails (3.0.3)
railties (3.0.3)
rake (0.8.7)
rdoc (2.5.8)
rspec (2.8.0)
rspec-core (2.8.0)
rspec-expectations (2.8.0)
rspec-mocks (2.8.0)
rubygems-update (1.8.15)
sinatra (1.3.2)
sqlite3 (1.3.5 x86-mingw32)
sqlite3-ruby (1.3.3, 1.3.2 x86-mingw32)
sys-uname (0.9.0 x86-mingw32)
thor (0.14.6)
tilt (1.3.3)
treetop (1.4.9)
trollop (1.16.2)
tzinfo (0.3.23)
yard (0.7.4)
It seems the RubyInstaller Development Kit is missing:
http://rubyinstaller.org/add-ons/devkit/
The devkit installs a C-compiler (and some other stuff like make) to compile C-written parts.
Install it and try again to install the gem - perhaps with option --platform=ruby.
Details can be found at https://github.com/oneclick/rubyinstaller/wiki/Development-Kit