Added Darwin detection and parameter handling.
Merge pull request #1 from esden/master

Adding Darwin support.