Project

General

Profile

Actions

Bug #18373

closed

Bundled gem (RBS, debug) extensions are not properly built

Added by vo.x (Vit Ondruch) almost 3 years ago. Updated over 2 years ago.

Status:
Closed
Target version:
-
ruby -v:
ruby 3.1.0dev (2021-12-01 master 0b53a8895f) [x86_64-linux]
[ruby-core:106355]

Description

Trying to build Ruby 3.1.0 preview1 (or the current snapshot), I observe the following issue during installation of bundled RBS:

Building native extensions. This could take a while...
/builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:95:in `run': ERROR: Failed to build gem native extension. (Gem::Ext::BuildError)

    current directory: /builddir/build/BUILDROOT/ruby-3.1.0-0.1.20211201git0b53a8895f.fc36.x86_64/usr/share/ruby/gems/gems/rbs-1.7.1/ext/rbs_extension
/builddir/build/BUILDROOT/ruby-3.1.0-0.1.20211201git0b53a8895f.fc36.x86_64/usr/bin/ruby --disable\\=gems -I/builddir/build/BUILDROOT/ruby-3.1.0-0.1.20211201git0b53a8895f.fc36.x86_64/usr/lib64/ruby -I /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib -r ./siteconf20211201-24852-213cgt.rb extconf.rb
creating Makefile

current directory: /builddir/build/BUILDROOT/ruby-3.1.0-0.1.20211201git0b53a8895f.fc36.x86_64/usr/share/ruby/gems/gems/rbs-1.7.1/ext/rbs_extension
make DESTDIR\\= clean
make[1]: Entering directory '/builddir/build/BUILDROOT/ruby-3.1.0-0.1.20211201git0b53a8895f.fc36.x86_64/usr/share/ruby/gems/gems/rbs-1.7.1/ext/rbs_extension'
rm -f 
rm -fr rbs_extension.so false *.o  *.bak mkmf.log .*.time
make[1]: Leaving directory '/builddir/build/BUILDROOT/ruby-3.1.0-0.1.20211201git0b53a8895f.fc36.x86_64/usr/share/ruby/gems/gems/rbs-1.7.1/ext/rbs_extension'

current directory: /builddir/build/BUILDROOT/ruby-3.1.0-0.1.20211201git0b53a8895f.fc36.x86_64/usr/share/ruby/gems/gems/rbs-1.7.1/ext/rbs_extension
make DESTDIR\\=
make[1]: Entering directory '/builddir/build/BUILDROOT/ruby-3.1.0-0.1.20211201git0b53a8895f.fc36.x86_64/usr/share/ruby/gems/gems/rbs-1.7.1/ext/rbs_extension'
make[1]: *** No rule to make target '/include/x86_64-linux/ruby/config.h', needed by 'constants.o'.  Stop.
make[1]: Leaving directory '/builddir/build/BUILDROOT/ruby-3.1.0-0.1.20211201git0b53a8895f.fc36.x86_64/usr/share/ruby/gems/gems/rbs-1.7.1/ext/rbs_extension'

make failed, exit code 2

Gem files will remain installed in /builddir/build/BUILDROOT/ruby-3.1.0-0.1.20211201git0b53a8895f.fc36.x86_64/usr/share/ruby/gems/gems/rbs-1.7.1 for inspection.
Results logged to /builddir/build/BUILDROOT/ruby-3.1.0-0.1.20211201git0b53a8895f.fc36.x86_64/usr/share/ruby/gems/extensions/x86_64-linux/3.1.0/rbs-1.7.1/gem_make.out
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:44:in `block in make'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:36:in `each'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:36:in `make'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/ext_conf_builder.rb:63:in `block in build'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/tempfile.rb:317:in `open'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/ext_conf_builder.rb:26:in `build'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:161:in `build_extension'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:195:in `block in build_extensions'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:192:in `each'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:192:in `build_extensions'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/installer.rb:837:in `build_extensions'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/installer.rb:318:in `install'
	from ./tool/rbinstall.rb:895:in `block in install'
	from ./tool/rbinstall.rb:719:in `no_write'
	from ./tool/rbinstall.rb:895:in `install'
	from ./tool/rbinstall.rb:1062:in `block (2 levels) in <main>'
	from ./tool/rbinstall.rb:1037:in `foreach'
	from ./tool/rbinstall.rb:1037:in `block in <main>'
	from ./tool/rbinstall.rb:1121:in `block in <main>'
	from ./tool/rbinstall.rb:1118:in `each'
	from ./tool/rbinstall.rb:1118:in `<main>'
/builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:95:in `run': make failed, exit code 2 (Gem::InstallError)
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:44:in `block in make'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:36:in `each'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:36:in `make'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/ext_conf_builder.rb:63:in `block in build'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/tempfile.rb:317:in `open'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/ext_conf_builder.rb:26:in `build'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:161:in `build_extension'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:195:in `block in build_extensions'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:192:in `each'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/ext/builder.rb:192:in `build_extensions'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/installer.rb:837:in `build_extensions'
	from /builddir/build/BUILD/ruby-3.1.0-0b53a8895f/lib/rubygems/installer.rb:318:in `install'
	from ./tool/rbinstall.rb:895:in `block in install'
	from ./tool/rbinstall.rb:719:in `no_write'
	from ./tool/rbinstall.rb:895:in `install'
	from ./tool/rbinstall.rb:1062:in `block (2 levels) in <main>'
	from ./tool/rbinstall.rb:1037:in `foreach'
	from ./tool/rbinstall.rb:1037:in `block in <main>'
	from ./tool/rbinstall.rb:1121:in `block in <main>'
	from ./tool/rbinstall.rb:1118:in `each'
	from ./tool/rbinstall.rb:1118:in `<main>'
make: *** [uncommon.mk:383: do-install-all] Error 1
error: Bad exit status from /var/tmp/rpm-tmp.cpHVoZ (%install)
    Bad exit status from /var/tmp/rpm-tmp.cpHVoZ (%install)

This is probably fault of RubyGems, but also, RBS have not contained binary extension previously, if I am not mistaken. So I am not entirely sure.

BTW there is not Ruby installed on the build system, so this should work with the Ruby being build.


Files

Makefile (9.3 KB) Makefile vo.x (Vit Ondruch), 12/07/2021 05:52 PM
Makefile (8.24 KB) Makefile vo.x (Vit Ondruch), 12/21/2021 11:13 AM
rbconfig.rb (13.8 KB) rbconfig.rb vo.x (Vit Ondruch), 12/21/2021 02:37 PM

Related issues 3 (0 open3 closed)

Related to Ruby master - Bug #7860: Passing --libdir to ./configure causes Gem.ruby to point to an incorrect ruby interpreter pathClosednobu (Nobuyoshi Nakada)Actions
Related to Ruby master - Bug #9160: configureに--with-rubylibprefixを指定するとrbconfigのprefixが空文字になるClosednobu (Nobuyoshi Nakada)11/27/2013Actions
Has duplicate Ruby master - Bug #18592: RPATH of bundled native extensions is incorrectClosedActions
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0