Change how R_HOME is set. Solve issue 97.