本文是小编为大家收集整理的关于没有提供ruby-2.0.0-p451的源代码和debugger-ruby_core_source gem。的处理/解决方法,可以参考本文帮助大家快速定位并解决问题,中文翻译不准确的可切换到English标签页查看源文。
问题描述
我在其他问题中看到了非常相似的问题(例如没有ruby-1.9.2-p321的来源,并通过debugger-ruby_core_source gem )以及通过Google搜索,但是这些都没有帮助过远.
我正在使用OSX Mavericks(首次MAC用户)和RBENV(也是第一次使用).我已经克隆了一个铁轨项目,我以前曾在另一台笔记本电脑(Ubuntu&rvm)上运行.
rbenv version:2.0.0-p451(我手动安装)
当我尝试bundle install时,我会得到以下内容:
... Using debugger-ruby_core_source (1.3.1) Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension. /Users/macuser/.rbenv/versions/2.0.0-p451/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-2.0.0-p451 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 --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/macuser/.rbenv/versions/2.0.0-p451/bin/ruby --with-ruby-dir --without-ruby-dir --with-ruby-include=${ruby-dir}/include --with-ruby-lib --without-ruby-lib=${ruby-dir}/ Gem files will remain installed in /Users/macuser/.rbenv/versions/2.0.0-p451/lib/ruby/gems/2.0.0/gems/debugger-1.6.5 for inspection. Results logged to /Users/macuser/.rbenv/versions/2.0.0-p451/lib/ruby/gems/2.0.0/gems/debugger-1.6.5/ext/ruby_debug/gem_make.out An error occurred while installing debugger (1.6.5), and Bundler cannot continue. Make sure that `gem install debugger -v '1.6.5'` succeeds before bundling.
所以我尝试运行gem install debugger -v '1.6.5',这基本上与上述错误.
通过搜索,这是我尝试过的一些事情:
也许还有其他一些...但是似乎没有用.
更新:将我的RBENV本地环境切换到Ruby 2.1.0,并且起作用.没有解决潜在的问题,但这很好,我猜
推荐答案
尝试安装debugger而无需指定版本,然后再次运行bundle install.
我遇到了同样的错误,而且它只是奏效的,不要问我为什么:
$ gem install debugger $ bundle install
其他推荐答案
我在尝试使用Ruby 2.0.0-p598的Dubugger时遇到了同一问题.
宝石 debugger-ruby_core_core_source >并为Ruby的特定版本提供标头文件,这些版本似乎在安装 debugger 时使用.查看debugger-ruby_core_source/lib/debugger/ruby_core_source/以查看支持哪些版本的支持 - 所有Ruby版本都不提供标题文件.就我而言,没有为2.0.0-P598版本提供它们.
查看 debugger-ruby_core_source 的dememe,有一个用于添加Ruby版本所需文件的Rake任务.
从宝石目录中的命令行中,我运行
$ rake add_source VERSION=2.0.0-p598
第一次执行此任务时,我收到了一个错误,并被要求安装 -Minitar GEM在再次运行耙任务之前.
耙子任务添加了我的版本的标头文件后,我能够成功安装和运行调试器.
其他推荐答案
我在这里发布,因为绝对没有任何效果.为我解决问题的唯一解决方案:
即使我们正在安装调试器,错误在于安装要求,debugger-ruby_core_source.
如果您查看正是提出问题的错误.
No source for ruby-2.0.0-p451 provided with debugger-ruby_core_source gem.
实际上很容易解决此错误.只需运行以下命令,安装依赖项并重试:
gem install debugger-ruby_core_source
将此解决方案的信用归功于:修复了GEM安装debugger -v'1.6.2'没有Ruby <的来源
问题描述
I've seen very similar problems in other SO questions (e.g. No source for ruby-1.9.2-p321 provided with debugger-ruby_core_source gem) as well as through a Google search, but none of those have helped so far.
I'm using OSX Mavericks (first time mac user) and rbenv (first time using that too). I've git cloned a Rails project which I've previously ran on another laptop (Ubuntu & rvm) fine.
rbenv version: 2.0.0-p451 (which I manually installed)
When I try to bundle install, I get the following:
... Using debugger-ruby_core_source (1.3.1) Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension. /Users/macuser/.rbenv/versions/2.0.0-p451/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-2.0.0-p451 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 --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/macuser/.rbenv/versions/2.0.0-p451/bin/ruby --with-ruby-dir --without-ruby-dir --with-ruby-include=${ruby-dir}/include --with-ruby-lib --without-ruby-lib=${ruby-dir}/ Gem files will remain installed in /Users/macuser/.rbenv/versions/2.0.0-p451/lib/ruby/gems/2.0.0/gems/debugger-1.6.5 for inspection. Results logged to /Users/macuser/.rbenv/versions/2.0.0-p451/lib/ruby/gems/2.0.0/gems/debugger-1.6.5/ext/ruby_debug/gem_make.out An error occurred while installing debugger (1.6.5), and Bundler cannot continue. Make sure that `gem install debugger -v '1.6.5'` succeeds before bundling.
So I then tried running gem install debugger -v '1.6.5', which throws basically the same error as above.
From searching around, here's some things I've unsuccessfully tried:
and probably some others too... but nothing seems to work.
Update: Switched my rbenv local environment to ruby 2.1.0 and it worked. Didn't fix the underlying problem, but this is fine I guess
推荐答案
Try install debugger without specifying a version and then run bundle install again.
I had the same error, and it just worked, don't ask me why:
$ gem install debugger $ bundle install
其他推荐答案
I ran into what I believe was the same problem while trying to install dubugger with ruby 2.0.0-p598.
The gem debugger-ruby_core_source is a dependency of debugger and provides header files for specific versions of ruby that seem to be used while installing debugger. Look in debugger-ruby_core_source/lib/debugger/ruby_core_source/ to see which versions are supported—the header files are not provided for all ruby versions. In my case, they were not provided for version 2.0.0-p598.
Looking at the README for debugger-ruby_core_source, there is a rake task for adding the required files for ruby versions.
From the command line within the gem's directory, I ran
$ rake add_source VERSION=2.0.0-p598
When I ran this task the first time, I received an error and was required to install the archive-tar-minitar gem before running the rake task again.
After the rake task added the header files for my version, I was able to successfully install and run debugger.
其他推荐答案
I am posting here because absolutely nothing worked. The only solution that fixed the problem for me:
Even though we are installing debugger, the error is in installing a requirement, debugger-ruby_core_source.
If you look at the error that is exactly where it raises the issue.
No source for ruby-2.0.0-p451 provided with debugger-ruby_core_source gem.
It is actually quite easy to fix this error. Just run the below command, installing the dependencies, and retry:
gem install debugger-ruby_core_source
Credit for this solution to: FIXED gem install debugger -v ’1.6.2′ No source for ruby