Fix builds on osx (and elsewhere?)

Set a global variable with the CXXFLAGS so that the make file generating code can see it.
This is mimicking what the code already does for the LDFLAGS and it works for me.

Without this the make file would not be informed of the `-std=c++11` flag set in my env.