Undefined symbols for architecture i386: _OBJC_CLASS_$_SKPSMTPMessage", referenced from: error
You can get this type of error if your class' .m file is not listed under the "Compile Sources" step of the "Build Phases" tab of your target. Normally Xcode does this for you, but sometimes it loses the plot and you need to add the .m file manually.
To do this:
TargetSettings -> Build Phases -> Compile Sources -> add your .m class ->Build and Run
for me the issue turned out to be missing frameworks. Once I added em, it worked.
Check the Valid Architectures & Build Active Architecture only properties.