Failing to install ruby-debug-ide gem under ruby 2.1.2 - ruby

I am trying to install the ruby-debug-ide gem under ruby 2.1.2 . This to debug in Rubymine.
It worked for ruby1.9.3 but not for this version.
here is the error:
1.3.5/lib/debugger/ruby_core_source/ruby-2.1.2-p95/***internal.h:209: error: expected ‘;’, ‘,’ or ‘)’ before ‘x’***
Here is the output.
I would love the ability to make sence or debug this in some way . A quick fix will also be great by the way :-)
Fetching: ruby-debug-ide-0.4.22.gem (100%)
Building native extensions. This could take a while...
ERROR: Error installing ruby-debug-ide:
ERROR: Failed to build gem native extension.
/Users/ohad/.rvm/rubies/ruby-2.1.2/bin/ruby mkrf_conf.rb
Installing base gem
Building native extensions. This could take a while...
Building native extensions. This could take a while...
ERROR: Failed to build gem native extension.
/Users/ohad/.rvm/rubies/ruby-2.1.2/bin/ruby extconf.rb
checking for vm_core.h... no
checking for vm_core.h... no
checking for vm_core.h... yes
creating Makefile
make "DESTDIR=" clean
make "DESTDIR="
compiling breakpoint.c
compiling context.c
compiling debase_internals.c
In file included from /Users/ohad/.rvm/gems/ruby-2.1.2#v1_v2/gems/debugger-ruby_core_source-1.3.5/lib/debugger/ruby_core_source/ruby-2.1.2-p95/method.h:14,
from /Users/ohad/.rvm/gems/ruby-2.1.2#v1_v2/gems/debugger-ruby_core_source-1.3.5/lib/debugger/ruby_core_source/ruby-2.1.2-p95/vm_core.h:24,
from ./hacks.h:1,
from debase_internals.c:2:
/Users/ohad/.rvm/gems/ruby-2.1.2#v1_v2/gems/debugger-ruby_core_source-1.3.5/lib/debugger/ruby_core_source/ruby-2.1.2-p95/***internal.h:209: error: expected ‘;’, ‘,’ or ‘)’ before ‘x’***
make: *** [debase_internals.o] Error 1
make failed, exit code 2
Gem files will remain installed in /Users/ohad/.rvm/gems/ruby-2.1.2#v1_v2/gems/debase-0.0.9 for inspection.
Results logged to /Users/ohad/.rvm/gems/ruby-2.1.2#v1_v2/extensions/x86_64-darwin-13/2.1.0-static/debase-0.0.9/gem_make.out
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/builder.rb:89:in `run'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/builder.rb:51:in `block in make'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/builder.rb:43:in `each'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/builder.rb:43:in `make'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/ext_conf_builder.rb:47:in `block in build'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tempfile.rb:324:in `open'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/ext_conf_builder.rb:17:in `build'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/builder.rb:161:in `block (2 levels) in build_extension'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/builder.rb:160:in `chdir'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/builder.rb:160:in `block in build_extension'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/builder.rb:159:in `synchronize'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/builder.rb:159:in `build_extension'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/builder.rb:198:in `block in build_extensions'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/builder.rb:195:in `each'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/ext/builder.rb:195:in `build_extensions'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/installer.rb:677:in `build_extensions'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/installer.rb:232:in `install'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/request_set.rb:142:in `block in install'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/request_set.rb:126:in `each'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/request_set.rb:126:in `install'
/Users/ohad/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/dependency_installer.rb:389:in `install'
mkrf_conf.rb:34:in `rescue in <main>'
mkrf_conf.rb:27:in `<main>'
rake failed, exit code 1
Gem files will remain installed in /Users/ohad/.rvm/gems/ruby-2.1.2#v1_v2/gems/ruby-debug-ide-0.4.22 for inspection.
Results logged to /Users/ohad/.rvm/gems/ruby-2.1.2#v1_v2/extensions/x86_64-darwin-13/2.1.0-static/ruby-debug-ide-0.4.22/gem_make.out
Also, I failed to install with ruby rvm reinstall ruby-2.1.2 --disable-binary with this error
`dyld: Library not loaded: ##HOMEBREW_CELLAR##/openssl/1.0.1i/lib/libssl.1.0.0.dylib
Referenced from: /usr/local/opt/openssl/bin/openssl
Reason: image not found
Failed reading certificates path for '/usr/local/opt/openssl/bin/openssl' with return code: ().
RVM autolibs is now configured with mode '2' => 'check and stop if missing',
please run `rvm autolibs enable` to let RVM do its job or run and read `rvm autolibs [help]`
or visit https://rvm,, for more information.
Requirements installation failed with status: 133.`

The problem seems to be that the gem debugger-ruby_core_source can’t find the header file vm_core.h, which is part of Ruby’s source code. To install the source only (given that you have the binaries installed already) do:
$ rvm fetch ruby-2.1.2
You can also reinstall from source (a bit slower but it’s a good habit):
$ rvm reinstall ruby-2.1.2 --disable-binary
Update based on your additional error message
According to your message, you need to install OpenSSL:
$ brew install openssl
To sum up:
You can’t install debugger-ruby_core_source because it needs the
Ruby source for your Ruby version.
You can’t install the Ruby source
code with RVM because the Open SSL libraries are missing.
To remedy that type rvm autolibs homebrew so that RVM will install the missing packages if needed (you might need root permissions and enter your password when requested). This also lets RVM takes care of dependency problems from now on, you shouldn’t need to type the command again.

I had a similar issue, and installing the debugger-ruby_core_source gem manually before installing ruby-debug-ide worked.

I had this happen to me today, and solved it after running brew unlink openssl && brew link openssl --force
Hope it helps.

Related

Why does `gem install` succeed but `bundle install` fails?

I'm trying to install gtk3, but bundle install chokes while installing atk. Most of the responses seem to resolve around mismatched versions in the lock file. Removing the lock file doesn't help, neither does installing the matching version of bundle.
$ bundle install
Fetching gem metadata from https://rubygems.org/....
Resolving dependencies...
Using bundler 2.4.6
Fetching native-package-installer 1.1.5
Fetching pkg-config 1.5.1
Installing pkg-config 1.5.1
Installing native-package-installer 1.1.5
Fetching glib2 3.5.1
Installing glib2 3.5.1 with native extensions
Fetching atk 3.5.1
Installing atk 3.5.1 with native extensions
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
current directory: /home/sproctor/code/lich-5/vendor/bundle/ruby/2.7.0/gems/atk-3.5.1/dependency-check
rake RUBYARCHDIR\=/home/sproctor/code/lich-5/vendor/bundle/ruby/2.7.0/extensions/x86_64-linux/2.7.0/atk-3.5.1
RUBYLIBDIR\=/home/sproctor/code/lich-5/vendor/bundle/ruby/2.7.0/extensions/x86_64-linux/2.7.0/atk-3.5.1
/home/sproctor/.rvm/rubies/ruby-2.7.7/lib/ruby/site_ruby/2.7.0/rubygems.rb:263:in `find_spec_for_exe': can't find gem
rake (>= 0.a) with executable rake (Gem::GemNotFoundException)
from /home/sproctor/.rvm/rubies/ruby-2.7.7/lib/ruby/site_ruby/2.7.0/rubygems.rb:282:in `activate_bin_path'
from /home/sproctor/.rvm/gems/ruby-2.7.7/bin/rake:23:in `<main>'
from /home/sproctor/.rvm/gems/ruby-2.7.7/bin/ruby_executable_hooks:22:in `eval'
from /home/sproctor/.rvm/gems/ruby-2.7.7/bin/ruby_executable_hooks:22:in `<main>'
rake failed, exit code 1
Gem files will remain installed in /home/sproctor/code/lich-5/vendor/bundle/ruby/2.7.0/gems/atk-3.5.1 for inspection.
Results logged to
/home/sproctor/code/lich-5/vendor/bundle/ruby/2.7.0/extensions/x86_64-linux/2.7.0/atk-3.5.1/gem_make.out
/home/sproctor/.rvm/rubies/ruby-2.7.7/lib/ruby/site_ruby/2.7.0/rubygems/ext/builder.rb:102:in `run'
/home/sproctor/.rvm/rubies/ruby-2.7.7/lib/ruby/site_ruby/2.7.0/rubygems/ext/rake_builder.rb:28:in `build'
/home/sproctor/.rvm/rubies/ruby-2.7.7/lib/ruby/site_ruby/2.7.0/rubygems/ext/builder.rb:170:in `build_extension'
/home/sproctor/.rvm/rubies/ruby-2.7.7/lib/ruby/site_ruby/2.7.0/rubygems/ext/builder.rb:204:in `block in
build_extensions'
/home/sproctor/.rvm/rubies/ruby-2.7.7/lib/ruby/site_ruby/2.7.0/rubygems/ext/builder.rb:201:in `each'
/home/sproctor/.rvm/rubies/ruby-2.7.7/lib/ruby/site_ruby/2.7.0/rubygems/ext/builder.rb:201:in `build_extensions'
/home/sproctor/.rvm/rubies/ruby-2.7.7/lib/ruby/site_ruby/2.7.0/rubygems/installer.rb:843:in `build_extensions'
/home/sproctor/.rvm/gems/ruby-2.7.7/gems/bundler-2.4.6/lib/bundler/rubygems_gem_installer.rb:72:in `build_extensions'
/home/sproctor/.rvm/gems/ruby-2.7.7/gems/bundler-2.4.6/lib/bundler/rubygems_gem_installer.rb:28:in `install'
/home/sproctor/.rvm/gems/ruby-2.7.7/gems/bundler-2.4.6/lib/bundler/source/rubygems.rb:200:in `install'
/home/sproctor/.rvm/gems/ruby-2.7.7/gems/bundler-2.4.6/lib/bundler/installer/gem_installer.rb:54:in `install'
/home/sproctor/.rvm/gems/ruby-2.7.7/gems/bundler-2.4.6/lib/bundler/installer/gem_installer.rb:16:in
`install_from_spec'
/home/sproctor/.rvm/gems/ruby-2.7.7/gems/bundler-2.4.6/lib/bundler/installer/parallel_installer.rb:155:in
`do_install'
/home/sproctor/.rvm/gems/ruby-2.7.7/gems/bundler-2.4.6/lib/bundler/installer/parallel_installer.rb:146:in `block in
worker_pool'
/home/sproctor/.rvm/gems/ruby-2.7.7/gems/bundler-2.4.6/lib/bundler/worker.rb:62:in `apply_func'
/home/sproctor/.rvm/gems/ruby-2.7.7/gems/bundler-2.4.6/lib/bundler/worker.rb:57:in `block in process_queue'
/home/sproctor/.rvm/gems/ruby-2.7.7/gems/bundler-2.4.6/lib/bundler/worker.rb:54:in `loop'
/home/sproctor/.rvm/gems/ruby-2.7.7/gems/bundler-2.4.6/lib/bundler/worker.rb:54:in `process_queue'
/home/sproctor/.rvm/gems/ruby-2.7.7/gems/bundler-2.4.6/lib/bundler/worker.rb:90:in `block (2 levels) in
create_threads'
An error occurred while installing atk (3.5.1), and Bundler cannot continue.
In Gemfile:
atk
However, installing via gem works fine.
gem install atk -v 3.5.1
Building native extensions. This could take a while...
Successfully installed atk-3.5.1
Parsing documentation for atk-3.5.1
Done installing documentation for atk after 0 seconds
1 gem installed
This isn't a great answer, so if someone has a more in depth explanation, please feel free to give a better answer.
gem install gtk3 and bundle install use a different copy of rake.
The only difference between the two is the shebang line. The version from bundler is #!/usr/bin/env ruby_executable_hooks while the other version points to a specific version of ruby.
I'm not sure why this fails for the bundler version.
An easy workaround mentioned here: https://github.com/postmodern/digest-crc/issues/18#issuecomment-652889761 is to add gem "rake" to your Gemfile.

Installing ruby-debug-ide - Failed to build gem native extension

I have win7x64 and struggling to install ruby-debug-ide to use debugger in my ide. It is failing to build gem native extensions
have tried everything i could find through net
--verbose, --pre, --with ruby etc
Its still failing (
Can anyone give some tip please? thanks
$ ruby -v
ruby 2.3.1p112 (2016-04-26 revision 54768) [x64-mingw32]
$ gem install ruby-debug-ide
Building native extensions. This could take a while...
System cannot find path specified
ERROR: Error installing ruby-debug-ide:
ERROR: Failed to build gem native extension.
current directory: C:/Ruby231-x64/lib/ruby/gems/2.3.0/gems/ruby-debug-ide-0.6.0/ext
C:/Ruby231-x64/bin/ruby.exe mkrf_conf.rb
'Ёбв?┐? -? г¤ ?вбп - cвЁ гЄ § --лc Їгвм.
'Ёбв?┐? -? г¤ ?вбп - cвЁ гЄ § --лc Їгвм.
Installing base gem
Building native extensions. This could take a while...
Building native extensions. This could take a while...
ERROR: Failed to build gem native extension.
current directory: C:/Ruby231-x64/lib/ruby/gems/2.3.0/gems/debase-0.2.2.beta9/ext
C:/Ruby231-x64/bin/ruby.exe -r ./siteconf20170120-10104-1f4a8us.rb extconf.rb
checking for vm_core.h... no
checking for vm_core.h... no
checking for vm_core.h... yes
creating Makefile
To see why this extension failed to compile, please check the mkmf.log which can be found here:
C:/Ruby231-x64/lib/ruby/gems/2.3.0/extensions/x64-mingw32/2.3.0/debase-0.2.2.beta9/mkmf.log
extconf failed, exit code 1
Gem files will remain installed in C:/Ruby231-x64/lib/ruby/gems/2.3.0/gems/debase-0.2.2.beta9 for inspection.
Results logged to C:/Ruby231-x64/lib/ruby/gems/2.3.0/extensions/x64-mingw32/2.3.0/debase-0.2.2.beta9/gem_make.out
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:92:in `run'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/ext/ext_conf_builder.rb:48:in `block in build'
C:/Ruby231-x64/lib/ruby/2.3.0/tempfile.rb:295:in `open'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/ext/ext_conf_builder.rb:31:in `build'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:164:in `block (2 levels) in build_extension'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:163:in `chdir'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:163:in `block in build_extension'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:162:in `synchronize'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:162:in `build_extension'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:201:in `block in build_extensions'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:198:in `each'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:198:in `build_extensions'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/installer.rb:752:in `build_extensions'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/installer.rb:304:in `install'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/resolver/specification.rb:97:in `install'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/request_set.rb:166:in `block in install'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/request_set.rb:156:in `each'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/request_set.rb:156:in `install'
C:/Ruby231-x64/lib/ruby/site_ruby/2.3.0/rubygems/dependency_installer.rb:405:in `install'
mkrf_conf.rb:35:in `rescue in <main>'
mkrf_conf.rb:28:in `<main>'
rake failed, exit code 1
Gem files will remain installed in C:/Ruby231-x64/lib/ruby/gems/2.3.0/gems/ruby-debug-ide-0.6.0 for inspection.
Results logged to C:/Ruby231-x64/lib/ruby/gems/2.3.0/extensions/x64-mingw32/2.3.0/ruby-debug-ide-0.6.0/gem_make.out
$ gem install debase-ruby_core_source
Successfully installed debase-ruby_core_source-0.9.6
$ gem install debase -- --with-ruby-include=C:\Ruby231-x64\lib\ruby\gems\2.3.0\gems\debase-ruby_core_source-0.9.6\lib\debase\ruby_core_source\ruby-2.3.1-p112
Building native extensions with: '--with-ruby-include=C:\Ruby231-x64\lib\ruby\gems\2.3.0\gems\debase-ruby_core_source-0.9.6\lib\debase\ruby_core_source\ruby-2.3.1-p112ruby -v'
This could take a while...
System cannot find path specified
ERROR: Error installing debase:
ERROR: Failed to build gem native extension.
$ gem install debase --pre
Building native extensions. This could take a while...
System cannot find path specified
ERROR: Error installing debase:
ERROR: Failed to build gem native extension.
$ gem install ruby-debug-ide --pre
Building native extensions. This could take a while...
Системе не удается найти указанный путь.
ERROR: Error installing ruby-debug-ide:
ERROR: Failed to build gem native extension.
current directory: C:/Ruby231-x64_unit/lib/ruby/gems/2.3.0/gems/ruby-debug-ide-0.6.1.beta4/ext
C:/Ruby231-x64_unit/bin/ruby.exe mkrf_conf.rb
'Ёбв?┐? -? г¤ ?вбп - cвЁ гЄ § --лc Їгвм.
'Ёбв?┐? -? г¤ ?вбп - cвЁ гЄ § --лc Їгвм.
Installing base gem
Building native extensions. This could take a while...
Building native extensions. This could take a while...
ERROR: Failed to build gem native extension.
current directory: C:/Ruby231-x64_unit/lib/ruby/gems/2.3.0/gems/debase-0.2.2.beta9/ext
C:/Ruby231-x64_unit/bin/ruby.exe -r ./siteconf20170201-7760-7dws4t.rb extconf.rb
checking for vm_core.h... no
checking for vm_core.h... no
checking for vm_core.h... yes
creating Makefile
To see why this extension failed to compile, please check the mkmf.log which can be found here:
C:/Ruby231-x64_unit/lib/ruby/gems/2.3.0/extensions/x64-mingw32/2.3.0/debase-0.2.2.beta9/mkmf.log
extconf failed, exit code 1
Gem files will remain installed in C:/Ruby231-x64_unit/lib/ruby/gems/2.3.0/gems/debase-0.2.2.beta9 for inspection.
Results logged to C:/Ruby231-x64_unit/lib/ruby/gems/2.3.0/extensions/x64-mingw32/2.3.0/debase-0.2.2.beta9/gem_make.out
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:91:in `run'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/ext/ext_conf_builder.rb:36:in `block in build'
C:/Ruby231-x64_unit/lib/ruby/2.3.0/tempfile.rb:295:in `open'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/ext/ext_conf_builder.rb:19:in `build'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:163:in `block (2 levels) in build_extension'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:162:in `chdir'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:162:in `block in build_extension'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:161:in `synchronize'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:161:in `build_extension'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:200:in `block in build_extensions'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:197:in `each'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/ext/builder.rb:197:in `build_extensions'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/installer.rb:741:in `build_extensions'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/installer.rb:290:in `install'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/request_set.rb:166:in `block in install'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/request_set.rb:150:in `each'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/request_set.rb:150:in `install'
C:/Ruby231-x64_unit/lib/ruby/site_ruby/2.3.0/rubygems/dependency_installer.rb:404:in `install'
mkrf_conf.rb:35:in `rescue in <main>'
mkrf_conf.rb:28:in `<main>'
rake failed, exit code 1
Gem files will remain installed in C:/Ruby231-x64_unit/lib/ruby/gems/2.3.0/gems/ruby-debug-ide-0.6.1.beta4 for inspection.
Results logged to C:/Ruby231-x64_unit/lib/ruby/gems/2.3.0/extensions/x64-mingw32/2.3.0/ruby-debug-ide-0.6.1.beta4/gem_make.out

Install Compass on OS X Yosemite

I'm trying to install compass using GEM but i have a lot of error.
My macbook pro is running OS X Yosemite.
Anyone have the same problem ?
Thank you for your time.
Have a nice day
sudo gem install compass
Password:
ERROR: Error installing compass:
ERROR: Failed to build gem native extension.
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby -r ./siteconf20141019-17085-1dv9dek.rb extconf.rb
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/universal-darwin14/rbconfig.rb:213: warning: Insecure world writable dir /Library/Ruby/Gems/2.0.0/gems/ffi-1.9.5/ext/ffi_c in PATH, mode 040777
checking for ffi.h... /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:434:in `try_do': The compiler failed to generate an executable file. (RuntimeError)
You have to install development tools first.
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:549:in `block in try_compile'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:502:in `with_werror'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:549:in `try_compile'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:1044:in `block in have_header'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:895:in `block in checking_for'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:340:in `block (2 levels) in postpone'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:310:in `open'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:340:in `block in postpone'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:310:in `open'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:336:in `postpone'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:894:in `checking_for'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:1043:in `have_header'
from extconf.rb:16:in `<main>'
extconf failed, exit code 1
Gem files will remain installed in /Library/Ruby/Gems/2.0.0/gems/ffi-1.9.5 for inspection.
Results logged to /Library/Ruby/Gems/2.0.0/extensions/universal-darwin-14/2.0.0/ffi-1.9.5/gem_make.out
Actually, this seems to be successfully answered at Installing 'Compass' via the command line receive error "extconf failed, exit code 1"
You evidently need to first install development tools (xcode-select --install), then install compass
good luck!
well you should not be installing gems globally for one thing. I would highly recommend installng rbenv and then the version of ruby you would like to have, before you install compass and other gems. Then you can install gems at a user level and don't have to worry about setting write permissions on directories outside of the users. - which appears to be the problem in this case.
Just follow the instructions here for rbenv https://github.com/sstephenson/rbenv and then install the ruby build plugin https://github.com/sstephenson/ruby-build
Just run sudo chmod go-w /usr/local/ from terminal as administrator.
This worked for me

Problems installing zeromq MacOSX

I tried to install zeromq using brew on MacOSX 10.9.5. This is the output I got:
==> Downloading http://download.zeromq.org/zeromq-3.2.3.tar.gz
######################################################################## 100.0%
==> Patching
patching file tests/test_disconnect_inproc.cpp
==> ./configure --prefix=/usr/local/Cellar/zeromq/3.2.3
==> make
==> make install
==> Caveats
To install the zmq gem on 10.6 with the system Ruby on a 64-bit machine,
you may need to do:
ARCHFLAGS="-arch x86_64" gem install zmq -- --with-zmq-dir=/usr/local/opt/zeromq
==> Summary
/usr/local/Cellar/zeromq/3.2.3: 54 files, 2.3M, built in 24 seconds
And after trying to execute the command it tells me to run (ARCHFLAGS="-arch x86_64" gem install zmq -- --with-zmq-dir=/usr/local/opt/zeromq), it tells me that it couldn't install zmq:
Fetching: zmq-2.1.4.gem (100%)
Building native extensions with: '--with-zmq-dir=/usr/local/opt/zeromq'
This could take a while...
ERROR: Error installing zmq:
ERROR: Failed to build gem native extension.
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby extconf.rb --with-zmq-dir=/usr/local/opt/zeromq
checking for zmq.h... /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:434:in `try_do': The compiler failed to generate an executable file. (RuntimeError)
You have to install development tools first.
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:549:in `block in try_compile'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:502:in `with_werror'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:549:in `try_compile'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:1044:in `block in have_header'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:895:in `block in checking_for'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:340:in `block (2 levels) in postpone'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:310:in `open'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:340:in `block in postpone'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:310:in `open'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:336:in `postpone'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:894:in `checking_for'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:1043:in `have_header'
from extconf.rb:23:in `header?'
from extconf.rb:32:in `<main>'
Gem files will remain installed in /Library/Ruby/Gems/2.0.0/gems/zmq-2.1.4 for inspection.
Results logged to /Library/Ruby/Gems/2.0.0/gems/zmq-2.1.4/./gem_make.out
Does someone know what problem that is and how to resolve it?
I had a similar problem on Yosemite. I've installed zmg using port:
sudo port install zmg
followed by:
npm install zmq
and:
brew uninstall zmq

Compass gemfile syntax error on Ubuntu 12.10, Ruby 1.9.3

Having run the standard procedure for installing the rvm, which also installs Ruby 1.9.3, then installing gems for rake, compass, sass, bundler and guard, then adding my gems/bin directory to my path I get the following message on running compass:
/home/m1ke/.rvm/gems/ruby-1.9.3-p362/gems/bundler-1.2.3/lib/bundler/dsl.rb:35:in `rescue in eval_gemfile': Gemfile syntax error: (Bundler::GemfileError)
gem "guard", "~> 1.0.1"
^
from /home/m1ke/.rvm/gems/ruby-1.9.3-p362/gems/bundler-1.2.3/lib/bundler/dsl.rb:32:in `eval_gemfile'
from /home/m1ke/.rvm/gems/ruby-1.9.3-p362/gems/bundler-1.2.3/lib/bundler/dsl.rb:7:in from /home/m1ke/.rvm/gems/ruby-1.9.3-p362/gems/bundler-1.2.3/lib/bundler/definition.rb:18:in `build'
from /home/m1ke/.rvm/gems/ruby-1.9.3-p362/gems/bundler-1.2.3/lib/bundler.rb:144:in `definition'
from /home/m1ke/.rvm/gems/ruby-1.9.3-p362/gems/bundler-1.2.3/lib/bundler.rb:112:in `setup'
from /home/m1ke/.rvm/gems/ruby-1.9.3-p362/gems/bundler-1.2.3/lib/bundler.rb:128:in `require'
from /home/m1ke/.rvm/gems/ruby-1.9.3-p362/gems/compass-0.12.2/bin/compass:26:in `<top (required)>'
from /home/m1ke/.rvm/gems/ruby-1.9.3-p362/bin/compass:19:in `load'
from /home/m1ke/.rvm/gems/ruby-1.9.3-p362/bin/compass:19:in `<main>
from /home/m1ke/.rvm/gems/ruby-1.9.3-p362/bin/ruby_noexec_wrapper:14:in `eval'
from /home/m1ke/.rvm/gems/ruby-1.9.3-p362/bin/ruby_noexec_wrapper:14:in `<main>'
All gems were installed with the standard gem install compass syntax, I have also run gem update --system
More information!
The same gem works fine on my Windows install, installed using the Windows RubyInstaller.
Having had no responses I tried removing the gem and installing the ruby-compass package from apt-get. This works fine, but now another gem (not available on apt-get) reports errors the come from both /home/m1ke/.rvm/gems/ruby-1.9.9-p362/ but also from /usr/share/ruby-1.9.1/ which I assume the Compass apt-get installed. So now I may have two Ruby versions fighting...
Found the answer on another thread
Just run rubygems-bundler-uninstaller and the problem was fixed right away. Posting this here instead of just linking as the thread linked didn't come up when I searched my error, as my error was a syntax error whereas the linked post has a "file not found" error.

Resources