In OSX 10.10 Yosemite the


header file contains code that can be processed by clang but not GCC. The specific error that GCC 4.9 (via homebrew) produces is:

/usr/include/dispatch/object.h:143:15: error: expected unqualified-id before '^' token
 typedef void (^dispatch_block_t)(void);
/usr/include/dispatch/object.h:143:15: error: expected ')' before '^' token
/usr/include/dispatch/object.h:362:3: error: 'dispatch_block_t' has not been declared
   dispatch_block_t notification_block);

The fix:

typedef void (^dispatch_block_t)(void);
typedef void* dispatch_block_t;

Similarly if using Xcode, the file is located at:

/Applications/ dispatch/object.h