Use uname command to detect Darwin platform
Merge pull request #680 from Chilledheart/detect_darwin_correctly

Use uname command to detect Darwin platform