Modified for compiling on cm10.1