]> git.ipfire.org Git - thirdparty/ccache.git/commitdiff
chore: Fix build parallelism in ci/build again
authorJoel Rosdahl <joel@rosdahl.net>
Sun, 17 Mar 2024 14:55:19 +0000 (15:55 +0100)
committerJoel Rosdahl <joel@rosdahl.net>
Sun, 24 Mar 2024 08:32:12 +0000 (09:32 +0100)
The -j option was removed in 39dcc7488159e6812292ecbd15a1ed25ade493a2,
but that means that builds using make will be serial. Thus add the
option again.

ci/build

index 9001bfbda0cfbc65a48552d5ea9a34f4655cce26..4ed04ebb9aab1d768cb95ebfcde038446b83acbc 100755 (executable)
--- a/ci/build
+++ b/ci/build
@@ -26,12 +26,12 @@ else
     cd "${BUILDDIR}"
     ${CMAKE_PREFIX} cmake ${CMAKE_PARAMS} ${CCACHE_LOC}
 
-    case "${CMAKE_GENERATOR}" in
+    case "${CMAKE_GENERATOR:-}" in
         [Vv]isual" "[Ss]tudio*) # MSBuild, use all CPUs.
             ${CMAKE_PREFIX} cmake --build . ${EXTRA_CMAKE_BUILD_FLAGS} -- -m
             ;;
-        *) # Ninja automatically uses all available CPUs.
-            ${CMAKE_PREFIX} cmake --build . ${EXTRA_CMAKE_BUILD_FLAGS}
+        *)
+            ${CMAKE_PREFIX} cmake --build . ${EXTRA_CMAKE_BUILD_FLAGS} -- -j "${JOBS}"
             ;;
     esac