【CMAKE系列】CMAKE外部工程引用及编译打印

tech2025-06-15  2

0.入门教程

CMAKE实践 参考网址:https://www.kancloud.cn/itfanr/cmake-practice/82983

1. ExternalProject 的使用

官网:https://cmake.org/cmake/help/v3.0/module/ExternalProject.html 参考网址:https://www.jianshu.com/p/ea7eafd7165c

2. enable_testing 的使用

官网: https://cmake.org/cmake/help/latest/command/enable_testing.html 参考网址:https://www.oschina.net/question/234345_52720?sort=time

3. CMake 编译过程打印

Code: % 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 set( CMAKE_VERBOSE_MAKEFILE on )

or Windows

cmake -DCMAKE_VERBOSE_MAKEFILE=ON -G"Visual Studio 15" ../../ cmake --build . --config Release -- /verbosity:detailed

参考网址1:https://sidvind.com/wiki/CMake/Verbose_output 参考网址2:https://stackoverflow.com/questions/47676199/how-to-build-with-cmake-to-both-release-config-and-verbose

cmake windows参数:https://www.brianlheim.com/2018/04/09/cmake-cheat-sheet.html

最新回复(0)