Fix clang warnings related to python macro redefinition and printf format specifiers.