Ruby-build: Interrupted system call when installing on MacOS Big Sur

Created on 26 Feb 2021  Â·  3Comments  Â·  Source: rbenv/ruby-build

I get this output and error when I attempt to build ruby:

simon@Simons-MBP ~ % time rbenv install 3.0.0
Downloading openssl-1.1.1i.tar.gz...
-> https://dqw8nmjcqpjn7.cloudfront.net/e8be6a35fe41d10603c3cc635e93289ed00bf34b79671a3a4de64fcee00d5242
Installing openssl-1.1.1i...
Installed openssl-1.1.1i to /Users/simon/.rbenv/versions/3.0.0

Downloading ruby-3.0.0.tar.gz...
-> https://cache.ruby-lang.org/pub/ruby/3.0/ruby-3.0.0.tar.gz
Installing ruby-3.0.0...
ruby-build: using readline from homebrew

BUILD FAILED (macOS 11.2.1 using ruby-build 20210119)

Inspect or clean up the working tree at /var/folders/7x/tj7wsjgj4nl1g3h6sbjdrf8m0000gn/T/ruby-build.20210226164233.16496.FWB6V6
Results logged to /var/folders/7x/tj7wsjgj4nl1g3h6sbjdrf8m0000gn/T/ruby-build.20210226164233.16496.log

The last lines of the build log are as follows:

compiling inspector.c
-e:4:in `write': Interrupted system call @ rb_sysopen - failure.failed (Errno::EINTR)
        from -e:4:in `<main>'
make[2]: *** [failure.failed] Error 1
make[1]: *** [ext/-test-/cxxanyargs/all] Error 2
make[1]: *** Waiting for unfinished jobs....
compiling profile_frames.c
compiling empty.c
linking shared-object -test-/dln/empty.bundle
linking shared-object -test-/debug.bundle
make: *** [build-ext] Error 2

Not sure why I would be getting an Interrupted system call?

Most helpful comment

Big Sur 11.2.1 rbenv install 3.0.0. also failed.

➜ ~ CFLAGS="-Wno-error=implicit-function-declaration" rbenv install 3.0.0
Downloading openssl-1.1.1i.tar.gz...
-> https://dqw8nmjcqpjn7.cloudfront.net/e8be6a35fe41d10603c3cc635e93289ed00bf34b79671a3a4de64fcee00d5242
Installing openssl-1.1.1i...
Installed openssl-1.1.1i to /Users/wangxiaofeng/.rbenv/versions/3.0.0

Downloading ruby-3.0.0.tar.gz...
-> https://cache.ruby-lang.org/pub/ruby/3.0/ruby-3.0.0.tar.gz
Installing ruby-3.0.0...
ruby-build: using readline from homebrew

BUILD FAILED (macOS 11.2.1 using ruby-build 20210119)

Inspect or clean up the working tree at /var/folders/hc/slkwwjpn5db488pdxb1k1hb80000gn/T/ruby-build.20210227234808.1292.czEIX7
Results logged to /var/folders/hc/slkwwjpn5db488pdxb1k1hb80000gn/T/ruby-build.20210227234808.1292.log

Last 10 log lines:
Check ext/readline/mkmf.log for more details.
* Fix the problems, then remove these directories and try again if you want.
Generating RDoc documentation
/private/var/folders/hc/slkwwjpn5db488pdxb1k1hb80000gn/T/ruby-build.20210227234808.1292.czEIX7/ruby-3.0.0/lib/time.rb:3:in require': cannot load such file -- date (LoadError) from /private/var/folders/hc/slkwwjpn5db488pdxb1k1hb80000gn/T/ruby-build.20210227234808.1292.czEIX7/ruby-3.0.0/lib/time.rb:3:in from /private/var/folders/hc/slkwwjpn5db488pdxb1k1hb80000gn/T/ruby-build.20210227234808.1292.czEIX7/ruby-3.0.0/lib/rdoc/rdoc.rb:7:in require' from /private/var/folders/hc/slkwwjpn5db488pdxb1k1hb80000gn/T/ruby-build.20210227234808.1292.czEIX7/ruby-3.0.0/lib/rdoc/rdoc.rb:7:in from ./libexec/rdoc:16:in require' from ./libexec/rdoc:16:in

'
make: *
[rdoc] Error 1
➜ ~

All 3 comments

Big Sur 11.2.1 rbenv install 3.0.0. also failed.

➜ ~ CFLAGS="-Wno-error=implicit-function-declaration" rbenv install 3.0.0
Downloading openssl-1.1.1i.tar.gz...
-> https://dqw8nmjcqpjn7.cloudfront.net/e8be6a35fe41d10603c3cc635e93289ed00bf34b79671a3a4de64fcee00d5242
Installing openssl-1.1.1i...
Installed openssl-1.1.1i to /Users/wangxiaofeng/.rbenv/versions/3.0.0

Downloading ruby-3.0.0.tar.gz...
-> https://cache.ruby-lang.org/pub/ruby/3.0/ruby-3.0.0.tar.gz
Installing ruby-3.0.0...
ruby-build: using readline from homebrew

BUILD FAILED (macOS 11.2.1 using ruby-build 20210119)

Inspect or clean up the working tree at /var/folders/hc/slkwwjpn5db488pdxb1k1hb80000gn/T/ruby-build.20210227234808.1292.czEIX7
Results logged to /var/folders/hc/slkwwjpn5db488pdxb1k1hb80000gn/T/ruby-build.20210227234808.1292.log

Last 10 log lines:
Check ext/readline/mkmf.log for more details.
* Fix the problems, then remove these directories and try again if you want.
Generating RDoc documentation
/private/var/folders/hc/slkwwjpn5db488pdxb1k1hb80000gn/T/ruby-build.20210227234808.1292.czEIX7/ruby-3.0.0/lib/time.rb:3:in require': cannot load such file -- date (LoadError) from /private/var/folders/hc/slkwwjpn5db488pdxb1k1hb80000gn/T/ruby-build.20210227234808.1292.czEIX7/ruby-3.0.0/lib/time.rb:3:in from /private/var/folders/hc/slkwwjpn5db488pdxb1k1hb80000gn/T/ruby-build.20210227234808.1292.czEIX7/ruby-3.0.0/lib/rdoc/rdoc.rb:7:in require' from /private/var/folders/hc/slkwwjpn5db488pdxb1k1hb80000gn/T/ruby-build.20210227234808.1292.czEIX7/ruby-3.0.0/lib/rdoc/rdoc.rb:7:in from ./libexec/rdoc:16:in require' from ./libexec/rdoc:16:in

'
make: *
[rdoc] Error 1
➜ ~

I also got this sometimes on Big Sur. Maybe, It's issues of Big Sur, not ruby-build.

@snibbets @csking119 @hsbt If you're having issues with Interrupted system call, you might try temporarily uninstalling or disabling security applications like Avira, Avast, ESET Endpoint Antivirus, Kaspersky, etc and then re-trying. This solved my similar issue.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

xargr picture xargr  Â·  6Comments

williambsb picture williambsb  Â·  5Comments

denisemauldin picture denisemauldin  Â·  4Comments

ghost picture ghost  Â·  4Comments

eddroid picture eddroid  Â·  4Comments