Added IFDEF around main to avoid duplicate symbols when consuming project has -all_load flag set