more compile fixes for Mac/Clang