Error when installing Ruby with RVM on MacOS 10.11.6

Hi there,

I’m having errors when trying to install Ruby 2.6.1 on my Mac. I’ve run a search here and although I’m not the only one to run into issues, my error message seems different and I haven’t found a fix yet.

Help please!

Steps to reproduce

  1. rvm install 2.6.1

  2. vim /Users/laurac/.rvm/log/1552439405_ruby-2.6.1/package_install_coreutils_libyaml_readline_libksba_openssl@1.1.log

Actual behavior

  • Command:
Error running 'requirements_osx_brew_libs_install coreutils libyaml readline libksba openssl@1.1',
please read /Users/laurac/.rvm/log/1552439405_ruby-2.6.1/package_install_coreutils_libyaml_readline_libksba_openssl@1.1.log
Requirements installation failed with status: 1.
  • Log:
requirements_osx_brew_libs_install () 
{ 
    brew install "$@" --force || { 
        \typeset ret=$?;
        requirements_osx_brew_libs_error "installation";
        return $ret
    }
}
current path: /Users/laurac/Desktop/Ruby
PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/Users/laurac/.rvm/bin
command(6): requirements_osx_brew_libs_install coreutils libyaml readline libksba openssl@1.1
++ brew install coreutils libyaml readline libksba openssl@1.1 --force
Warning: You are using macOS 10.11.
We (and Apple) do not provide support for this old version.
You will encounter build failures with some formulae.
Please create pull requests instead of asking for help on Homebrew's GitHub,
Discourse, Twitter or IRC. You are responsible for resolving any issues you
experience, as you are running this old version.

==> Downloading https://ftp.gnu.org/gnu/coreutils/coreutils-8.31.tar.xz
Already downloaded: /Users/laurac/Library/Caches/Homebrew/downloads/6986a49efd8adf9ae4525c613a8660244612dfaa4e1571bb5ef0ff5105f35fac--coreutils-8.31.tar.xz
Error: An exception occurred within a child process:
  Errno::ENOENT: No such file or directory @ rb_sysopen - lib/renameat2.c
++ typeset ret=1
++ requirements_osx_brew_libs_error installation
++ rvm_warn 'There were package installation errors, make sure to read the log.

Try `brew tap --repair` and make sure `brew doctor` looks reasonable.

Check Homebrew requirements https://docs.brew.sh/Installation'
++ rvm_pretty_print stderr
++ case "${rvm_pretty_print_flag:=auto}" in
++ case "${TERM:-dumb}" in
++ case "$1" in
++ [[ -t 2 ]]
++ return 1
++ printf %b 'There were package installation errors, make sure to read the log.

Try `brew tap --repair` and make sure `brew doctor` looks reasonable.

Check Homebrew requirements https://docs.brew.sh/Installation\n'
++ return 1

Environment info

system:
xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

  system:
    uname:        "Darwin MacBook-Air-de-Laura-C.local 15.6.0 Darwin Kernel Version 15.6.0: Thu Jun 21 20:07:40 PDT 2018; root:xnu-3248.73.11~1/RELEASE_X86_64 x86_64"
    name:         "OSX"
    version:      "10.11"
    architecture: "x86_64"
    bash:         "/bin/bash => GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin15)"
    zsh:          "/bin/zsh => zsh 5.0.8 (x86_64-apple-darwin15.0)"
    remote_path:  "osx/10.11/x86_64"
    xcode:        ""

  rvm:
    version:      "1.29.7 (latest)"
    updated:      "20 hours 31 minutes 7 seconds ago"
    path:         "/Users/laurac/.rvm"
    autolibs:     "[4] Allow RVM to use package manager if found, install missing dependencies, install package manager (only OS X)."

  homes:
    gem:          "not set"
    ruby:         "not set"

  binaries:
    ruby:         "/usr/bin/ruby"
    irb:          "/usr/bin/irb"
    gem:          "/usr/bin/gem"
    rake:         "/usr/bin/rake"

  environment:
    PATH:         "/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/Users/laurac/.rvm/bin"
    GEM_HOME:     ""
    GEM_PATH:     ""
    MY_RUBY_HOME: ""
    IRBRC:        ""
    RUBYOPT:      ""
    gemset:       ""
1 Like

can you run ruby -v and tell me what it outputs?

1 Like

Hi there,

All sorted! It had to do with my MacOS version and Xcode not being installed :slight_smile: sorted then but thanks for your help!