support MacOS
use 'else ifeq'
Merge pull request #5 from handlename/master

support MacOS