windows-build: Use number of processors
Extract number of processors using `nproc` command and use it to set Makeflags and git submodules jobs. Signed-off-by: markoburcul <marko@status.im>
This commit is contained in:
parent
99a209635b
commit
14b326fbf8
3
Makefile
3
Makefile
|
@ -50,7 +50,8 @@ BUILD_SYSTEM_DIR := vendor/nimbus-build-system
|
|||
|
||||
ifeq ($(NIM_PARAMS),)
|
||||
# "variables.mk" was not included, so we update the submodules.
|
||||
GIT_SUBMODULE_UPDATE := git submodule update --init --recursive
|
||||
NUMPROC ?= 10
|
||||
GIT_SUBMODULE_UPDATE := git submodule update --init --recursive --jobs $(NUMPROC)
|
||||
.DEFAULT:
|
||||
+@ echo -e "Git submodules not found. Running '$(GIT_SUBMODULE_UPDATE)'.\n"; \
|
||||
$(GIT_SUBMODULE_UPDATE); \
|
||||
|
|
|
@ -5,7 +5,7 @@ library 'status-jenkins-lib@v1.9.7'
|
|||
def isPRBuild = utils.isPRBuild()
|
||||
|
||||
pipeline {
|
||||
agent { label 'windows && x86_64 && qt-5.15.2 && go-1.21' }
|
||||
agent { label 'windows && x86_64 && qt-5.15.2 && go-1.21 && win-04' }
|
||||
|
||||
parameters {
|
||||
booleanParam(
|
||||
|
@ -66,8 +66,10 @@ pipeline {
|
|||
|
||||
environment {
|
||||
PLATFORM = "windows/${getArch()}"
|
||||
/* Number of processors on the host*/
|
||||
NUMPROC = "${sh(script: 'nproc', returnStdout: true).trim()}"
|
||||
/* Improve make performance */
|
||||
MAKEFLAGS = "-j${utils.getProcCount()} V=${params.VERBOSE}"
|
||||
MAKEFLAGS = "-j${env.NUMPROC} V=${params.VERBOSE}"
|
||||
/* Explicitly set the QT version */
|
||||
QTDIR = "/c/Qt/5.15.2/msvc2019_64"
|
||||
PATH = "${env.QTDIR}/bin:${env.PATH}"
|
||||
|
|
Loading…
Reference in New Issue