On some machines, installing Ruby 1.8.7 with ruby-build can lead to this error:
math.c:37:13: error: missing binary operator before token "("
Your development team has a full backlog? No time for infrastructure architecture? Our DevOps team is ready to support you!
Try instead to install ruby-1.8.7-p374.
ruby-1.8.7-p374