On Thu, 8 Oct 2009, Dr. David Kirkby wrote:
I want a user to set environment variables CC and CXX and point them to C and C++ compilers. I want to check that they are in fact C and C++ compilers, and that CC does not point to a C++ compiler, and CXX does not point to a C compiler.
Just test if it defines __cplusplus. Bonus: it works the same for any compiler.
-- Marc Glisse