[build] detect darwin platform correctly
Merge pull request #16 from Chilledheart/patch-2

[build] detect darwin platform correctly