cmake --build . --config Release
是否可以设置构建过程使用的核心数量?
我正在寻找类似于 GNU make 的 -j
选项的内容。
最佳答案
根据Release Notes ,使用 CMake 3.12 可以跨平台完成:
The
cmake(1)
Build Tool Mode (cmake –build
) gained--parallel [<jobs>]
and-j [<jobs>]
options to specify a parallel build level. They map to corresponding options of the native build tool.
关于cmake - 设置 CMake 构建中的线程数,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36633074/