A number of small fixes that were required to successfully build rc2 on OSX

(cherry picked from commit e71818ad4056c42022317520c61093028d86ffab)
The actual configuration used to build RC2

(cherry picked from commit 8c11f1cb45354f215713d5c0f7d0fc776f3a50b4)