Project

General

Profile

Bug #17255

Installation failed for ruby version 2.7.1: unknown encoding name: binary (ArgumentError)

Added by shiftag (shiftag shiftag) about 2 months ago. Updated about 1 month ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Target version:
-
[ruby-core:100344]

Description

Hi,

I am trying to install version 2.7.1 of ruby. For now, ruby is not installed in my system (I removed it) and I used ruby-build to install it.

# ruby-build 2.7.1 /usr/local
[...]

Attached log file.

By looking at the offending file I found this:

$ head -n1 /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/.ext/common/openssl/buffering.rb                                                                                                                                                                            
# coding: binary

And this explain the following error:

generating x86_64-linux-fake.rb
x86_64-linux-fake.rb updated
./miniruby -I./lib -I. -I.ext/common  ./tool/runruby.rb --extout=.ext  -- --disable-gems -r./x86_64-linux-fake ./tool/rbinstall.rb --make="make" --dest-dir="" --extout=".ext" --mflags="" --make-flags="" --data-mode=0644 --prog-mode=0755 --installed-list .installed.list --mantype="doc" --rdoc-output=".ext/rdoc" --html-output=".ext/html"
/tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/.ext/common/openssl/buffering.rb:1: unknown encoding name: binary (ArgumentError)
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/core_ext/kernel_require.rb:72:in `require'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/core_ext/kernel_require.rb:72:in `require'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/.ext/common/openssl/ssl.rb:13:in `<top (required)>'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/core_ext/kernel_require.rb:72:in `require'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/core_ext/kernel_require.rb:72:in `require'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/.ext/common/openssl.rb:21:in `<top (required)>'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/core_ext/kernel_require.rb:72:in `require'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/core_ext/kernel_require.rb:72:in `require'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/security.rb:12:in `<top (required)>'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/core_ext/kernel_require.rb:72:in `require'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/core_ext/kernel_require.rb:72:in `require'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/package.rb:44:in `<top (required)>'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/core_ext/kernel_require.rb:72:in `require'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/core_ext/kernel_require.rb:72:in `require'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/installer.rb:11:in `<top (required)>'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/core_ext/kernel_require.rb:72:in `require'
    from /tmp/ruby-build.20201008122828.17646.H63fWD/ruby-2.7.1/lib/rubygems/core_ext/kernel_require.rb:72:in `require'
    from ./tool/rbinstall.rb:713:in `<module:RbInstall>'
    from ./tool/rbinstall.rb:649:in `<main>'
uncommon.mk:373: recipe for target 'do-install-all' failed
make: *** [do-install-all] Error 1

How can this be fixed ?

Thanks.


Files

ruby-build.20201008122828.17646.log (185 KB) ruby-build.20201008122828.17646.log ruby-build log file shiftag (shiftag shiftag), 10/08/2020 10:26 AM

Updated by jeremyevans0 (Jeremy Evans) about 2 months ago

Does this error also occur when building Ruby 2.7.2 in your environment?

#2

Updated by jeremyevans0 (Jeremy Evans) about 1 month ago

  • Status changed from Open to Closed

Also available in: Atom PDF