Makefile

I added a Makefile for people not using Xcode to compile the code. I tested it both on linux and mac. Also fixed the ifdef to conform to the rest of the code.