minor changes to allow compiling on Xcode 5 using the apple llvm compiler