honour option to disable cocoa

As the variable is set to 1 to enable and 0 to disable it will always
be defined.
Merge pull request #93 from keis/optional-cocoa

honour option to disable cocoa