fixed compiler flags for MacOS