improve build for mac.
Merge pull request #21 from rydotyosh/improveBuildForMac_PR

improve build for mac.