Fix build/install issues

I have barely any idea what I'm doing with this C stuff, but I've incorporated fixes from the open PRs and used nan's docs to update it and fix for its latest API.

My fork installs well, does not throw errors on `npm rebuild` on non-mac systems, and passes chokidar's tests. The fsevents tests perform as well as they did before, with 1 failed test.

There are increasing reports of the error message described in #33, and it's confusing a lot of people trying to use brunch, karma, etc. 

@pipobscure Please indicate whether you intend to merge and publish the fixes in this PR (or equivalent fixes, as I've applied these changes rather naively and as far as I know there are better ways). If I don't hear anything within a few days, I plan to publish my fork to npm and switch chokidar to it for the benefit of all its users/dependents.