diff --git a/CMakeLists.txt b/CMakeLists.txt index 1d0890831d..0eea5faf42 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -161,8 +161,13 @@ else() WORKING_DIRECTORY ${jemalloc_targ_SOURCE_DIR} OUTPUT ${jemalloc_targ_SOURCE_DIR}/Makefile DEPENDS ${jemalloc_targ_SOURCE_DIR}/configure) + + if(NOT UMF_QEMU_BUILD) + set(MAKE_ARGUMENTS "-j$(nproc)") + endif() + add_custom_command( - COMMAND make + COMMAND make ${MAKE_ARGUMENTS} WORKING_DIRECTORY ${jemalloc_targ_SOURCE_DIR} OUTPUT ${jemalloc_targ_SOURCE_DIR}/lib/libjemalloc.a DEPENDS ${jemalloc_targ_SOURCE_DIR}/Makefile) diff --git a/scripts/qemu/run-build.sh b/scripts/qemu/run-build.sh index b0f4bee1e5..c6314153c6 100755 --- a/scripts/qemu/run-build.sh +++ b/scripts/qemu/run-build.sh @@ -21,6 +21,7 @@ cd build cmake .. \ -DCMAKE_BUILD_TYPE=Debug \ + -DUMF_QEMU_BUILD=1 \ -DUMF_BUILD_LEVEL_ZERO_PROVIDER=ON \ -DUMF_BUILD_CUDA_PROVIDER=ON \ -DUMF_FORMAT_CODE_STYLE=OFF \