ruby-debug / ruby-debug-ide

An interface which glues ruby-debug to IDEs like Eclipse (RDT), NetBeans and RubyMine.
https://www.jetbrains.com/ruby/features/ruby_debugger.html
Other
371 stars 83 forks source link

Problems with debase Windows 7 (Offline install) #97

Open rubtk opened 7 years ago

rubtk commented 7 years ago

Hello! I am newbie to ruby and wanna to teach ruby at my Windows Workstation. I having problems with installing Ruby-debug-ide, coz of debase gem too. I have downloaded and installed MSYS2 and last GCC (using pacman) packages and successfully installed gems debase and debase-ruby_core_source. But when i tried to install ruby-debug-ide i have no luck:

D:\Files\Distrib\Programming\ruby\gem>gem install ruby-debug-ide-0.6.1.beta4.gem

Temporarily enhancing PATH for MSYS/MINGW...
Building native extensions.  This could take a while...
ERROR:  Error installing ruby-debug-ide-0.6.1.beta4.gem:
        ERROR: Failed to build gem native extension.

    current directory: C:/Ruby24-x64/lib/ruby/gems/2.4.0/gems/ruby-debug-ide-0.6
.1.beta4/ext
C:/Ruby24-x64/bin/ruby.exe mkrf_conf.rb
Installing base gem
Unable to resolve dependency: user requested 'debase (> 0)'
C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver.rb:231:in `search_for'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver.rb:263:in `block in sort_depend
encies'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver.rb:257:in `each'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver.rb:257:in `sort_by'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver.rb:257:in `sort_dependencies'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver/molinillo/lib/molinillo/delegat
es/specification_provider.rb:52:in `block in sort_dependencies'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver/molinillo/lib/molinillo/delegat
es/specification_provider.rb:69:in `with_no_such_dependency_error_handling'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver/molinillo/lib/molinillo/delegat
es/specification_provider.rb:51:in `sort_dependencies'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver/molinillo/lib/molinillo/resolut
ion.rb:165:in `initial_state'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver/molinillo/lib/molinillo/resolut
ion.rb:106:in `start_resolution'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver/molinillo/lib/molinillo/resolut
ion.rb:64:in `resolve'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver/molinillo/lib/molinillo/resolve
r.rb:42:in `resolve'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/resolver.rb:188:in `resolve'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/request_set.rb:368:in `resolve'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/dependency_installer.rb:484:in `resolve_
dependencies'
  C:/Ruby24-x64/lib/ruby/2.4.0/rubygems/dependency_installer.rb:384: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:/Ruby24-x64/lib/ruby/gems/2.4.0/gems/ruby-d
ebug-ide-0.6.1.beta4 for inspection.
Results logged to C:/Ruby24-x64/lib/ruby/gems/2.4.0/extensions/x64-mingw32/2.4.0
/ruby-debug-ide-0.6.1.beta4/gem_make.out

D:\Files\Distrib\Programming\ruby\gem>
D:\Files\Distrib\Programming\ruby\gem>gem list

*** LOCAL GEMS ***

bigdecimal (default: 1.3.0)
debase (0.2.2.beta10)
debase-ruby_core_source (0.9.9)
did_you_mean (1.1.0)
io-console (default: 0.4.6)
json (default: 2.0.2)
minitest (5.10.1)
net-telnet (0.1.1)
openssl (default: 2.0.3)
power_assert (0.4.1)
psych (default: 2.2.2)
rake (12.0.0)
rdoc (default: 5.0.0)
test-unit (3.2.3)
xmlrpc (0.2.1)

As you can see, i have debase and debase-ruby_core_source installed. I can not update my gems from remote repository, coz i am working offline. I am working with msys2 and ruby 64 bit.

rubtk commented 6 years ago

I have solved this problem patching rdebug-ide gem. This is not a solution, but at least now i can work.

lindhor commented 5 years ago

Same problem for me. Online is ok, but when running offline get the same error.

ViugiNick commented 5 years ago

@rubtk How did you change ruby-debug-ide?

lindhor commented 5 years ago

My way around it was to pip install debase then clone the git repo https://github.com/ruby-debug/ruby-debug-ide then edit the Gemfile to comment out parts making it look like this

source "http://rubygems.org"

# @param [Array<String>] versions compatible ruby versions
# @return [Array<String>] an array with mri platforms of given versions
def mries(*versions)
  versions.flat_map do |v|
    %w(ruby mingw x64_mingw)
        .map { |platform| "#{platform}_#{v}".to_sym unless platform == "x64_mingw" && v < "2.0" }
        .delete_if &:nil?
  end
end

#gem "ruby-debug-base", :platforms => [:jruby, *mries('18')]
#gem "ruby-debug-base19x", ">= 0.11.32", :platforms => mries('19')
if RUBY_VERSION && RUBY_VERSION >= "2.0"
  gem "debase", "~> 0.2.2" #, :platforms => mries('20', '21', '22', '23', '24', '25')
end

gemspec

group :development do
  gem "bundler"
end

group :test do
  gem "test-unit"
end

Then run rake installI'm using Ruby 3.7 on Windows 10.

ViugiNick commented 5 years ago

@lindhor ruby 3.7?