I´m trying to install the p4ruby gem on our RHEL 7.9 server and I keep getting the "failed to build gem native extension" error.
Here is what the log contains this message:
have_library: checking for -lsupc++... -------------------- no
I have installed the Development Tools with
yum group install "Development tools"
And I´m using RVM with Ruby Version 2.7.1.
What am I missing?
Edit:
Thanks to Knud Larsens hint
yum install gcc-c++ libstdc++-static
fixed the previous issue.
But the building still doesn´t work
`rbuf_fill': Net::ReadTimeout with #<Socket:fd 9> (Net::ReadTimeout)
is what I get now.
I tried install the postgresSQL adapter for the Python:
$ pipenv install psycopg2
And I got this error:
Installing dependencies from Pipfile.lock (45527d)…
An error occurred while installing psycopg2==2.8.2...
The error stack is soo long, here the last lines:
(...)bin/../include/site/python3.7/psycopg2" failed with error code 1 in /private/var/folders/wq/wp6z48kj7_z3ynpkchsmqjp80000gn/T/pip-install-8ffakjrp/psycopg2/']
Any tip about?
Use this:
pipenv clean
pipenv install psycopg2-binary
I had solved installing just the binaries an others libs. Here is:
$ brew install libxml2 libxmlsec1 pkg-config
$ pipenv install psycopg2-binary
I tried a bunch of stuff but I think this worked better.
$ xcode-select --install
$ export LDFLAGS="-L/usr/local/opt/openssl/lib"
$ export CPPFLAGS="-I/usr/local/opt/openssl/include"
I want to install Gitlab on my new Raspberry Pi 2 (with Raspbian).
https://gitlab.com/gitlab-org/gitlab-ce/blob/6-5-stable/doc/install/installation.md
Under "2) Ruby" it says:
Install the Bundler Gem:
sudo gem install bundler --no-ri --no-rdoc
When I try to run this, it just says:
ERROR: Loading command: install (LoadError)
cannot load such file -- openssl
ERROR: While executing gem ... (NoMethodError)
undefined method `invoke_with_build_args' for nil:NilClass
Is there any chance, somebody knows what went wrong here - and how to fix it? Thank you very much!
I am trying to install GITLAB. I get this error executing "sudo gem install charlock_holmes --version '0.6.9'" (section Install Gems)
GEOGIT:/geogit/Administrative_Tools # sudo gem install charlock_holmes --version '0.6.9'
Building native extensions. This could take a while...
ERROR: Error installing charlock_holmes:
ERROR: Failed to build gem native extension.
/usr/bin/ruby1.9 extconf.rb
checking for main() in -licui18n... no
which: no brew in (/usr/sbin:/bin:/usr/bin:/sbin)
checking for main() in -licui18n... no
***************************************************************************************
*********** icu required (brew install icu4c or apt-get install libicu-dev) ***********
***************************************************************************************
*** 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}/
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/usr/bin/ruby1.9
--with-icu-dir
--without-icu-dir
--with-icu-include
--without-icu-include=${icu-dir}/include
--with-icu-lib
--without-icu-lib=${icu-dir}/
--with-icui18nlib
--without-icui18nlib
--with-icui18nlib
--without-icui18nlib
Gem files will remain installed in /usr/lib64/ruby/gems/1.9.1/gems/charlock_holmes-0.6.9 for inspection.
Results logged to /usr/lib64/ruby/gems/1.9.1/gems/charlock_holmes-0.6.9/ext/charlock_holmes/gem_make.out
Someone, can help me debug those logs and error?
This looks like issue 1952
It was actually weirdness with the way my ubuntu VPS is commissioned. Mine did not come with a C compiler or libdev obviously.
The problem fix I found was to install libdev first, then the GCC
Then apt-get install libicu-dev.
Update 2015: additional comments include:
yum install libicu-devel worked for me
You just need to make sure "patch" is installed (yum install patch) then it should work
For MacOS install the following dependency:
brew install icu4c
According to the documentation (https://github.com/gitlabhq/gitlabhq/blob/master/doc/install/installation.md) the package libicu-dev is required
Install it with "apt-get install libicu-dev" and then charlock_holmes could be installed
I used "yum install libicu-devel" and then I could install charlock_holmes
I got the same mistake on a Centos 5.4 server, the yum repository only have the icu version 3.6, so i have to search and install manually the library icu 4.2 which solve the problem. In case someone else need to know how to do it, i recommend to check this link http://source.icu-project.org/repos/icu/icu/tags/release-4-2-1/readme.html#HowToBuildUNIX
I had kind of the same problem: when I was trying to install charlock_holmes gem, I had this error:
charlock_holmes-0.7.3/mkmf.log
have_library: checking for main() in -licui18n... -------------------- no
I fixed it by running the first command of #VonC:
sudo apt-get install libicu-dev
Hope I helped someone!
The console output pretty much speaks for itself:
$ java -jar jruby-complete-1.6.4.jar -S gem install nokogiri --no-rdoc --no-ri
Fetching: nokogiri-1.5.0-java.gem (100%)
Successfully installed nokogiri-1.5.0-java
1 gem installed
11:17:04|dkowis#racktop jruby
$ java -jar jruby-complete-1.6.4.jar -S gem install cucumber --no-rdoc --no-ri
ERROR: While executing gem ... (ArgumentError)
undefined class/module YAML::Syck::DefaultKey
11:18:24|dkowis#racktop jruby
$ java -jar jruby-complete-1.6.4.jar -S gem install cuke4duke --version=0.4.4 --no-rdoc --no-ri
ERROR: While executing gem ... (ArgumentError)
undefined class/module YAML::Syck::DefaultKey
There's a couple gems I can install, but the ones I need, I cannot. Is it a problem with the gem itself? Is it a problem with rubygems? I'm not able to puzzle this one out.
This apparently is a known issue with Rubygems reported here on the JRuby Forum.
There is a pull request to fix this Rubygems error, but you could try build the gems you want locally and correct the dependency statements in the gemspec file yourself. I had ran into the same problem with the i18n-js gem.
Hope this helps.