CMake 输出所有的编译过程

来源:互联网 发布:适合mac用的办公软件 编辑:程序博客网 时间:2024/06/05 09:17

CMake has a nice colored output which hides the commandline. This is pretty to look at in the long run but sometimes when you write your configurations you want to know if you got all the compiler flags right. There is two ways to disable the pretty output, well, it's essentially the same but still two different ways.

The first way is to simply run make with the additional argument "VERBOSE=1". This will show each command being run for this session, which is the most useful way to see if the flags is correct.

Code: 
  1. % make VERBOSE=1

The second way is to permanently disable the pretty output in your CMakeLists.txt by setting CMAKE_VERBOSE_MAKEFILE.

Code: CMakeLists.txt
  1.  set( CMAKE_VERBOSE_MAKEFILE on )
0 0
原创粉丝点击