I'm trying to reinstall rugged as it's causing issues with another program (Dandelion Deploy).
I've recently updated my RVM and Ruby, and installed cmake and pkg-config again, but I get this error when I run the following command: gem install rugged
Fetching: rugged-0.22.2.gem (100%)
Building native extensions. This could take a while...
ERROR: Error installing rugged:
ERROR: Failed to build gem native extension.
/Users/J/.rvm/rubies/ruby-2.0.0-p645/bin/ruby -r ./siteconf20150605-56781-qfplzm.rb extconf.rb
checking for gmake... no
checking for make... yes
checking for cmake... yes
checking for pkg-config... yes
-- cmake .. -DBUILD_CLAR=OFF -DTHREADSAFE=ON -DBUILD_SHARED_LIBS=OFF -DCMAKE_C_FLAGS=-fPIC -DCMAKE_BUILD_TYPE=RelWithDebInfo -G "Unix Makefiles"
*** 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=/Users/J/.rvm/rubies/ruby-2.0.0-p645/bin/ruby
--use-system-libraries
extconf.rb:13:in `sys': ERROR: 'cmake .. -DBUILD_CLAR=OFF -DTHREADSAFE=ON -DBUILD_SHARED_LIBS=OFF -DCMAKE_C_FLAGS=-fPIC -DCMAKE_BUILD_TYPE=RelWithDebInfo -G "Unix Makefiles"' failed (RuntimeError)
from extconf.rb:66:in `block (2 levels) in <main>'
from extconf.rb:65:in `chdir'
from extconf.rb:65:in `block in <main>'
from extconf.rb:62:in `chdir'
from extconf.rb:62:in `<main>'
extconf failed, exit code 1
Gem files will remain installed in /Users/J/.rvm/rubies/ruby-2.0.0-p645/lib/ruby/gems/2.0.0/gems/rugged-0.22.2 for inspection.
Results logged to /Users/J/.rvm/rubies/ruby-2.0.0-p645/lib/ruby/gems/2.0.0/extensions/x86_64-darwin-11/2.0.0/rugged-0.22.2/gem_make.out
I'm a frontender, so this is way out of my comfort zone. Any help appreciated!
Mac OSX 10.7.5, Lion
Solved it.
I installed the latest version of XCode I could (4.6.3) on OSX 10.7.5.
To get dandelion working, I installed the following gems: rugged, dandelion and net-sftp
and everything worked again.
Related
I try to install the gem charlock_holmes_bundle_icu -v '0.6.9.2'
but I receive this error:
Building native extensions. This could take a while...
ERROR: Error installing charlock_holmes_bundle_icu:
ERROR: Failed to build gem native extension.
current directory: /Users/agatheloubert/.rbenv/versions/2.4.1/lib/ruby/gems/2.4.0/gems/charlock_holmes_bundle_icu-0.6.9.2/ext/charlock_holmes
/Users/agatheloubert/.rbenv/versions/2.4.1/bin/ruby -r ./siteconf20180306-35008-vbolm2.rb extconf.rb
-- tar zxvf icu4c-49_1_2-src.tgz
-- LDFLAGS= CXXFLAGS="-O2 -fPIC" CFLAGS="-O2 -fPIC" ./configure --prefix=/Users/agatheloubert/.rbenv/versions/2.4.1/lib/ruby/gems/2.4.0/gems/charlock_holmes_bundle_icu-0.6.9.2/ext/charlock_holmes/dst/ --disable-tests --disable-samples --disable-icuio --disable-extras --disable-layout --enable-static --disable-shared
-- make install
*** 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/agatheloubert/.rbenv/versions/2.4.1/bin/$(RUBY_BASE_NAME)
extconf.rb:7:in `sys': make install failed, please report issue on http://github.com/brianmario/charlock_holmes (RuntimeError)
from extconf.rb:33:in `block (2 levels) in <main>'
from extconf.rb:31:in `chdir'
from extconf.rb:31:in `block in <main>'
from extconf.rb:27:in `chdir'
from extconf.rb:27:in `<main>'
extconf failed, exit code 1
Gem files will remain installed in /Users/agatheloubert/.rbenv/versions/2.4.1/lib/ruby/gems/2.4.0/gems/charlock_holmes_bundle_icu-0.6.9.2 for inspection.
Results logged to /Users/agatheloubert/.rbenv/versions/2.4.1/lib/ruby/gems/2.4.0/extensions/x86_64-darwin-17/2.4.0-static/charlock_holmes_bundle_icu-0.6.9.2/gem_make.out
Do you know how to do it?
Uninstalling and reinstalling solved the issue for me.
gem uninstall charlock_holmes
gem install charlock_holmes -- --with-icu-dir=/usr/local/Custom/icu
You can use sudo for su permissions.
I have installed Ruby and in my project file i have rmagick gem.
gem "rmagick", "2.13.2", require: "RMagick"
Ruby Version
gem "rmagick", "2.13.2", require: "RMagick"
I am getting an error while installing rmagick.
g native extensions. This could take a while...
ERROR: Error installing rmagick:
ERROR: Failed to build gem native extension.
/home/suganya/.rvm/rubies/ruby-2.2.5/bin/ruby -r ./siteconf20160916-13775-z6z2nl.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 HDRI disabled version of ImageMagick... yes
checking for stdint.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/suganya/.rvm/rubies/ruby-2.2.5/bin/$(RUBY_BASE_NAME)
/home/suganya/.rvm/rubies/ruby-2.2.5/lib/ruby/2.2.0/mkmf.rb:456:in `try_do': The compiler failed to generate an executable file. (RuntimeError)
You have to install development tools first.
from /home/suganya/.rvm/rubies/ruby- 2.2.5/lib/ruby/2.2.0/mkmf.rb:587:in `try_cpp'
from /home/suganya/.rvm/rubies/ruby-2.2.5/lib/ruby/2.2.0/mkmf.rb:1060:in `block in have_header'
from /home/suganya/.rvm/rubies/ruby-2.2.5/lib/ruby/2.2.0/mkmf.rb:911:in `block in checking_for'
from /home/suganya/.rvm/rubies/ruby-2.2.5/lib/ruby/2.2.0/mkmf.rb:351:in `block (2 levels) in postpone'
from /home/suganya/.rvm/rubies/ruby-2.2.5/lib/ruby/2.2.0/mkmf.rb:321:in `open'
from /home/suganya/.rvm/rubies/ruby-2.2.5/lib/ruby/2.2.0/mkmf.rb:351:in `block in postpone'
from /home/suganya/.rvm/rubies/ruby-2.2.5/lib/ruby/2.2.0/mkmf.rb:321:in `open'
from /home/suganya/.rvm/rubies/ruby-2.2.5/lib/ruby/2.2.0/mkmf.rb:347:in `postpone'
from /home/suganya/.rvm/rubies/ruby-2.2.5/lib/ruby/2.2.0/mkmf.rb:910:in `checking_for'
from /home/suganya/.rvm/rubies/ruby-2.2.5/lib/ruby/2.2.0/mkmf.rb:1059:in `have_header'
from extconf.rb:194:in `<main>'
extconf failed, exit code 1
Gem files will remain installed in /home/suganya/.rvm/gems/ruby-2.2.5/gems/rmagick-2.13.2 for inspection.
Results logged to /home/suganya/.rvm/gems/ruby-2.2.5/extensions/x86_64-linux/2.2.0/rmagick-2.13.2/gem_make.out.
i have been working on this for past two days and I tried a lot of work arounds.
sudo apt-get install libmagickwand-dev imagemagick
But if I run just
gem install rmagick
It runs perfect installs rmagick-2.16.0
You need to run the following commands for ubuntu
sudo apt-get install libmagick++-dev
sudo apt-get install imagemagick
Then try to install
gem install rmagick
I have working mariadb 10.1 server.
I install ruby 2.3.0 on ubuntu 16.04.
I install libmariadbd-dev and libmariadbclient-dev.
When I try "gem install mysql2", then a recive message:
Building native extensions with: '--with-mysql-dir=/usr/local/mysql'
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.4/ext/mysql2
/usr/bin/ruby2.3 -r ./siteconf20160615-5183-kj9yds.rb extconf.rb --with-mysql-dir=/usr/local/mysql
checking for ruby/thread.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=/usr/bin/$(RUBY_BASE_NAME)2.3
/usr/lib/ruby/2.3.0/mkmf.rb:456:in `try_do': The compiler failed to generate an executable file. (RuntimeError)
You have to install development tools first.
from /usr/lib/ruby/2.3.0/mkmf.rb:587:in `try_cpp'
from /usr/lib/ruby/2.3.0/mkmf.rb:1091:in `block in have_header'
from /usr/lib/ruby/2.3.0/mkmf.rb:942:in `block in checking_for'
from /usr/lib/ruby/2.3.0/mkmf.rb:350:in `block (2 levels) in postpone'
from /usr/lib/ruby/2.3.0/mkmf.rb:320:in `open'
from /usr/lib/ruby/2.3.0/mkmf.rb:350:in `block in postpone'
from /usr/lib/ruby/2.3.0/mkmf.rb:320:in `open'
from /usr/lib/ruby/2.3.0/mkmf.rb:346:in `postpone'
from /usr/lib/ruby/2.3.0/mkmf.rb:941:in `checking_for'
from /usr/lib/ruby/2.3.0/mkmf.rb:1090:in `have_header'
from extconf.rb:16:in `<main>'
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.4/mkmf.log
extconf failed, exit code 1
Gem files will remain installed in /var/lib/gems/2.3.0/gems/mysql2-0.4.4 for inspection.
Results logged to /var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/mysql2-0.4.4/gem_make.out
And I can`t find how to build this gem.
Gem in this situation need 3 packets.
sudo apt-get install libnetcdf-dev libssl-dev libcrypto++-dev
This is for mac but you need to change the path:
gem uninstall mysql2
intall mariadb 10.1 andnecesaary ssl packages or maybe this are not needed
then check the path to the libraries and the tinal folders have the same name:
bundle config --local build.mysql2 "--with-mysql-config=/usr/local/Cellar/mariadb#10.1/10.1.29/bin/mysql_config --with-ldflags=-L/usr/local/opt/openssl/lib --with-cppflags=-I/usr/local/opt/openssl/include"
or without the ssl path
bundle config --local build.mysql2 "--with-mysql-config=/usr/local/Cellar/mariadb#10.1/10.1.29/bin/mysql_config
or directly the gem, but if you come ffrom mysql is better to do it with bundle
gem install mysql2 -v 'x.y.z' -- --with-mysql-config=/usr/local/Cellar/mariadb#10.1/10.1.29/bin/mysql_config
and finally
bundle install
I'd like to install RMagic gem, I got “Can't find Magick-config” so I installed
$ sudo apt-get install libmagickwand-dev
but now I get following output:
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
/usr/local/rvm/rubies/ruby-2.1.5/bin/ruby -r
./siteconf20150526-12203-xr9xf7.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... *
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/rvm/rubies/ruby-2.1.5/bin/ruby extconf.rb:154:in ``': No such file or directory - convert
(Errno::ENOENT)
from extconf.rb:154:in block in <main>'
from /usr/local/rvm/rubies/ruby-2.1.5/lib/ruby/2.1.0/mkmf.rb:918:inblock
in checking_for'
from /usr/local/rvm/rubies/ruby-2.1.5/lib/ruby/2.1.0/mkmf.rb:351:in block
(2 levels) in postpone'
from /usr/local/rvm/rubies/ruby-2.1.5/lib/ruby/2.1.0/mkmf.rb:321:inopen'
from /usr/local/rvm/rubies/ruby-2.1.5/lib/ruby/2.1.0/mkmf.rb:351:in block
in postpone'
from /usr/local/rvm/rubies/ruby-2.1.5/lib/ruby/2.1.0/mkmf.rb:321:inopen'
from /usr/local/rvm/rubies/ruby-2.1.5/lib/ruby/2.1.0/mkmf.rb:347:in
postpone'
from /usr/local/rvm/rubies/ruby-2.1.5/lib/ruby/2.1.0/mkmf.rb:917:in
checking_for'
from extconf.rb:151:in `'
extconf failed, exit code 1
Gem files will remain installed in
/usr/local/rvm/gems/ruby-2.1.5#rails4/gems/rmagick-2.13.4 for
inspection. Results logged to
/usr/local/rvm/gems/ruby-2.1.5#rails4/extensions/x86_64-linux/2.1.0/rmagick-2.13.4/gem_make.out
Could someone help me solve it?
Look at where it fails (which was hard to work out because your newlines got swallowed somewhere):
checking for ImageMagick version >= 6.4.9... * extconf.rb failed *
This check didn't get a "yes", which suggests that the libmagickwand-dev package you installed did not provide a version of ImageMagic >= 6.4.9 which is apparently the version that the rmagick gem version 2.13.4 requires.
Either get a newer ImageMagick or an older rmagick gem.
Make sure you install ImageMagick. Usually, not having the right dependencies is the culprit.
http://www.imagemagick.org/script/install-source.php
After trying the above solutions and still not working .. i tried this one
sudo apt-get install graphicsmagick-libmagick-dev-compat
did the trick for me
I am trying to install an RoR app from Github and while running bundle install, I get this error:
Installing rmagick (2.13.1) with native extensions
Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
/Users/adam/.rvm/rubies/ruby-1.9.3-p327/bin/ruby extconf.rb
checking for Ruby version >= 1.8.5... yes
extconf.rb:128: Use RbConfig instead of obsolete and deprecated Config.
checking for clang... yes
checking for Magick-config... yes
checking for ImageMagick version >= 6.4.9... yes
checking for HDRI disabled version of ImageMagick... yes
checking for stdint.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
--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/adam/.rvm/rubies/ruby-1.9.3-p327/bin/ruby
/Users/adam/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/mkmf.rb:381:in `try_do': The compiler failed to generate an executable file. (RuntimeError)
You have to install development tools first.
from /Users/adam/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/mkmf.rb:506:in `try_cpp'
from /Users/adam/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/mkmf.rb:931:in `block in have_header'
from /Users/adam/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/mkmf.rb:790:in `block in checking_for'
from /Users/adam/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/mkmf.rb:284:in `block (2 levels) in postpone'
from /Users/adam/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/mkmf.rb:254:in `open'
from /Users/adam/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/mkmf.rb:284:in `block in postpone'
from /Users/adam/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/mkmf.rb:254:in `open'
from /Users/adam/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/mkmf.rb:280:in `postpone'
from /Users/adam/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/mkmf.rb:789:in `checking_for'
from /Users/adam/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/mkmf.rb:930:in `have_header'
from extconf.rb:193:in `<main>'
Gem files will remain installed in /Users/adam/.rvm/gems/ruby-1.9.3-p327/gems/rmagick-2.13.1 for inspection.
Results logged to /Users/adam/.rvm/gems/ruby-1.9.3-p327/gems/rmagick-2.13.1/ext/RMagick/gem_make.out
An error occurred while installing rmagick (2.13.1), and Bundler cannot continue.
Make sure that `gem install rmagick -v '2.13.1'` succeeds before bundling.
I've tried to run gem install rmagick -v '2.13.1', but I got the same error.
I am running on Mac OS X Lion. What am I missing?
Thank you in advance.
Try to run:
brew link imagemagick
Make sure you have a compiler. XCODE command line tools, or just install gcc.
I could not install the rmagick gem either...
To get Imagemagick installed correctly I first
brew remove libtool
brew install libtool --universal
Then I was able to install Imagemagick using this command:
brew install imagemagick --build-from-source
Then the rmagick gem installed correctly
The error message I was getting when rmagick would not install looked like:
linking shared-object RMagick2.bundle
ld: file not found: /usr/local/lib/libltdl.7.dylib for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [RMagick2.bundle] Error 1
make failed, exit code 2
This was for Imagemagick 6.8.9-8 and rmagick 2.13.2