define pthread macro for ERRORCHECK type