On MacOS Big Sur - installing Ruby 2.6.7 may fail during the compilation step. Here is the snippet I used to ensure it compiles and installs.