title: Can't install ruby 1.8.7 Mac OS X Sierra
body: <p>I'm trying to (re-)install ruby 1.8.7 using rvm 1.29.1 on a brand new MBP running OS X Sierra. I <em>HAVE</em> to get this done for work, I'm not in a position to switch to a more current version or anything unfortunately. </p>
  
  <p>I had a functional install of this but after getting some weird errors in a project decided to try a completely clean reinstall of both rvm (and eventually homebrew!) (long story- had a broken file structure after removing an unwanted space from the name of my home directory!). I was careful to remove all traces of the old install from .bashrc, .profile etc following other posts on here. 2.4.0 installs and runs fine. However, on trying to install 1.8.7:</p>
  
  <pre><code>9bxbniv1:~ Rob$ rvm install ruby-1.8.7
  
  Warning! Requested ruby installation which requires another ruby available - installing ruby-1.8.7-p374 first.
  
  ruby-1.8.7-p374 - #removing src/ruby-1.8.7-p374..
  Checking requirements for osx.
  Certificates in '/usr/local/etc/openssl@1.1/cert.pem' are already up to date.
  Requirements installation successful.
  Installing Ruby from source to: /Users/Rob/.rvm/rubies/ruby-1.8.7-p374, this may take a while depending on your cpu(s)...
  ruby-1.8.7-p374 - #downloading ruby-1.8.7-p374, this may take a while depending on your connection...
  ruby-1.8.7-p374 - #extracting ruby-1.8.7-p374 to /Users/Rob/.rvm/src/ruby-1.8.7-p374....
  ruby-1.8.7-p374 - #applying patch /Users/Rob/.rvm/patches/ruby/1.8.7/stdout-rouge-fix.patch.
  ruby-1.8.7-p374 - #applying patch /Users/Rob/.rvm/patches/ruby/1.8.7/no_sslv2.diff.
  ruby-1.8.7-p374 - #applying patch /Users/Rob/.rvm/patches/ruby/GH-488.patch.
  ruby-1.8.7-p374 - #applying patch /Users/Rob/.rvm/patches/ruby/ssl_no_ec2m.patch.
  ruby-1.8.7-p374 - #configuring...............................
  ruby-1.8.7-p374 - #post-configuration.
  ruby-1.8.7-p374 - #compiling................................
  Error running '__rvm_make -j 1',
  showing last 15 lines of /Users/Rob/.rvm/log/1488471654_ruby-1.8.7-p374/make.log
                              ^
  openssl_missing.c:107:28: error: dereferencing pointer to incomplete type
       EVP_MD_CTX_cleanup(&amp;ctx-&gt;o_ctx);
                              ^
  openssl_missing.c:108:28: error: dereferencing pointer to incomplete type
       EVP_MD_CTX_cleanup(&amp;ctx-&gt;md_ctx);
                              ^
  In file included from /usr/include/string.h:192:0,
                   from openssl_missing.c:19:
  openssl_missing.c:109:27: error: invalid application of 'sizeof' to incomplete type 'HMAC_CTX'
       memset(ctx, 0, sizeof(HMAC_CTX));
                             ^
  make[1]: *** [openssl_missing.o] Error 1
  make: *** [all] Error 1
  +++ return 2
  There has been an error while running make. Halting the installation.
  
  To proceed rvm requires a ruby-1.8.7-p374 compatible ruby is installed.
  We attempted to install it automatically but it failed with status 2.
  Please install it manually (or a compatible alternative) to proceed.
  </code></pre>
  
  <p>I have tried some of the hacks suggested in <a href="https://stackoverflow.com/questions/12469530/getting-ruby-1-8-7-installed-on-mountain-lion-10-8?noredirect=1&amp;lq=1">Getting Ruby 1.8.7 installed on Mountain Lion (10.8)</a> but unfortunately that didn't help. 
  Looking further into the log file the error begins with the following message:</p>
  
  <pre><code>In file included from openssl_missing.c:22:0:
  openssl_missing.h:79:35: error: macro "EVP_MD_CTX_create" passed 1 arguments, but takes just 0
   EVP_MD_CTX *EVP_MD_CTX_create(void);
                                     ^
  In file included from /usr/local/opt/openssl@1.1/include/openssl/x509.h:23:0,
                   from /usr/local/opt/openssl@1.1/include/openssl/x509_vfy.h:17,
                   from openssl_missing.c:16:
  /usr/local/opt/openssl@1.1/include/openssl/evp.h:501:51: error: expected declaration specifiers or '...' before '(' token
   # define EVP_MD_CTX_init(ctx)    EVP_MD_CTX_reset((ctx))
  </code></pre>
  
  <p>Searching for the first line of this error returned 0 results on here. Suggestions would be gratefully received.</p>