In a pinch, I succeded in compiling just changing in: /usr/include/thrift/protocol/TBinaryProtocol.h
static const int32_t VERSION_MASK = 0xffff0000; static const int32_t VERSION_1 = 0x80010000; to static const uint32_t VERSION_MASK = 0xffff0000; static const uint32_t VERSION_1 = 0x80010000; Seeing this bug http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49896 as pointed by Matthieu, i assumed the problem is related to an issue in int overflowing management. I have not tested it in a any extensive way, just compiled and ran my code, but maybe it could be an useful clue
