From 0c2e66e41483ad73c32abd929c32ec34688bf462 Mon Sep 17 00:00:00 2001 From: "marcin.mirski" Date: Thu, 5 Jun 2025 11:48:03 -0700 Subject: [PATCH] Improve CMAKE_BUILD_PARALLEL_LEVEL message --- cmake/godotcpp.cmake | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/cmake/godotcpp.cmake b/cmake/godotcpp.cmake index f0dbba62..a0c544fc 100644 --- a/cmake/godotcpp.cmake +++ b/cmake/godotcpp.cmake @@ -200,10 +200,15 @@ function(godotcpp_generate) message(STATUS "Using ${PROC_N} cores for multi-threaded compilation.") # TODO You can override it at configure time with ...." ) else() + if(CMAKE_BUILD_PARALLEL_LEVEL) + set(_cores "${CMAKE_BUILD_PARALLEL_LEVEL}") + else() + set(_cores "all") + endif() message( STATUS - "Using ${CMAKE_BUILD_PARALLEL_LEVEL} cores, You can override" - " it at configure time by using -j or --parallel on the build" + "Using ${_cores} cores. You can override" + " this at configure time by using -j or --parallel in the build" " command." ) message(STATUS " eg. cmake --build . -j 7 ...")