I am unable to install Unicorn on localhost (OS -- Windows 8).
>gem install unicorn
Temporarily enhancing PATH to include DevKit...
Building native extensions. This could take a while...
ERROR: Error installing unicorn:
ERROR: Failed to build gem native extension.
E:/software/Ruby200-x64/bin/ruby.exe extconf.rb
checking for CLOCK_MONOTONIC in time.h... yes
checking for clockid_t in time.h... yes
checking for clock_gettime() in -lrt... no
checking for t_open() in -lnsl... no
checking for socket() in -lsocket... no
checking for poll() in poll.h... no
checking for getaddrinfo() in sys/types.h,sys/socket.h,netdb.h... no
getaddrinfo required
*** 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=E:/software/Ruby200-x64/bin/ruby
--with-rtlib
--without-rtlib
--with-nsllib
--without-nsllib
--with-socketlib
--without-socketlib
Gem files will remain installed in E:/software/Ruby200-x64/lib/ruby/gems/2.0.0/gems/kgio-2.9.2 for inspection.
Results logged to E:/software/Ruby200-x64/lib/ruby/gems/2.0.0/gems/kgio-2.9.2/ext/kgio/gem_make.out
Why? What am I doing wrong? How can I fix it?
I'm using Ruby on Rails 4.1.4 btw.
Thanks in advance.
Unicorn does not have native Windows support.
Related
I am not a Ruby developer and I am finding many difficult to install Redmine (that is developed in Ruby) on an Ububuntu 16.04 server.
I am following this official tutorial: http://www.redmine.org/projects/redmine/wiki/HowTo_Install_Redmine_on_Ubuntu_step_by_step
It seems very simple but I am finding many difficult when it "ensure that the bundler GEM is installed".
I am not sure about what exactly is this bundler GEM that have to be installed. From what I have understand (correct me if I am doing wrong assertion) a GEM is something that packages excutable Ruby application (something like a JAR file in Java).
So, the problem is that when I perform this statment in the bash console:
sudo gem update
I obtain many error messages like this:
root#Betrivius-VPS:~# sudo gem update
Updating installed gems
Updating molinillo
Fetching: molinillo-0.5.4.gem (100%)
Successfully installed molinillo-0.5.4
Parsing documentation for molinillo-0.5.4
Installing ri documentation for molinillo-0.5.4
Installing darkfish documentation for molinillo-0.5.4
Done installing documentation for molinillo after 1 seconds
Parsing documentation for molinillo-0.5.4
Done installing documentation for molinillo after 0 seconds
Updating mysql2
Building native extensions. This could take a while...
ERROR: Error installing mysql2:
ERROR: Failed to build gem native extension.
current directory: /var/lib/gems/2.3.0/gems/mysql2-0.4.5/ext/mysql2
/usr/bin/ruby2.3 -r ./siteconf20161115-29205-1v41srl.rb extconf.rb
checking for rb_absint_size()... yes
checking for rb_absint_singlebit_p()... yes
checking for ruby/thread.h... yes
checking for rb_thread_call_without_gvl() in ruby/thread.h... yes
checking for rb_thread_blocking_region()... no
checking for rb_wait_for_single_fd()... yes
checking for rb_hash_dup()... yes
checking for rb_intern3()... yes
checking for rb_big_cmp()... yes
checking for mysql_query() in -lmysqlclient... no
-----
mysql client is missing. You may need to 'apt-get install libmysqlclient-dev' or 'yum install mysql-devel', and try again.
-----
*** 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/$(RUBY_BASE_NAME)2.3
--with-mysql-dir
--without-mysql-dir
--with-mysql-include
--without-mysql-include=${mysql-dir}/include
--with-mysql-lib
--without-mysql-lib=${mysql-dir}/lib
--with-mysql-config
--without-mysql-config
--with-mysql-dir
--without-mysql-dir
--with-mysql-include
--without-mysql-include=${mysql-dir}/include
--with-mysql-lib
--without-mysql-lib=${mysql-dir}/lib
--with-mysqlclientlib
--without-mysqlclientlib
To see why this extension failed to compile, please check the mkmf.log which can be found here:
/var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/mysql2-0.4.5/mkmf.log
extconf failed, exit code 1
Gem files will remain installed in /var/lib/gems/2.3.0/gems/mysql2-0.4.5 for inspection.
Results logged to /var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/mysql2-0.4.5/gem_make.out
Updating 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.3.0/gems/nokogiri-1.6.8.1/ext/nokogiri
/usr/bin/ruby2.3 -r ./siteconf20161115-29205-11qd2.rb extconf.rb
checking if the C compiler accepts ... yes
Building nokogiri using packaged libraries.
Using mini_portile version 2.1.0
checking for gzdopen() in -lz... no
zlib is missing; necessary for building libxml2
*** 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/$(RUBY_BASE_NAME)2.3
--help
--clean
--use-system-libraries
--enable-static
--disable-static
--with-zlib-dir
--without-zlib-dir
--with-zlib-include
--without-zlib-include=${zlib-dir}/include
--with-zlib-lib
--without-zlib-lib=${zlib-dir}/lib
--enable-cross-build
--disable-cross-build
To see why this extension failed to compile, please check the mkmf.log which can be found here:
/var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/nokogiri-1.6.8.1/mkmf.log
extconf failed, exit code 1
Gem files will remain installed in /var/lib/gems/2.3.0/gems/nokogiri-1.6.8.1 for inspection.
Results logged to /var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/nokogiri-1.6.8.1/gem_make.out
Updating psych
Fetching: psych-2.2.0.gem (100%)
Building native extensions. This could take a while...
Successfully installed psych-2.2.0
Parsing documentation for psych-2.2.0
Installing ri documentation for psych-2.2.0
Installing darkfish documentation for psych-2.2.0
Done installing documentation for psych after 2 seconds
Parsing documentation for psych-2.2.0
Done installing documentation for psych after 1 seconds
Updating rmagick
Building native extensions. This could take a while...
ERROR: Error installing rmagick:
ERROR: Failed to build gem native extension.
current directory: /var/lib/gems/2.3.0/gems/rmagick-2.16.0/ext/RMagick
/usr/bin/ruby2.3 -r ./siteconf20161115-29205-1qfeji3.rb extconf.rb
checking for gcc... yes
checking for Magick-config... no
checking for pkg-config... no
Can't install RMagick 2.16.0. Can't find Magick-config or pkg-config in /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin
*** 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/$(RUBY_BASE_NAME)2.3
To see why this extension failed to compile, please check the mkmf.log which can be found here:
/var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/rmagick-2.16.0/mkmf.log
extconf failed, exit code 1
Gem files will remain installed in /var/lib/gems/2.3.0/gems/rmagick-2.16.0 for inspection.
Results logged to /var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/rmagick-2.16.0/gem_make.out
Updating sqlite3
Building native extensions. This could take a while...
ERROR: Error installing sqlite3:
ERROR: Failed to build gem native extension.
current directory: /var/lib/gems/2.3.0/gems/sqlite3-1.3.12/ext/sqlite3
/usr/bin/ruby2.3 -r ./siteconf20161115-29205-1mvfxcm.rb extconf.rb
checking for sqlite3.h... no
sqlite3.h is missing. Try 'brew install sqlite3',
'yum install sqlite-devel' or 'apt-get install libsqlite3-dev'
and check your shared library search path (the
location where your sqlite3 shared library is located).
*** 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/$(RUBY_BASE_NAME)2.3
--with-sqlite3-config
--without-sqlite3-config
--with-pkg-config
--without-pkg-config
--with-sqlite3-dir
--without-sqlite3-dir
--with-sqlite3-include
--without-sqlite3-include=${sqlite3-dir}/include
--with-sqlite3-lib
--without-sqlite3-lib=${sqlite3-dir}/lib
To see why this extension failed to compile, please check the mkmf.log which can be found here:
/var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/sqlite3-1.3.12/mkmf.log
extconf failed, exit code 1
In these error messages it say that I have to check the /var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/sqlite3-1.3.12/mkmf.log file content, this is its content (that maybe could give some additional information to understand where is the probem):
package configuration for sqlite3 is not found
find_header: checking for sqlite3.h... -------------------- no
"gcc -o conftest -I/usr/include/x86_64-linux-gnu/ruby-2.3.0 -I/usr/include/ruby-2.3.0/ruby/backward -I/usr/include/ruby-2.3.0 -I. -Wdate-t$
checked program was:
/* begin */
1: #include "ruby.h"
2:
3: int main(int argc, char **argv)
4: {
5: return 0;
6: }
/* end */
"gcc -E -I/usr/include/x86_64-linux-gnu/ruby-2.3.0 -I/usr/include/ruby-2.3.0/ruby/backward -I/usr/include/ruby-2.3.0 -I. -Wdate-time -D_FO$
conftest.c:3:21: fatal error: sqlite3.h: No such file or directory
compilation terminated.
checked program was:
/* begin */
1: #include "ruby.h"
2:
3: #include <sqlite3.h>
/* end */
--------------------
So, reading the previous log file, it seems that the problem could be related to:
fatal error: sqlite3.h: No such file or directory
It seems that a C header file is missing but I really don't know why.
What am I missing? How can I try to fix this issue?
I am not sure about what exactly is this bundler GEM that have to be installed
-> bundler is package manager for ruby code libraries aka ruby gems.
mysql gem would not install unless you install the binary dependencies of the library. try
$ sudo apt-get install libmysql-ruby libmysqlclient-dev
Welcome, gather around.
My first step when trying to install the gem puma is to enter gem install puma --version 2.12.3 into my command prompt. Then this error appears. I don't know what to make of it.
C:\Users>gem install puma --version 2.12.3
Temporarily enhancing PATH to include DevKit...
Building native extensions. This could take a while...
ERROR: Error installing puma:
ERROR: Failed to build gem native extension.
C:/Ruby22-x64/bin/ruby.exe -r ./siteconf20150809-8352-14jkju1.rb extconf.rb
checking for BIO_read() in -lcrypto... no
checking for BIO_read() in -llibeay32... 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=C:/Ruby22-x64/bin/$(RUBY_BASE_NAME)
--with-puma_http11-dir
--without-puma_http11-dir
--with-puma_http11-include
--without-puma_http11-include=${puma_http11-dir}/include
--with-puma_http11-lib
--without-puma_http11-lib=${puma_http11-dir}/lib
--with-cryptolib
--without-cryptolib
--with-libeay32lib
--without-libeay32lib
extconf failed, exit code 1
Gem files will remain installed in C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/puma-2
.12.3 for inspection.
Results logged to C:/Ruby22-x64/lib/ruby/gems/2.2.0/extensions/x64-mingw32/2.2.0
/puma-2.12.3/gem_make.out
Please help, thank you!
You probably just need OpenSSL, but be warned that some gems just fail to work on Windows.
https://github.com/hicknhack-software/rails-disco/wiki/Installing-puma-on-windows
I am installing gem rmagick in Ubuntu 14.04 OS but I am getting error as,
Building native extensions. This could take a while...
ERROR: Error installing rmagick:
ERROR: Failed to build gem native extension.
/home/jignesh/.rvm/rubies/ruby-2.1.5/bin/ruby -r ./siteconf20150317-9073-18x8ncb.rb extconf.rb
checking for Ruby version >= 1.8.5... yes
checking for gcc... yes
checking for Magick-config... yes
checking for ImageMagick version >= 6.4.9... yes
checking for stdint.h... yes
checking for sys/types.h... yes
checking for wand/MagickWand.h... no
Can't install RMagick 2.13.4. Can't find MagickWand.h.
*** 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=/home/jignesh/.rvm/rubies/ruby-2.1.5/bin/ruby
extconf failed, exit code 1
I have tried so many solutions provided on Stackoverflow as well as on other sites but no one worked for me.
So please any one provide me solution.
Thanks in advance.
You should install magickwand package to fix this problem:
sudo apt-get install libmagickwand-dev
I can't install the debuggar gem.
I get this error and I have no ide why:
Building native extensions. This could take a while...
ERROR: Error installing debugger:
ERROR: Failed to build gem native extension.
/usr/local/rvm/rubies/ruby-1.9.3-p547/bin/ruby extconf.rb
checking for rb_method_entry_t.called_id in method.h... no
checking for rb_control_frame_t.method_id in method.h... no
checking for rb_method_entry_t.called_id in method.h... no
checking for rb_control_frame_t.method_id in method.h... no
Makefile creation failed
**************************************************************************
No source for ruby-1.9.3-p547 provided with debugger-ruby_core_source gem.
**************************************************************************
*** 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
--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/rvm/rubies/ruby-1.9.3-p547/bin/ruby
--with-ruby-dir
--without-ruby-dir
--with-ruby-include
--without-ruby-include=${ruby-dir}/include
--with-ruby-lib
--without-ruby-lib=${ruby-dir}/lib
extconf failed, exit code 1
Gem files will remain installed in /usr/local/rvm/gems/ruby-1.9.3-p547/gems/debugger-1.5.0 for inspection.
Results logged to /usr/local/rvm/gems/ruby-1.9.3-p547/extensions/x86_64-darwin-13/1.9.1/debugger-1.5.0/gem_make.out
I was having the same issue and this solved it for me:
gem update debugger-ruby_core_source
And then bundle install would work.
Try it:
bundle update debugger
And keep in your gemfile:
gem 'debugger'
Im new to ruby and rails. I've set up ruby 2 on rails 4 successfully (On windows 7). I cloned a ruby on rails based git project (thingspeak - https://github.com/iobridge/thingspeak/blob/master/README.textile). Using the command line I went into the project directory and ran "bundle install". A few bundles got downloaded and installed and then I got the following error -
::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension
.
c:/row/Ruby200/bin/ruby.exe extconf.rb
checking for CLOCK_MONOTONIC in time.h... yes
checking for clockid_t in time.h... yes
checking for clock_gettime() in -lrt... no
checking for t_open() in -lnsl... no
checking for socket() in -lsocket... no
checking for poll() in poll.h... no
checking for getaddrinfo() in sys/types.h,sys/socket.h,netdb.h... no
getaddrinfo required
*** 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:/row/Ruby200/bin/ruby
--with-rtlib
--without-rtlib
--with-nsllib
--without-nsllib
--with-socketlib
--without-socketlib
Gem files will remain installed in c:/row/Ruby200/lib/ruby/gems/2.0.0/gems/kgio-
2.8.1 for inspection.
Results logged to c:/row/Ruby200/lib/ruby/gems/2.0.0/gems/kgio-2.8.1/ext/kgio/ge
m_make.out
An error occurred while installing kgio (2.8.1), and Bundler cannot continue.
Make sure that `gem install kgio -v '2.8.1'` succeeds before bundling.
Any ideas on what it means and how to fix it?
The kgio gem which fails to compile here does not work on Windows. It could work if you comment the respective line in the Gemfile but could fail in various other places.
Generally, the Rails app you want to install doesn't seem to be tested on Windows at all, so you might instead want to use a better supported OS to install it. The README mentions Ubuntu here.