I don't know Qt 3 but it looks like you are missing the header with the Q_OBJECT definition. The (internal?) header qobjectdefs.h is not included by any of your includes.