Repository navigation
Open
Description
I try to install debase and ruby-debug-ide-0.7.2
part my Gemfile
gem 'debase', '0.2.5.beta2',
gem 'ruby-debug-ide', '~> 0.7.2'
part my Dockerfile
FROM ruby:3.0.2-buster
RUN apt update
RUN apt install -y \
git \
libxml2-dev \
libxslt-dev \
&& gem install bundler
but getting the following error
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
current directory:
/home/circleci/src/.bundler/ruby/3.0.0/gems/ruby-debug-ide-0.7.2/ext
/usr/local/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.
current directory:
/home/circleci/src/.bundler/ruby/3.0.0/gems/debase-0.2.5.beta2/ext
/usr/local/bin/ruby -I /usr/local/lib/ruby/3.0.0 -r
./siteconf20210907-778-tnuf1c.rb extconf.rb
*** 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/bin/$(RUBY_BASE_NAME)
<internal:/usr/local/lib/ruby/3.0.0/rubygems/core_ext/kernel_require.rb>:85:in
`require': cannot load such file -- debase/ruby_core_source (LoadError)
from
<internal:/usr/local/lib/ruby/3.0.0/rubygems/core_ext/kernel_require.rb>:85:in
`require'
from extconf.rb:28:in `<main>'
extconf failed, exit code 1
Gem files will remain installed in
/home/circleci/src/.bundler/ruby/3.0.0/gems/debase-0.2.5.beta2 for inspection.
Results logged to
/home/circleci/src/.bundler/ruby/3.0.0/extensions/x86_64-linux/3.0.0/debase-0.2.5.beta2/gem_make.out
/usr/local/lib/ruby/3.0.0/rubygems/ext/builder.rb:91:in `run'
/usr/local/lib/ruby/3.0.0/rubygems/ext/ext_conf_builder.rb:48:in `block in
build'
/usr/local/lib/ruby/3.0.0/tempfile.rb:317:in `open'
/usr/local/lib/ruby/3.0.0/rubygems/ext/ext_conf_builder.rb:28:in `build'
/usr/local/lib/ruby/3.0.0/rubygems/ext/builder.rb:157:in `build_extension'
/usr/local/lib/ruby/3.0.0/rubygems/ext/builder.rb:191:in `block in
build_extensions'
/usr/local/lib/ruby/3.0.0/rubygems/ext/builder.rb:188:in `each'
/usr/local/lib/ruby/3.0.0/rubygems/ext/builder.rb:188:in `build_extensions'
/usr/local/lib/ruby/3.0.0/rubygems/installer.rb:828:in `build_extensions'
/usr/local/lib/ruby/3.0.0/rubygems/installer.rb:312:in `install'
/usr/local/lib/ruby/3.0.0/rubygems/resolver/specification.rb:104:in `install'
/usr/local/lib/ruby/3.0.0/rubygems/request_set.rb:279:in `block in
install_into'
/usr/local/lib/ruby/3.0.0/rubygems/request_set.rb:271:in `each'
/usr/local/lib/ruby/3.0.0/rubygems/request_set.rb:271:in `install_into'
/usr/local/lib/ruby/3.0.0/rubygems/request_set.rb:147:in `install'
/usr/local/lib/ruby/3.0.0/rubygems/dependency_installer.rb:252:in `install'
mkrf_conf.rb:31:in `rescue in <main>'
mkrf_conf.rb:24:in `<main>'
rake failed, exit code 1
Gem files will remain installed in
/home/circleci/src/.bundler/ruby/3.0.0/gems/ruby-debug-ide-0.7.2 for inspection.
Results logged to
/home/circleci/src/.bundler/ruby/3.0.0/extensions/x86_64-linux/3.0.0/ruby-debug-ide-0.7.2/gem_make.out
An error occurred while installing ruby-debug-ide (0.7.2), and Bundler
cannot continue.
Make sure that `gem install ruby-debug-ide -v '0.7.2' --source
'https://rubygems.org/'` succeeds before bundling.
In Gemfile:
ruby-debug-ide
Exited with code exit status 5
debase-0.2.5.beta2/gem_make.out
~$ cat /home/circleci/src/.bundler/ruby/3.0.0/extensions/x86_64-linux/3.0.0/debase-0.2.5.beta2/gem_make.out
current directory: /home/circleci/src/.bundler/ruby/3.0.0/gems/debase-0.2.5.beta2/ext/attach
/usr/local/bin/ruby -I /usr/local/lib/ruby/3.0.0 -r ./siteconf20210907-112-m10uv7.rb extconf.rb
checking for vm_core.h... no
checking for vm_core.h... no
**************************************************************************
No source for ruby-3.0.2-p107 (revision 0db68f023372b634603c74fca94588b457be084c) provided with
debase-ruby_core_source gem. Falling back to ruby-3.0.0-p0.
**************************************************************************
checking for vm_core.h... yes
checking for iseq.h... yes
checking for version.h... yes
creating Makefile
current directory: /home/circleci/src/.bundler/ruby/3.0.0/gems/debase-0.2.5.beta2/ext/attach
make DESTDIR\= clean
current directory: /home/circleci/src/.bundler/ruby/3.0.0/gems/debase-0.2.5.beta2/ext/attach
make DESTDIR\=
compiling attach.c
linking shared-object attach.so
current directory: /home/circleci/src/.bundler/ruby/3.0.0/gems/debase-0.2.5.beta2/ext/attach
make DESTDIR\= install
/usr/bin/install -c -m 0755 attach.so ./.gem.20210907-112-oi5vck
**ruby-debug-ide-0.7.2/gem_make.out **
~$ cat /home/circleci/src/.bundler/ruby/3.0.0/extensions/x86_64-linux/3.0.0/ruby-debug-ide-0.7.2/gem_make.out
current directory: /home/circleci/src/.bundler/ruby/3.0.0/gems/ruby-debug-ide-0.7.2/ext
/usr/local/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.
current directory: /home/circleci/src/.bundler/ruby/3.0.0/gems/debase-0.2.5.beta2/ext
/usr/local/bin/ruby -I /usr/local/lib/ruby/3.0.0 -r ./siteconf20210907-786-cy6qm5.rb extconf.rb
*** 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/bin/$(RUBY_BASE_NAME)
<internal:/usr/local/lib/ruby/3.0.0/rubygems/core_ext/kernel_require.rb>:85:in `require': cannot load such file -- debase/ruby_core_source (LoadError)
from <internal:/usr/local/lib/ruby/3.0.0/rubygems/core_ext/kernel_require.rb>:85:in `require'
from extconf.rb:28:in `<main>'
extconf failed, exit code 1
Gem files will remain installed in /home/circleci/src/.bundler/ruby/3.0.0/gems/debase-0.2.5.beta2 for inspection.
Results logged to /home/circleci/src/.bundler/ruby/3.0.0/extensions/x86_64-linux/3.0.0/debase-0.2.5.beta2/gem_make.out
/usr/local/lib/ruby/3.0.0/rubygems/ext/builder.rb:91:in `run'
/usr/local/lib/ruby/3.0.0/rubygems/ext/ext_conf_builder.rb:48:in `block in build'
/usr/local/lib/ruby/3.0.0/tempfile.rb:317:in `open'
/usr/local/lib/ruby/3.0.0/rubygems/ext/ext_conf_builder.rb:28:in `build'
/usr/local/lib/ruby/3.0.0/rubygems/ext/builder.rb:157:in `build_extension'
/usr/local/lib/ruby/3.0.0/rubygems/ext/builder.rb:191:in `block in build_extensions'
/usr/local/lib/ruby/3.0.0/rubygems/ext/builder.rb:188:in `each'
/usr/local/lib/ruby/3.0.0/rubygems/ext/builder.rb:188:in `build_extensions'
/usr/local/lib/ruby/3.0.0/rubygems/installer.rb:828:in `build_extensions'
/usr/local/lib/ruby/3.0.0/rubygems/installer.rb:312:in `install'
/usr/local/lib/ruby/3.0.0/rubygems/resolver/specification.rb:104:in `install'
/usr/local/lib/ruby/3.0.0/rubygems/request_set.rb:279:in `block in install_into'
/usr/local/lib/ruby/3.0.0/rubygems/request_set.rb:271:in `each'
/usr/local/lib/ruby/3.0.0/rubygems/request_set.rb:271:in `install_into'
/usr/local/lib/ruby/3.0.0/rubygems/request_set.rb:147:in `install'
/usr/local/lib/ruby/3.0.0/rubygems/dependency_installer.rb:252:in `install'
mkrf_conf.rb:31:in `rescue in <main>'
mkrf_conf.rb:24:in `<main>'
rake failed, exit code 1
Reacted by Collin Sauve, Patrick Grenning, hangedman, Kamil Gwóźdź, eg, Rafael Gomes, Bradley Carrion and Sebastian Bonilla
Reacted by Mikael Henriksson, Joel Cogen, Carl Mercier, Anton Topchii and Salim Chekili
Metadata
Metadata
Assignees
Labels
No labels
Activity
jabamaus commentedon Sep 12, 2021
I would like this too :) Hoping it might help stabilise the debugging experience in ruby vscode....
jabamaus commentedon Sep 13, 2021
I got as far as adding 3.0.2p107 to debase-ruby_core_source and submitting a pull request... Hoping an expert can do the débase part.
iandol commentedon Nov 24, 2021
@jabamaus — You could use the new official debug gem https://github.com/ruby/debug and debug extension for VSCode: https://marketplace.visualstudio.com/items?itemName=KoichiSasada.vscode-rdbg — works reliably in 3.0.2 for me...
AlecRust commentedon Nov 25, 2021
@iandol does that remove the need for https://github.com/ruby-debug/ruby-debug-ide too?
iandol commentedon Nov 25, 2021
@AlecRust Yes, it is a single ruby gem and one extension. The extension is very new, so there may be teething troubles. But at least for my requirements of remote debugger triggered within-the-code, this is already much more useful.
ruby/debugwill be officially bundled in 3.1 and Rails 7 (replacingbyebug), so it also makes sense to move over as it will better support new ruby versions...Remove debase and ruby-debug-ide gems
iefhong commentedon Dec 13, 2021
try install beta version
gem install debase --precollinsauve commentedon Jan 15, 2022
This does not seem to be just a Ruby 3.x problem. See https://github.com/collinsauve/ruby-debug-ide-test/branches
These base images build:
These base images get the native extension error
Is this a missing C library or something, that should be documented in the readme?
collinsauve commentedon Jan 15, 2022
Here's the output from the ruby-2.7.1-slim-buster branch:
AirWick219 commentedon Mar 3, 2022
Got the same error with ruby 3.0.0 but was able to install
debase-0.2.5.beta2after installingdebase-ruby_core_sourcegot the idea from here
zhouluyao2020 commentedon Mar 4, 2022
upgrade ruby,it's work for me!
ruby -vruby 2.6.3p62 (2019-04-16 revision 67580) [universal.x86_64-darwin19]
brew install ruby➜ ~ brew install ruby
==> Downloading https://mirrors.ustc.edu.cn/homebrew-bottles/libyaml-0.2.5.big_s
######################################################################## 100.0%
==> Downloading https://mirrors.ustc.edu.cn/homebrew-bottles/ruby-3.0.1.big_sur.
#=#=#
curl: (22) The requested URL returned error: 404
Warning: Bottle missing, falling back to the default domain...
==> Downloading https://ghcr.io/v2/homebrew/core/ruby/manifests/3.0.1
######################################################################## 100.0%
==> Downloading https://ghcr.io/v2/homebrew/core/ruby/blobs/sha256:00daa93e4b30d
==> Downloading from https://pkg-containers.githubusercontent.com/ghcr1/blobs/sh
######################################################################## 100.0%
==> Installing dependencies for ruby: libyaml
==> Installing ruby dependency: libyaml
==> Pouring libyaml-0.2.5.big_sur.bottle.tar.gz
🍺 /usr/local/Cellar/libyaml/0.2.5: 10 files, 348.4KB
==> Installing ruby
==> Pouring ruby--3.0.1.big_sur.bottle.tar.gz
==> Caveats
By default, binaries installed by gem will be placed into:
/usr/local/lib/ruby/gems/3.0.0/bin
You may want to add this to your PATH.
ruby is keg-only, which means it was not symlinked into /usr/local,
because macOS already provides this software and installing another version in
parallel can cause all kinds of trouble.
If you need to have ruby first in your PATH, run:
echo 'export PATH="/usr/local/opt/ruby/bin:$PATH"' >> ~/.zshrc
For compilers to find ruby you may need to set:
export LDFLAGS="-L/usr/local/opt/ruby/lib"
export CPPFLAGS="-I/usr/local/opt/ruby/include"
For pkg-config to find ruby you may need to set:
export PKG_CONFIG_PATH="/usr/local/opt/ruby/lib/pkgconfig"
==> Summary
🍺 /usr/local/Cellar/ruby/3.0.1: 16,358 files, 38.4MB
==> Caveats
==> ruby
By default, binaries installed by gem will be placed into:
/usr/local/lib/ruby/gems/3.0.0/bin
You may want to add this to your PATH.
ruby is keg-only, which means it was not symlinked into /usr/local,
because macOS already provides this software and installing another version in
parallel can cause all kinds of trouble.
If you need to have ruby first in your PATH, run:
echo 'export PATH="/usr/local/opt/ruby/bin:$PATH"' >> ~/.zshrc
For compilers to find ruby you may need to set:
export LDFLAGS="-L/usr/local/opt/ruby/lib"
export CPPFLAGS="-I/usr/local/opt/ruby/include"
For pkg-config to find ruby you may need to set:
export PKG_CONFIG_PATH="/usr/local/opt/ruby/lib/pkgconfig"
echo 'export PATH="/usr/local/opt/ruby/bin:$PATH"' >> ~/.zshrcsource ~/.zshrcsudo gem install debase -v '0.2.5.beta2'Password:
Fetching debase-0.2.5.beta2.gem
Fetching debase-ruby_core_source-0.10.14.gem
Successfully installed debase-ruby_core_source-0.10.14
Building native extensions. This could take a while...
Successfully installed debase-0.2.5.beta2
Parsing documentation for debase-ruby_core_source-0.10.14
Installing ri documentation for debase-ruby_core_source-0.10.14
Parsing documentation for debase-0.2.5.beta2
Installing ri documentation for debase-0.2.5.beta2
Done installing documentation for debase-ruby_core_source, debase after 6 seconds
2 gems installed
rgalanakis commentedon Mar 6, 2022
I am using
rbenv, I was able to copy~/.rbenv/versions/3.1.1/lib/ruby/gems/3.1.0/gems/debase-ruby_core_source-0.10.14/lib/debaseinto~/.rbenv/versions/3.1.1/lib/ruby/3.1.0/debase, next to the Ruby stdlib files/folders, so the build step could fine the needed files. Not the worst hack I've had to do.kristian-nst commentedon Jul 19, 2025
None of these work for me with Ruby 3.3.6 :/
gem install debase-ruby_core_source ✅
gem install debase or gem install debase -v '0.2.5.beta2' ❌
finally this worked:
gem install debase-ruby_core_source --source 'https://rubygems.org'
Successfully installed debase-ruby_core_source-3.4.1
1 gem installed
gem install debase --source 'https://rubygems.org'
Successfully installed debase-0.2.9
1 gem installed