rvm / rvm

Ruby enVironment Manager (RVM)
https://rvm.io
Other
5.12k stars 1.03k forks source link

OpenSSL 1.1 via Homebrew satisfies autolibs and builds ruby 2.3 but built rubies throw `LoadError` when attempting to use openssl #4819

Open lyjia opened 5 years ago

lyjia commented 5 years ago

Description

Hello, I've spent the last day and a half troubleshooting an issue with rvm, Homebrew, ruby 2.3.x, and OpenSSL 1.1. This issue seems to manifest with both latest as acquired via rvm get head, rvm get master, and via the rvm.io website as of time of writing for this issue.

Essentially, it appears that rvm allows rubies to build with and link against OpenSSL 1.1 as installed to /usr/local/opt/openssl, but then built rubies seem to expect libssl.1.0.0.dylib when require 'openssl' is called. With bundler this error manifests as:

Could not load OpenSSL.
You must recompile Ruby with OpenSSL support or change the sources in your
Gemfile from 'https' to 'http'. Instructions for compiling with OpenSSL using
RVM are available at rvm.io/packages/openssl.

which began occurring after OpenSSL 1.1 was installed (and 1.0 was removed) by Homebrew. Launching irb with irb -d -ropenssl also exposes the issue as it will throw a LoadError exception and quit. Reinstalling rubies does not fix the issue, and if I set autolibs to abort via rvm autolibs fail and then rebuild, autolibs will not fail-abort and the build will continue unimpeded, but incorrectly linked.

The workaround outlined at https://wiki.archlinux.org/index.php/RVM#RVM_uses_wrong_OpenSSL_version seems to fix the issue and allows correct builds, but requires the --with-openssl-dir switch to be set each time one wants to install a new ruby. (I tried installing this to my .bash_profile via an export RUBY_CONFIGURE_OPTS="--with-openssl-dir=$HOME/.rvm/usr" line but I don't think this is the right env var)

Steps to reproduce

I have to improvise a bit here because I spent a day and a half troubleshooting and diagnosing this issue before I was able to find a fix.

  1. Install OpenSSL via homebrew (it should install 1.1 to /usr/local/Cellar/openssl@1.1, and symlink that path to /usr/local/opt/openssl): brew install openssl; ls -lt /usr/local/opt/ | grep openssl
  2. Verify that /usr/local/opt/openssl/libssl.dylib links to libssl1.1.dylib: ls -lt /usr/local/opt/openssl/lib | grep libssl
  3. Install ruby via rvm: rvm install 2.3.7 (or whatever version). Note that in the described bug state, there will be numerous errors installing gems appearing in the build's console output:
    ruby-2.3.5 - #importing gemset /Users/tomcorelis/.rvm/gemsets/global.gems..................there was an error installing gem gem-wrappers
    .................there was an error installing gem rubygems-bundler
    .........................there was an error installing gem rvm

    and so on.

  4. Verify install with ruby -v then try irb -ropenssl. irb should immediately throw LoadError: cannot load such file -- openssl
  5. Similarly, gem install bundler will fail, also throwing LoadError.

Workaround:

  1. Install openssl via rvm pkg install openssl
  2. Remove and reinstall rubies with rvm reinstall 2.3.1 --with-openssl-dir=$HOME/.rvm/usr
  3. Repeat steps 4 and 5 and they should no longer throw exceptions; ruby should function as normal

Expected behavior

I expected rvm to handle OpenSSL 1.1 either by throwing an error or having compilation link to the correct dylibs. Compiled rubies should not throw LoadError when requiring openssl.

Actual behavior

Here is the output of a typical install that fails: https://gist.github.com/lyjia/10fda651f035a22ff7df1d884d9d9ccf

Additionally, by forcing ruby to link against Homebrew-installed /usr/local/opt/openssl\@1.0 I was able to induce an interesting error: https://gist.github.com/lyjia/9efbaa0caf5f1265121e91fb28e96d52

Environment info

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

  system:
    uname:        "Darwin [computer name] 17.7.0 Darwin Kernel Version 17.7.0: Fri Oct  4 23:08:59 PDT 2019; root:xnu-4570.71.57~1/RELEASE_X86_64 x86_64"
    name:         "OSX"
    version:      "10.13"
    architecture: "x86_64"
    bash:         "/bin/bash => GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin17)"
    zsh:          "/bin/zsh => zsh 5.3 (x86_64-apple-darwin17.0)"
    remote_path:  "osx/10.13/x86_64"
    xcode:        ""

  rvm:
    version:      "1.29.9-next (master)"
    updated:      "1 hour 17 minutes 33 seconds ago"
    path:         "/Users/tomcorelis/.rvm"
    autolibs:     "[4] Allow RVM to use package manager if found, install missing dependencies, install package manager (only OS X)."

  ruby:
    interpreter:  "ruby"
    version:      "2.3.5p376"
    date:         "2017-09-14"
    platform:     "x86_64-darwin17"
    patchlevel:   "2017-09-14 revision 59905"
    full_version: "ruby 2.3.5p376 (2017-09-14 revision 59905) [x86_64-darwin17]"

  homes:
    gem:          "/Users/tomcorelis/.rvm/gems/ruby-2.3.5"
    ruby:         "/Users/tomcorelis/.rvm/rubies/ruby-2.3.5"

  binaries:
    ruby:         "/Users/tomcorelis/.rvm/rubies/ruby-2.3.5/bin/ruby"
    irb:          "/Users/tomcorelis/.rvm/rubies/ruby-2.3.5/bin/irb"
    gem:          "/Users/tomcorelis/.rvm/rubies/ruby-2.3.5/bin/gem"
    rake:         "/Users/tomcorelis/.rvm/rubies/ruby-2.3.5/bin/rake"

  environment:
    PATH:         "/Users/tomcorelis/.rvm/gems/ruby-2.3.5/bin:/Users/tomcorelis/.rvm/gems/ruby-2.3.5@global/bin:/Users/tomcorelis/.rvm/rubies/ruby-2.3.5/bin:/Users/tomcorelis/.rvm/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/Wireshark.app/Contents/MacOS:/Users/tomcorelis/Library/Python/2.7/bin:/Users/tomcorelis/Library/Python/2.7/bin"
    GEM_HOME:     "/Users/tomcorelis/.rvm/gems/ruby-2.3.5"
    GEM_PATH:     "/Users/tomcorelis/.rvm/gems/ruby-2.3.5:/Users/tomcorelis/.rvm/gems/ruby-2.3.5@global"
    MY_RUBY_HOME: "/Users/tomcorelis/.rvm/rubies/ruby-2.3.5"
    IRBRC:        "/Users/tomcorelis/.rvm/rubies/ruby-2.3.5/.irbrc"
    RUBYOPT:      ""
    gemset:       ""

Related links that helped with finding a workaround

https://wiki.archlinux.org/index.php/RVM#RVM_uses_wrong_OpenSSL_version

https://stackoverflow.com/questions/15511943/troubles-with-rvm-and-openssl

https://github.com/rbenv/ruby-build/issues/1353

Versions tested with

2.3.1, 2.3.5, 2.3.7

Does not seem to manifest with 2.4.9, 2.5.7, or 2.6.5

Fayer00 commented 4 years ago

i have the same problem and trying to fix it no my computer

auspicious99 commented 4 years ago

I have the same problem with ruby 2.4.1

rbq commented 4 years ago

Finally managed to install using the old RVM package mechanism as a workaround:

rvm pkg remove &&\
rvm pkg install openssl &&\
rvm reinstall 2.2.10 --with-openssl-dir=$HOME/.rvm/usr
lyjia commented 4 years ago

Finally managed to install using the old RVM package mechanism as a workaround:

rvm pkg remove &&\
rvm pkg install openssl &&\
rvm reinstall 2.2.10 --with-openssl-dir=$HOME/.rvm/usr

I tried that during my original round of troubleshooting but still had issues compiling gems. Are all your gems installing/compiling/running ok?

A coworker found a potential fix but I haven’t had a chance to try it out yet

rbq commented 4 years ago

@lyjia No issues so far.

lyjia commented 4 years ago

Tentatively, @rbq 's solution (using version 2.3.1 instead of 2.2.10) seems to work for me without any side effects. Thanks!!

jyr commented 4 years ago

Hi,

I have the same error and tried with multiple options:

$ RUBY_CONFIGURE_OPTS="--with-openssl-dir=/usr/local/opt/openssl" rvm install ruby-2.1.2
$ rvm install --disable-binary  ruby-2.1.2 --autolibs=homebrew --with-openssl-dir=`brew --prefix libressl`
$ rvm install ruby-2.1.2 --autolibs=homebrew --with-openssl-dir=`brew --prefix libressl`

I have LibreSSL 3.0.2 and I'm using macOS High Sierra version 10.13.6

the error is:

++ printf %b 'command(6): command gem install /Users/jyr/.rvm/gem-cache/gem-wrappers-1.4.0.gem --local --no-document\n'
++ rvm_log 'installing gem /Users/jyr/.rvm/gem-cache/gem-wrappers-1.4.0.gem --local --no-document'
++ [[ '' == 1 ]]
++ printf %b 'installing gem /Users/jyr/.rvm/gem-cache/gem-wrappers-1.4.0.gem --local --no-document\n'
++ command gem install /Users/jyr/.rvm/gem-cache/gem-wrappers-1.4.0.gem --local --no-document
++ gem install /Users/jyr/.rvm/gem-cache/gem-wrappers-1.4.0.gem --local --no-document
ERROR:  Loading command: install (LoadError)
        cannot load such file -- openssl
ERROR:  While executing gem ... (NoMethodError)
    undefined method `invoke_with_build_args' for nil:NilClass
++ return 1
++ return 1
++ return 1
++ return 1

When I want to install openssl

$ rvm list
=> ruby-2.1.2 [ x86_64 ]
 * ruby-2.6.3 [ x86_64 ]

# => - current
# =* - current && default
#  * - default
$ gem install openssl
ERROR:  Loading command: install (LoadError)
    cannot load such file -- openssl
ERROR:  While executing gem ... (NoMethodError)
    undefined method `invoke_with_build_args' for nil:NilClass

And I have libressl via homebrew:

$ brew --prefix libressl
/usr/local/opt/libressl

Thanks a lot

marsz commented 4 years ago

I tried this and it works

brew install rbenv/tap/openssl@1.0
rvm install 2.3.8 -C --with-openssl-dir=`brew --prefix openssl@1.0`

I need both openssl 1.0 & 1.1 for different ruby versions on my local development environment, so this solution I think is better for this situation.

raghvendra1501 commented 4 years ago

Thanks, I wasted my whole day in it and finally the solution of @marsz worked for me.

jamiecook commented 4 years ago

I'm having the same trouble. Unfortunately @marsz solution didn't work for me... but it was closer than any others

rvm install output

```bash rvm --autolibs=disable install 2.2.6 -C --with-openssl-dir=`brew --prefix openssl@1.0` ruby-2.2.6 - #removing src/ruby-2.2.6.. Installing Ruby from source to: /Users/jamie/.rvm/rubies/ruby-2.2.6, this may take a while depending on your cpu(s)... ruby-2.2.6 - #downloading ruby-2.2.6, this may take a while depending on your connection... ruby-2.2.6 - #extracting ruby-2.2.6 to /Users/jamie/.rvm/src/ruby-2.2.6..... ruby-2.2.6 - #applying patch /Users/jamie/.rvm/patches/ruby/2.2.6/fix_installing_bundled_gems.patch. ruby-2.2.6 - #configuring.......................................................... ruby-2.2.6 - #post-configuration. ruby-2.2.6 - #compiling............................................................ ruby-2.2.6 - #installing......... ruby-2.2.6 - #making binaries executable.. ruby-2.2.6 - #downloading rubygems-3.0.8 ruby-2.2.6 - #extracting rubygems-3.0.8...... ruby-2.2.6 - #removing old rubygems........ ruby-2.2.6 - #installing rubygems-3.0.8.. Error running 'env GEM_HOME=/Users/jamie/.rvm/gems/ruby-2.2.6@global GEM_PATH= /Users/jamie/.rvm/rubies/ruby-2.2.6/bin/ruby -d /Users/jamie/.rvm/src/rubygems-3.0.8/setup.rb --no-document', please read /Users/jamie/.rvm/log/1585718835_ruby-2.2.6/rubygems.install.log

So it configured and compiled correctly... or so it says. Looking in the make.log I get these lines

Ignore OpenSSL broken by Apple.
Please use another openssl. (e.g. using `configure --with-openssl-dir=/path/to/openssl')
Failed to configure openssl. It will not be installed.
full configure.log

``` [2020-04-01 15:27:19] ./configure current path: /Users/jamie/.rvm/src/ruby-2.2.6 GEM_HOME=/Users/jamie/.rvm/gems/ruby-2.2.6 GEM_PATH=/Users/jamie/.rvm/gems/ruby-2.2.6:/Users/jamie/.rvm/gems/ruby-2.2.6@global PATH=/Users/jamie/.rvm/usr/bin:/Users/jamie/.rvm/gems/ruby-2.2.6/bin:/Users/jamie/.rvm/gems/ruby-2.2.6@global/bin:/Users/jamie/.rvm/rubies/ruby-2.2.6/bin:/Users/jamie/.rvm/bin:/Users/jamie/.poetry/bin:/Users/jamie/.pyenv/shims:/Users/jamie/.nvm/versions/node/v8.9.3/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/usr/local/bin:/usr/local/git/bin:/Users/jamie/.local/bin:/Users/jamie/bin:/opt/jdk17/bin command(5): ./configure --prefix=/Users/jamie/.rvm/rubies/ruby-2.2.6 --with-openssl-dir=/usr/local/opt/openssl@1.0 --disable-install-doc --enable-shared config.guess already exists config.sub already exists checking build system type... x86_64-apple-darwin18.7.0 checking host system type... x86_64-apple-darwin18.7.0 checking target system type... x86_64-apple-darwin18.7.0 checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking whether we are using the GNU C++ compiler... yes checking whether g++ accepts -g... yes checking how to run the C preprocessor... gcc -E checking for grep that handles long lines and -e... /usr/bin/grep checking for egrep... /usr/bin/grep -E checking whether gcc needs -traditional... no checking for ld... ld checking whether the linker is GNU ld... no checking whether gcc -E accepts -o... yes checking for real target cpu... x86_64 checking for ranlib... ranlib checking for ar... ar checking for as... as checking for objdump... objdump checking for objcopy... no checking for gobjcopy... no checking for nm... nm checking whether ln -s works... yes checking whether make sets $(MAKE)... yes checking for a BSD-compatible install... /usr/local/bin/ginstall -c checking for a thread-safe mkdir -p... /usr/local/bin/gmkdir -p checking for dtrace... dtrace checking for dot... dot checking for doxygen... doxygen checking for pkg-config... pkg-config checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking minix/config.h usability... no checking minix/config.h presence... no checking for minix/config.h... no checking whether it is safe to define __EXTENSIONS__... yes checking for cd using physical directory... cd -P checking whether CFLAGS is valid... yes checking whether LDFLAGS is valid... yes checking whether -Wno-unused-parameter is accepted as CFLAGS... yes checking whether -Wno-parentheses is accepted as CFLAGS... yes checking whether -Wno-long-long is accepted as CFLAGS... yes checking whether -Wno-missing-field-initializers is accepted as CFLAGS... yes checking whether -Wunused-variable is accepted as CFLAGS... yes checking whether -Wpointer-arith is accepted as CFLAGS... yes checking whether -Wwrite-strings is accepted as CFLAGS... yes checking whether -Wdeclaration-after-statement is accepted as CFLAGS... yes checking whether -Wshorten-64-to-32 is accepted as CFLAGS... yes checking whether -Wimplicit-function-declaration is accepted as CFLAGS... yes checking whether -Wdivision-by-zero is accepted as CFLAGS... yes checking whether -Wdeprecated-declarations is accepted as CFLAGS... yes checking whether -Wno-packed-bitfield-compat is accepted as CFLAGS... no checking whether -Wextra-tokens is accepted as CFLAGS... yes checking whether -Wall -Wextra is accepted as CFLAGS... yes checking whether -Qunused-arguments is accepted as CFLAGS... yes checking whether -D_FORTIFY_SOURCE=2 is accepted as CFLAGS... yes checking whether -fstack-protector is accepted as CFLAGS... yes checking whether -fstack-protector is accepted as LDFLAGS... yes checking whether -fno-strict-overflow is accepted as CFLAGS... yes checking whether -ggdb3 is accepted as CFLAGS... yes checking whether -fvisibility=hidden is accepted as CFLAGS... yes checking whether -fno-fast-math is accepted as CFLAGS... yes checking whether Mac OS X 10.5 or later... yes checking for broken crypt with 8bit chars... no checking for codesign... codesign checking for crt_externs.h... yes checking for crypt in -lcrypt... (cached) no checking for dlopen in -ldl... yes checking for shl_load in -ldld... no checking for shutdown in -lsocket... no checking for dirent.h that defines DIR... yes checking for library containing opendir... none required checking for stdbool.h that conforms to C99... yes checking for _Bool... yes checking for sys/wait.h that is POSIX.1 compatible... yes checking limits.h usability... yes checking limits.h presence... yes checking for limits.h... yes checking sys/file.h usability... yes checking sys/file.h presence... yes checking for sys/file.h... yes checking sys/ioctl.h usability... yes checking sys/ioctl.h presence... yes checking for sys/ioctl.h... yes checking sys/syscall.h usability... yes checking sys/syscall.h presence... yes checking for sys/syscall.h... yes checking fcntl.h usability... yes checking fcntl.h presence... yes checking for fcntl.h... yes checking sys/fcntl.h usability... yes checking sys/fcntl.h presence... yes checking for sys/fcntl.h... yes checking sys/param.h usability... yes checking sys/param.h presence... yes checking for sys/param.h... yes checking sys/select.h usability... yes checking sys/select.h presence... yes checking for sys/select.h... yes checking sys/time.h usability... yes checking sys/time.h presence... yes checking for sys/time.h... yes checking sys/times.h usability... yes checking sys/times.h presence... yes checking for sys/times.h... yes checking syscall.h usability... no checking syscall.h presence... no checking for syscall.h... no checking pwd.h usability... yes checking pwd.h presence... yes checking for pwd.h... yes checking grp.h usability... yes checking grp.h presence... yes checking for grp.h... yes checking a.out.h usability... no checking a.out.h presence... no checking for a.out.h... no checking utime.h usability... yes checking utime.h presence... yes checking for utime.h... yes checking direct.h usability... no checking direct.h presence... no checking for direct.h... no checking sys/resource.h usability... yes checking sys/resource.h presence... yes checking for sys/resource.h... yes checking sys/mkdev.h usability... no checking sys/mkdev.h presence... no checking for sys/mkdev.h... no checking sys/utime.h usability... no checking sys/utime.h presence... no checking for sys/utime.h... no checking float.h usability... yes checking float.h presence... yes checking for float.h... yes checking ieeefp.h usability... no checking ieeefp.h presence... no checking for ieeefp.h... no checking ucontext.h usability... yes checking ucontext.h presence... yes checking for ucontext.h... yes checking intrinsics.h usability... no checking intrinsics.h presence... no checking for intrinsics.h... no checking langinfo.h usability... yes checking langinfo.h presence... yes checking for langinfo.h... yes checking locale.h usability... yes checking locale.h presence... yes checking for locale.h... yes checking sys/sendfile.h usability... no checking sys/sendfile.h presence... no checking for sys/sendfile.h... no checking time.h usability... yes checking time.h presence... yes checking for time.h... yes checking net/socket.h usability... no checking net/socket.h presence... no checking for net/socket.h... no checking sys/socket.h usability... yes checking sys/socket.h presence... yes checking for sys/socket.h... yes checking process.h usability... no checking process.h presence... no checking for process.h... no checking sys/prctl.h usability... no checking sys/prctl.h presence... no checking for sys/prctl.h... no checking sys/uio.h usability... yes checking sys/uio.h presence... yes checking for sys/uio.h... yes checking atomic.h usability... no checking atomic.h presence... no checking for atomic.h... no checking malloc.h usability... no checking malloc.h presence... no checking for malloc.h... no checking malloc_np.h usability... no checking malloc_np.h presence... no checking for malloc_np.h... no checking malloc/malloc.h usability... yes checking malloc/malloc.h presence... yes checking for malloc/malloc.h... yes checking setjmpex.h usability... no checking setjmpex.h presence... no checking for setjmpex.h... no checking sys/attr.h usability... yes checking sys/attr.h presence... yes checking for sys/attr.h... yes checking sys/id.h usability... no checking sys/id.h presence... no checking for sys/id.h... no checking gmp.h usability... yes checking gmp.h presence... yes checking for gmp.h... yes checking for __gmpz_init in -lgmp... yes checking for special C compiler options needed for large files... no checking for _FILE_OFFSET_BITS value needed for large files... no checking whether byte ordering is bigendian... no checking for an ANSI C-conforming const... yes checking whether char is unsigned... no checking for inline... inline checking for working volatile... yes checking for typeof syntax and keyword spelling... typeof checking for long long... yes checking for off_t... yes checking char bit... 8 checking size of int... 4 checking size of short... 2 checking size of long... 8 checking size of long long... 8 checking size of __int64... 0 checking size of __int128... 16 checking size of off_t... 8 checking size of void*... 8 checking size of float... 4 checking size of double... 8 checking size of time_t... 8 checking size of clock_t... 8 checking packed struct attribute... x __attribute__((packed)) checking for printf prefix for long long... ll checking for pid_t... yes checking for convertible type of pid_t... INT checking for uid_t... yes checking for convertible type of uid_t... UINT checking for gid_t... yes checking for convertible type of gid_t... UINT checking for time_t... yes checking for convertible type of time_t... LONG checking for dev_t... yes checking for convertible type of dev_t... INT checking for mode_t... yes checking for convertible type of mode_t... UINT checking for rlim_t... yes checking for convertible type of rlim_t... ULL checking for off_t... (cached) yes checking for convertible type of off_t... LL checking for clockid_t... no checking for convertible type of clockid_t... INT checking for prototypes... yes checking token paste string... ansi checking stringization... #expr checking string literal concatenation... yes checking for variable length prototypes and stdarg.h... yes checking for variable length macro... yes checking for NORETURN function attribute... __attribute__ ((noreturn)) x checking for DEPRECATED function attribute... __attribute__ ((deprecated)) x checking for NOINLINE function attribute... __attribute__ ((noinline)) x checking for stdcall function attribute... x checking for cdecl function attribute... __attribute__ ((cdecl)) x checking for fastcall function attribute... x checking for FUNC_MINIMIZED function attribute... x checking for function alias... no checking for __atomic builtins... yes checking for __sync builtins... yes checking for __builtin_unreachable... yes checking for exported function attribute... __attribute__ ((visibility("default"))) checking for function name string predefined identifier... __func__ checking whether sys_nerr is declared... yes checking whether getenv is declared... yes checking for size_t... yes checking size of size_t... 8 checking size of ptrdiff_t... 8 checking for printf prefix for size_t... z checking for printf prefix for ptrdiff_t... t checking for struct stat.st_blksize... yes checking for struct stat.st_blocks... yes checking for struct stat.st_rdev... yes checking size of struct stat.st_size... SIZEOF_OFF_T checking size of struct stat.st_blocks... SIZEOF_OFF_T checking size of struct stat.st_ino... SIZEOF_LONG checking for struct stat.st_atim... no checking for struct stat.st_atimespec... yes checking for struct stat.st_atimensec... no checking for struct stat.st_mtim... no checking for struct stat.st_mtimespec... yes checking for struct stat.st_mtimensec... no checking for struct stat.st_ctim... no checking for struct stat.st_ctimespec... yes checking for struct stat.st_ctimensec... no checking for struct stat.st_birthtimespec... yes checking for struct timeval... yes checking size of struct timeval.tv_sec... SIZEOF_TIME_T checking for struct timespec... yes checking for struct timezone... yes checking for clockid_t... (cached) no checking for fd_mask... yes checking for int8_t... yes checking size of int8_t... 1 checking for uint8_t... yes checking size of uint8_t... 1 checking for int16_t... yes checking size of int16_t... 2 checking for uint16_t... yes checking size of uint16_t... 2 checking for int32_t... yes checking size of int32_t... 4 checking for uint32_t... yes checking size of uint32_t... 4 checking for int64_t... yes checking size of int64_t... 8 checking for uint64_t... yes checking size of uint64_t... 8 checking for int128_t... __int128 checking for uint128_t... unsigned __int128 checking for intptr_t... yes checking size of intptr_t... 8 checking for uintptr_t... yes checking size of uintptr_t... 8 checking for ssize_t... yes checking size of ssize_t... 8 checking for stack end address... no checking for uid_t in sys/types.h... (cached) yes checking type of array argument to getgroups... (cached) gid_t checking return type of signal handlers... void checking for working alloca.h... yes checking for alloca... yes checking for dynamic size alloca... ok checking for working memcmp... yes checking for broken erfc of glibc-2.3.6 on IA64... no checking for acosh... yes checking for cbrt... yes checking for crypt... yes checking for dup2... yes checking for erf... yes checking for ffs... yes checking for finite... yes checking for flock... yes checking for hypot... yes checking for isinf... yes checking for isnan... yes checking for lgamma_r... yes checking for memmove... yes checking for nextafter... yes checking for setproctitle... no checking for strchr... yes checking for strerror... yes checking for strlcat... yes checking for strlcpy... yes checking for strstr... yes checking for tgamma... yes checking sys/pstat.h usability... no checking sys/pstat.h presence... no checking for sys/pstat.h... no checking for signbit... yes checking for pid_t... (cached) yes checking vfork.h usability... no checking vfork.h presence... no checking for vfork.h... no checking for fork... yes checking for vfork... (cached) no checking for working fork... yes checking for __syscall... yes checking for _longjmp... yes checking for _setjmp... no checking for _setjmpex... no checking for atan2l... yes checking for atan2f... yes checking for chroot... yes checking for chsize... no checking for clock_gettime... yes checking for cosh... yes checking for daemon... (cached) no checking for dirfd... yes checking for dl_iterate_phdr... no checking for dlopen... yes checking for dladdr... yes checking for dup... yes checking for dup3... no checking for eaccess... no checking for endgrent... yes checking for fchmod... yes checking for fchown... yes checking for fcntl... yes checking for fdatasync... (cached) no checking for fgetattrlist... yes checking for fmod... yes checking for fsync... yes checking for ftruncate... yes checking for ftruncate64... no checking for getattrlist... yes checking for getcwd... yes checking for getgidx... no checking for getgrnam... yes checking for getgrnam_r... yes checking for getgroups... yes checking for getpgid... yes checking for getpgrp... yes checking for getpriority... yes checking for getpwnam_r... yes checking for getresgid... no checking for getresuid... no checking for getrlimit... yes checking for getsid... yes checking for gettimeofday... yes checking for getuidx... no checking for gmtime_r... yes checking for initgroups... yes checking for ioctl... yes checking for isfinite... no checking for issetugid... yes checking for killpg... yes checking for lchmod... yes checking for lchown... yes checking for link... yes checking for llabs... yes checking for lockf... yes checking for log2... yes checking for lstat... yes checking for malloc_usable_size... no checking for malloc_size... yes checking for mblen... yes checking for memalign... no checking for writev... yes checking for memrchr... no checking for memmem... yes checking for mktime... yes checking for pipe2... no checking for poll... yes checking for posix_fadvise... no checking for posix_memalign... yes checking for ppoll... no checking for pread... yes checking for qsort_r... yes checking for readlink... yes checking for round... yes checking for sched_getaffinity... no checking for seekdir... yes checking for select_large_fdset... no checking for sendfile... yes checking for setegid... yes checking for setenv... yes checking for seteuid... yes checking for setgid... yes checking for setgroups... yes checking for setpgid... yes checking for setpgrp... yes checking for setregid... yes checking for setresgid... no checking for setresuid... no checking for setreuid... yes checking for setrgid... yes checking for setrlimit... yes checking for setruid... yes checking for setsid... yes checking for setuid... yes checking for shutdown... yes checking for sigaction... yes checking for sigaltstack... yes checking for sigprocmask... yes checking for sinh... yes checking for spawnv... no checking for symlink... yes checking for syscall... yes checking for sysconf... yes checking for tanh... yes checking for telldir... yes checking for timegm... yes checking for times... yes checking for truncate... yes checking for truncate64... no checking for unsetenv... yes checking for utimensat... yes checking for utimes... yes checking for wait4... yes checking for waitpid... yes checking if getcwd allocates buffer if NULL is given... yes checking for __builtin_bswap16... yes checking for __builtin_bswap32... yes checking for __builtin_bswap64... yes checking for __builtin_clz... yes checking for __builtin_clzl... yes checking for __builtin_clzll... yes checking for __builtin_choose_expr... yes checking for __builtin_choose_expr_constant_p... yes checking for __builtin_types_compatible_p... yes checking whether qsort_r is GNU version... no checking whether qsort_r is BSD version... yes checking whether atan2 handles Inf as C99... yes checking whether lgamma_r handles -0.0... no checking for clock_getres... yes checking for unsetenv returns a value... yes checking for sigsetjmp as a macro or function... yes checking whether struct tm is in sys/time.h or time.h... time.h checking for struct tm.tm_zone... yes checking for struct tm.tm_gmtoff... yes checking for external int daylight... yes checking for external timezone... long checking for external altzone... no checking for timezone... yes checking whether timezone requires zero arguments... yes checking for negative time_t for gmtime(3)... yes checking for localtime(3) overflow correctly... yes checking whether right shift preserve sign bit... yes checking whether _SC_CLK_TCK is supported... yes checking stack growing direction on x86_64... -1 checking for pthread_kill in -lthr... no checking for pthread_kill in -lpthread... yes checking for pthread_np.h... no checking whether pthread_t is scalar type... yes checking for sched_yield... yes checking for pthread_attr_setinheritsched... yes checking for pthread_attr_get_np... no checking for pthread_attr_getstack... yes checking for pthread_get_stackaddr_np... yes checking for pthread_get_stacksize_np... yes checking for thr_stksegment... no checking for pthread_stackseg_np... no checking for pthread_getthrds_np... no checking for pthread_cond_init... yes checking for pthread_condattr_setclock... no checking for pthread_condattr_init... yes checking for pthread_sigmask... yes checking for pthread_setname_np... yes checking for pthread_getattr_np... no checking for pthread_attr_init... yes checking arguments of pthread_setname_np... (name) checking if mcontext_t is a pointer... yes checking for getcontext... (cached) no checking for setcontext... (cached) no checking if fork works with pthread... yes checking whether ELF binaries are produced... no checking whether OS depend dynamic link works... yes checking whether -Wl,-undefined,dynamic_lookup is accepted as LDFLAGS... yes checking whether -Wl,-multiply_defined,suppress is accepted as LDFLAGS... yes checking execinfo.h usability... yes checking execinfo.h presence... yes checking for execinfo.h... yes checking for backtrace in -lexecinfo... no checking libunwind.h usability... yes checking libunwind.h presence... yes checking for libunwind.h... yes checking for backtrace... yes checking for broken backtrace... yes checking valgrind/memcheck.h usability... no checking valgrind/memcheck.h presence... no checking for valgrind/memcheck.h... no checking for strip... strip checking whether -Wl,--no-undefined is accepted as LDFLAGS... no checking whether dtrace USDT is available... yes checking whether dtrace USDT is available... (cached) yes checking whether dtrace needs post processing... no checking for __builtin_setjmp... (cached) no checking for setjmp type... sigsetjmp checking for prefix of external symbols... _ checking pthread.h usability... yes checking pthread.h presence... yes checking for pthread.h... yes checking if make is GNU make... yes checking for broken memmem... yes checking for nroff... /usr/bin/nroff .ext/include/x86_64-darwin18/ruby/config.h updated ruby library version = 2.2.0 configure: creating ./config.status config.status: creating GNUmakefile config.status: creating Makefile config.status: creating ruby-2.2.pc ```

full make.log

``` [2020-04-01 15:28:03] __rvm_make __rvm_make () { \make "$@" || return $? } current path: /Users/jamie/.rvm/src/ruby-2.2.6 GEM_HOME=/Users/jamie/.rvm/gems/ruby-2.2.6 GEM_PATH=/Users/jamie/.rvm/gems/ruby-2.2.6:/Users/jamie/.rvm/gems/ruby-2.2.6@global PATH=/Users/jamie/.rvm/usr/bin:/Users/jamie/.rvm/gems/ruby-2.2.6/bin:/Users/jamie/.rvm/gems/ruby-2.2.6@global/bin:/Users/jamie/.rvm/rubies/ruby-2.2.6/bin:/Users/jamie/.rvm/bin:/Users/jamie/.poetry/bin:/Users/jamie/.pyenv/shims:/Users/jamie/.nvm/versions/node/v8.9.3/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/usr/local/bin:/usr/local/git/bin:/Users/jamie/.local/bin:/Users/jamie/bin:/opt/jdk17/bin command(2): __rvm_make -j8 ++ make -j8 CC = gcc LD = ld LDSHARED = gcc -dynamiclib CFLAGS = -O3 -fno-fast-math -ggdb3 -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Wunused-variable -Wpointer-arith -Wwrite-strings -Wdeclaration-after-statement -Wshorten-64-to-32 -Wimplicit-function-declaration -Wdivision-by-zero -Wdeprecated-declarations -Wextra-tokens -fno-common -pipe XCFLAGS = -D_FORTIFY_SOURCE=2 -fstack-protector -fno-strict-overflow -fvisibility=hidden -DRUBY_EXPORT CPPFLAGS = -I/usr/local/opt/openssl@1.0/include -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE -D_DARWIN_UNLIMITED_SELECT -D_REENTRANT -I. -I.ext/include/x86_64-darwin18 -I./include -I. DLDFLAGS = -Wl,-undefined,dynamic_lookup -Wl,-multiply_defined,suppress -install_name /Users/jamie/.rvm/rubies/ruby-2.2.6/lib/libruby.2.2.0.dylib -current_version 2.2.0 -compatibility_version 2.2.0 -fstack-protector -Wl,-u,_objc_msgSend -framework CoreFoundation -fstack-protector -Wl,-u,_objc_msgSend -framework CoreFoundation SOLIBS = -lpthread -lgmp -ldl -lobjc translating probes probes.d compiling main.c compiling dmydln.c compiling miniinit.c compiling miniprelude.c compiling bignum.c compiling class.c Configured with: --prefix=/Library/Developer/CommandLineTools/usr --with-gxx-include-dir=/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/c++/4.2.1 Apple LLVM version 10.0.1 (clang-1001.0.46.4) Target: x86_64-apple-darwin18.7.0 Thread model: posix InstalledDir: /Library/Developer/CommandLineTools/usr/bin compiling compar.c compiling complex.c . ./vm_opts.h compiling dir.c compiling dln_find.c compiling encoding.c compiling enum.c compiling enumerator.c encoding.c:825:2: warning: implicit declaration of function 'rb_str_change_terminator_length' is invalid in C99 [-Wimplicit-function-declaration] rb_str_change_terminator_length(obj, oldtermlen, termlen); ^ compiling error.c compiling eval.c 1 warning generated. compiling load.c compiling proc.c compiling file.c compiling gc.c compiling hash.c compiling inits.c compiling io.c compiling marshal.c compiling math.c compiling node.c compiling numeric.c compiling object.c compiling pack.c compiling parse.c compiling process.c compiling random.c compiling range.c compiling rational.c compiling re.c compiling regcomp.c compiling regenc.c compiling regerror.c compiling regexec.c compiling regparse.c compiling regsyntax.c compiling ruby.c compiling safe.c compiling signal.c compiling sprintf.c compiling st.c compiling strftime.c compiling string.c compiling struct.c compiling symbol.c compiling time.c compiling transcode.c compiling util.c compiling variable.c compiling version.c compiling compile.c compiling debug.c compiling iseq.c compiling vm.c compiling vm_dump.c compiling vm_backtrace.c compiling vm_trace.c compiling thread.c thread.c:1065:27: warning: implicit conversion loses integer precision: 'long' to '__darwin_suseconds_t' (aka 'int') [-Wshorten-64-to-32] tp->tv_usec = ts.tv_nsec / 1000; ~ ~~~~~~~~~~~^~~~~~ compiling cont.c compiling ./enc/ascii.c compiling ./enc/us_ascii.c compiling ./enc/unicode.c compiling ./enc/utf_8.c compiling newline.c compiling ./missing/setproctitle.c compiling dmyext.c compiling dmyenc.c compiling dln.c compiling localeinit.c compiling prelude.c compiling array.c 1 warning generated. linking miniruby generating encdb.h rbconfig.rb updated generating enc.mk creating verconf.h verconf.h updated compiling loadpath.c encdb.h updated making srcs under enc make[1]: Nothing to be done for `srcs'. generating transdb.h linking static-library libruby.2.2.0-static.a verifying static-library libruby.2.2.0-static.a transdb.h updated linking shared-library libruby.2.2.0.dylib generating makefile exts.mk making enc making trans compiling ./enc/trans/transdb.c compiling ./enc/encdb.c compiling ./enc/emacs_mule.c compiling ./enc/cp949.c compiling ./enc/euc_kr.c compiling ./enc/euc_jp.c compiling ./enc/big5.c configuring -test-/array/resize configuring -test-/bignum configuring -test-/bug-3571 compiling ./enc/trans/big5.c configuring -test-/bug-3662 configuring -test-/bug-5832 configuring -test-/bug_reporter configuring -test-/class configuring -test-/debug configuring -test-/dln/empty configuring -test-/exception configuring -test-/fatal configuring -test-/file compiling ./enc/trans/chinese.c compiling ./enc/euc_tw.c compiling ./enc/trans/emoji.c compiling ./enc/trans/emoji_iso2022_kddi.c compiling ./enc/trans/emoji_sjis_docomo.c compiling ./enc/gb2312.c compiling ./enc/trans/emoji_sjis_kddi.c compiling ./enc/gb18030.c compiling ./enc/gbk.c compiling ./enc/iso_8859_1.c compiling ./enc/trans/emoji_sjis_softbank.c compiling ./enc/iso_8859_2.c compiling ./enc/iso_8859_3.c compiling ./enc/iso_8859_4.c compiling ./enc/trans/escape.c compiling ./enc/iso_8859_5.c compiling ./enc/iso_8859_6.c compiling ./enc/trans/gb18030.c compiling ./enc/iso_8859_7.c compiling ./enc/trans/gbk.c compiling ./enc/trans/iso2022.c compiling ./enc/iso_8859_8.c compiling ./enc/iso_8859_9.c compiling ./enc/iso_8859_10.c compiling ./enc/iso_8859_11.c compiling ./enc/iso_8859_13.c compiling ./enc/trans/japanese.c compiling ./enc/trans/japanese_euc.c compiling ./enc/trans/japanese_sjis.c configuring -test-/float compiling ./enc/iso_8859_14.c configuring -test-/funcall configuring -test-/hash configuring -test-/iseq_load configuring -test-/iter configuring -test-/load/dot.dot configuring -test-/marshal/compat configuring -test-/marshal/usr compiling ./enc/iso_8859_15.c configuring -test-/method configuring -test-/num2int configuring -test-/path_to_class configuring -test-/postponed_job configuring -test-/printf configuring -test-/proc configuring -test-/rational configuring -test-/recursion configuring -test-/st/foreach configuring -test-/st/numhash configuring -test-/st/update configuring -test-/string configuring -test-/struct configuring -test-/symbol compiling ./enc/trans/korean.c compiling ./enc/iso_8859_16.c compiling ./enc/koi8_r.c compiling ./enc/koi8_u.c configuring -test-/tracepoint configuring -test-/typeddata configuring -test-/vm compiling ./enc/trans/single_byte.c compiling ./enc/shift_jis.c configuring -test-/wait_for_single_fd configuring -test-/win32/console Failed to configure -test-/win32/console. It will not be installed. configuring -test-/win32/dln Failed to configure -test-/win32/dln. It will not be installed. configuring -test-/win32/fd_setsize Failed to configure -test-/win32/fd_setsize. It will not be installed. configuring bigdecimal compiling ./enc/utf_16be.c compiling ./enc/utf_16le.c compiling ./enc/utf_32be.c configuring continuation configuring coverage configuring date compiling ./enc/utf_32le.c compiling ./enc/trans/utf8_mac.c compiling ./enc/trans/utf_16_32.c configuring dbm compiling ./enc/windows_31j.c compiling ./enc/windows_1250.c linking transcoder transdb.bundle linking transcoder chinese.bundle compiling ./enc/windows_1251.c linking transcoder emoji.bundle compiling ./enc/windows_1252.c linking transcoder emoji_iso2022_kddi.bundle linking transcoder emoji_sjis_docomo.bundle linking encoding encdb.bundle linking transcoder emoji_sjis_kddi.bundle linking encoding big5.bundle linking transcoder emoji_sjis_softbank.bundle linking encoding cp949.bundle linking encoding emacs_mule.bundle linking encoding euc_jp.bundle linking encoding euc_kr.bundle linking transcoder escape.bundle linking encoding euc_tw.bundle linking transcoder gb18030.bundle linking encoding gb2312.bundle linking encoding gb18030.bundle linking transcoder gbk.bundle linking encoding gbk.bundle linking transcoder iso2022.bundle linking encoding iso_8859_1.bundle linking encoding iso_8859_2.bundle linking transcoder japanese.bundle linking encoding iso_8859_3.bundle linking transcoder japanese_sjis.bundle linking transcoder single_byte.bundle linking transcoder utf_16_32.bundle linking encoding iso_8859_4.bundle linking transcoder korean.bundle linking encoding iso_8859_5.bundle linking encoding iso_8859_6.bundle linking encoding iso_8859_7.bundle linking encoding iso_8859_8.bundle linking encoding iso_8859_9.bundle linking encoding iso_8859_10.bundle linking encoding iso_8859_11.bundle linking encoding iso_8859_13.bundle linking encoding iso_8859_14.bundle linking encoding iso_8859_15.bundle linking encoding iso_8859_16.bundle linking encoding koi8_r.bundle linking encoding koi8_u.bundle linking encoding shift_jis.bundle linking encoding utf_16be.bundle linking encoding utf_16le.bundle linking encoding utf_32be.bundle linking encoding utf_32le.bundle linking transcoder japanese_euc.bundle linking encoding windows_31j.bundle header: ndbm.h library: libc linking encoding windows_1250.bundle linking encoding windows_1251.bundle linking encoding windows_1252.bundle linking transcoder utf8_mac.bundle linking transcoder big5.bundle making encs configuring digest configuring digest/bubblebabble configuring digest/md5 configuring digest/rmd160 configuring digest/sha1 configuring digest/sha2 configuring etc configuring fcntl configuring fiber configuring fiddle configuring gdbm configuring io/console configuring io/nonblock configuring io/wait configuring json configuring json/generator configuring json/parser configuring mathn/complex configuring mathn/rational configuring nkf configuring objspace configuring openssl Ignore OpenSSL broken by Apple. Please use another openssl. (e.g. using `configure --with-openssl-dir=/path/to/openssl') Failed to configure openssl. It will not be installed. configuring pathname configuring psych configuring pty configuring racc/cparse configuring rbconfig/sizeof configuring readline configuring ripper configuring sdbm configuring socket configuring stringio configuring strscan configuring syslog configuring thread configuring tk ........... check struct members.. check libraries.... Use ActiveTcl libraries (if available). Search tclConfig.sh and tkConfig.sh................................... Fail to find [tclConfig.sh, tkConfig.sh] Use X11 libraries (or use TK_XINCLUDES/TK_XLIBSW information on tkConfig.sh). Search tcl.h. Search tk.h..Search Tcl library..Search Tk library............ Warning:: cannot find Tk library. tcltklib will not be compiled (tcltklib is disabled on your Ruby. That is, Ruby/Tk will not work). Please check configure options. Can't find proper Tcl/Tk libraries. So, can't make tcltklib.so which is required by Ruby/Tk. If you have Tcl/Tk libraries on your environment, you may be able to use them with configure options (see ext/tk/README.tcltklib). At present, Tcl/Tk8.6 is not supported. Although you can try to use Tcl/Tk8.6 with configure options, it will not work correctly. I recommend you to use Tcl/Tk8.5 or 8.4. Failed to configure tk. It will not be installed. Failed to configure tk/tkutil. It will not be installed. configuring win32 Failed to configure win32. It will not be installed. configuring win32ole Failed to configure win32ole. It will not be installed. configuring zlib compiling resize.c compiling bug.c compiling bug.c compiling bug.c compiling bug_reporter.c compiling str2big.c compiling init.c compiling inspector.c compiling class2name.c compiling init.c linking shared-object -test-/bug-3662/bug.bundle linking shared-object -test-/bug_reporter/bug_reporter.bundle linking shared-object -test-/bug-3571/bug.bundle linking shared-object -test-/array/resize.bundle linking shared-object -test-/bug-5832/bug.bundle compiling mul.c compiling profile_frames.c compiling init.c compiling empty.c compiling dataerror.c compiling rb_fatal.c linking shared-object -test-/dln/empty.bundle compiling init.c linking shared-object -test-/class.bundle compiling init.c compiling fs.c linking shared-object -test-/fatal/rb_fatal.bundle linking shared-object -test-/debug.bundle compiling div.c compiling init.c compiling enc_raise.c compiling intpack.c compiling nextafter.c compiling passing_block.c compiling big2str.c compiling stat.c compiling init.c compiling bigzero.c compiling ensured.c linking shared-object -test-/float.bundle linking shared-object -test-/funcall/funcall.bundle compiling iseq_load.c compiling delete.c compiling init.c compiling dot.dot.c linking shared-object -test-/file.bundle compiling break.c linking shared-object -test-/bignum.bundle linking shared-object -test-/exception.bundle linking shared-object -test-/load/dot.dot/dot.dot.bundle compiling yield.c compiling usrcompat.c linking shared-object -test-/iseq_load/iseq_load.bundle linking shared-object -test-/hash.bundle compiling usrmarshal.c compiling init.c compiling num2int.c compiling path_to_class.c compiling arity.c compiling postponed_job.c linking shared-object -test-/iter.bundle compiling printf.c linking shared-object -test-/marshal/compat.bundle linking shared-object -test-/marshal/usr.bundle linking shared-object -test-/path_to_class/path_to_class.bundle compiling super.c linking shared-object -test-/method.bundle linking shared-object -test-/num2int/num2int.bundle compiling receiver.c linking shared-object -test-/postponed_job.bundle compiling rat.c compiling init.c compiling recursion.c compiling foreach.c compiling numhash.c compiling update.c linking shared-object -test-/proc.bundle linking shared-object -test-/printf.bundle linking shared-object -test-/rational.bundle compiling coderange.c linking shared-object -test-/recursion.bundle compiling duplicate.c compiling enc_associate.c compiling init.c linking shared-object -test-/st/update.bundle linking shared-object -test-/st/numhash.bundle compiling init.c linking shared-object -test-/st/foreach.bundle compiling type.c compiling member.c compiling init.c compiling cstr.c compiling tracepoint.c compiling typeddata.c compiling at_exit.c compiling wait_for_single_fd.c compiling gc_hook.c linking shared-object -test-/struct.bundle linking shared-object -test-/typeddata/typeddata.bundle linking shared-object -test-/symbol.bundle compiling qsort.c linking shared-object -test-/vm/at_exit.bundle make[2]: Nothing to be done for `all'. make[2]: Nothing to be done for `all'. make[2]: Nothing to be done for `all'. compiling bigdecimal.c compiling continuation.c compiling nofree.c linking shared-object -test-/wait_for_single_fd/wait_for_single_fd.bundle compiling coverage.c compiling date_parse.c linking shared-object -test-/tracepoint.bundle compiling date_strptime.c linking shared-object continuation.bundle compiling date_core.c installing default bigdecimal libraries compiling ellipsize.c compiling dbm.c linking shared-object coverage.bundle compiling digest.c compiling normalize.c compiling date_strftime.c compiling modify.c linking shared-object digest.bundle linking shared-object dbm.bundle installing digest libraries installing default digest libraries compiling set_len.c compiling bubblebabble.c installing default date_core libraries compiling enc_str_buf_cat.c compiling md5init.c compiling rmd160init.c linking shared-object digest/bubblebabble.bundle compiling sha1init.c linking shared-object -test-/string/string.bundle compiling sha2init.c compiling md5ossl.c generating constant definitions compiling rmd160ossl.c compiling sha1ossl.c compiling etc.c linking shared-object digest/md5.bundle compiling sha2ossl.c linking shared-object digest/rmd160.bundle linking shared-object digest/sha1.bundle compiling fcntl.c compiling fiber.c compiling handle.c installing default sha2 libraries linking shared-object digest/sha2.bundle linking shared-object fiber.bundle linking shared-object fcntl.bundle compiling closure.c linking shared-object etc.bundle compiling pointer.c compiling function.c compiling gdbm.c compiling console.c compiling conversions.c compiling nonblock.c compiling wait.c compiling fiddle.c installing default console libraries linking shared-object io/console.bundle linking shared-object io/nonblock.bundle compiling generator.c linking shared-object io/wait.bundle compiling parser.c linking shared-object fiddle.bundle installing default libraries compiling complex.c compiling rational.c installing default fiddle libraries linking shared-object mathn/complex.bundle linking shared-object mathn/rational.bundle compiling nkf.c installing default nkf libraries linking shared-object gdbm.bundle compiling object_tracing.c compiling objspace.c compiling objspace_dump.c make[2]: Nothing to be done for `all'. compiling pathname.c compiling psych_to_ruby.c linking shared-object objspace.bundle linking shared-object json/ext/parser.bundle compiling psych_yaml_tree.c installing default pathname libraries compiling psych_emitter.c compiling psych.c compiling pty.c compiling cparse.c linking shared-object json/ext/generator.bundle compiling psych_parser.c installing default pty libraries linking shared-object pathname.bundle compiling sizes.c linking shared-object pty.bundle compiling readline.c compiling ripper.c linking shared-object rbconfig/sizeof.bundle linking shared-object bigdecimal.bundle compiling _sdbm.c linking shared-object racc/cparse.bundle generating constant definitions compiling init.c generating constant definitions compiling basicsocket.c linking shared-object psych.bundle installing default psych libraries linking shared-object readline.bundle compiling socket.c compiling ipsocket.c compiling stringio.c compiling strscan.c linking shared-object sdbm.bundle compiling tcpsocket.c compiling syslog.c compiling tcpserver.c compiling thread.c linking shared-object syslog.bundle linking shared-object strscan.bundle compiling sockssocket.c installing default syslog libraries make[2]: Nothing to be done for `all'. compiling udpsocket.c compiling unixsocket.c make[2]: Nothing to be done for `all'. linking shared-object stringio.bundle compiling unixserver.c linking shared-object thread.bundle checking ../.././parse.y and ../.././ext/ripper/eventids2.c make[2]: Nothing to be done for `all'. compiling option.c compiling ancdata.c make[2]: Nothing to be done for `all'. compiling raddrinfo.c compiling zlib.c installing default ripper libraries compiling ifaddr.c installing default socket libraries compiling init.c compiling constants.c linking shared-object socket.bundle linking shared-object nkf.bundle linking shared-object zlib.bundle linking shared-object date_core.bundle linking shared-object ripper.bundle linking shared-library libruby.2.2.0.dylib linking ruby ```

chriso0710 commented 4 years ago

@marsz Took me 2 hours to gain some knowledge about the problem. Your solution worked for me and is the best!

cgatesman commented 4 years ago

Just to contribute a little more information for people. I found that I had both 1.0 and 1.1 in my Homebrew Cellar. I suspect this would be the case for most people if they've been using Homebrew for a while with openssl installed. You can switch back to 1.0:

$ brew switch openssl 1.0.2t
Cleaning /usr/local/Cellar/openssl/1.0.2t
Opt link created for /usr/local/Cellar/openssl/1.0.2t

This solved the problem for me by linking /usr/local/opt/openssl to ../Cellar/openssl/1.0.2t.

I realize this isn't a true fix as it means I'm using an EOL openssl, but for now, it's better than trying to sort out the dependency mess this left.

gulymaestro commented 4 years ago

Here is what worked for me:

brew install rbenv/tap/openssl@1.0
rvm reinstall 1.9.3-p551 --with-openssl-dir='/usr/local/opt/openssl@1.0'
gem update --system

Cheers!

akhan commented 4 years ago

Hello I tried your instructions and below is the result

brew install rbenv/tap/openssl@1.0 Warning: rbenv/tap/openssl@1.0 1.0.2t is already installed and up-to-date To reinstall 1.0.2t, run brew reinstall openssl@1.0 rvm reinstall 2.0.0-p643 --with-openssl-dir='/usr/local/opt/openssl@1.0'

gem update --system Updating rubygems-update ERROR: Error installing rubygems-update: rubygems-update requires Ruby version >= 2.3.0. ERROR: While executing gem ... (NoMethodError) undefined method `version' for nil:NilClass

stevepolitodesign commented 4 years ago

@gulymaestro's solution worked for me, except I was installing 2.3.4 and not 1.9.3-p551.

eraviii commented 3 years ago

Here is what worked for me:

brew install rbenv/tap/openssl@1.0
rvm reinstall 1.9.3-p551 --with-openssl-dir='/usr/local/opt/openssl@1.0'
gem update --system

Cheers!

Hi brew command worked however my machine says rvm cmd not found. Could you guide me on the right path to set.