Avoid hardcoding compiler/flags

Ref. https://github.com/Homebrew/homebrew/pull/28443.
Merge pull request #8 from mathiasbynens/makefile-tweaks

Avoid hardcoding compiler/flags