I 'm glad you solved your problem and posted the solution.
In the future, when you 're asking for help on compilation issues, it 'll be better to post the full build log. This way, people wanting to help you, can spot the problem easier...
To enable full build logging, go to "Settings/Configure plugins/Compiler", switch to the "Other" tab and select full logging.
Yiannis.