How cmake checks the working compiler

when using cmake, I noticed output messages:

- C compiler id is GNU

- CXX compiler ID is GNU

- Check the compiler C: / usr / bin / gcc

- Verify that the C compiler is working: / usr / bin / gcc - works

- Detection of C ABI Compiler Information

- Compiler detection C ABI info - done

- Check the operation of the CXX compiler: / usr / bin / C ++

- Check the performance of the CXX compiler: / usr / bin / C ++ - works

- CXX ABI info compiler detection

- CXX ABI compiler discovery info - done

I'm just wondering how cmake checks to see if the compiler and ABI info are working.

Any answer is welcome!

From Duan 
+6
source share
1 answer

You can easily see for yourself. The code is located in the CMake modules CMakeDetermineCCompiler.cmake , CMakeDetermineCompilerABI.cmake , etc.

You can find these modules in your_cmake_install/share/cmake-2.8/Modules .

+8
source

All Articles