Only give g++ flags to compatible compilers