From 3d9573a50c5394adf72f5d797d35081eec39fa4c Mon Sep 17 00:00:00 2001 From: Nils Andreas Svee Date: Sun, 27 Nov 2022 15:15:57 +0100 Subject: [PATCH] jenkinsfile: try to use jenkins function for running executables --- Jenkinsfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 8d80fc2..c77f065 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -26,7 +26,7 @@ pipeline { environment { GCC_TARGET = getGCCTarget(TARGET) CC = "${GCC_TARGET}-gcc" - PATH = "${WORKSPACE}/${GCC_TARGET}-cross:${env.HOME}/.cargo/bin:${env.PATH}" + PATH = "${WORKSPACE}/${GCC_TARGET}-cross/bin:${env.HOME}/.cargo/bin:${env.PATH}" TOOLCHAIN_URL = "https://musl.cc/${GCC_TARGET}-cross.tgz" } @@ -34,9 +34,9 @@ pipeline { stage('Download GCC toolchain') { when { expression { - def process = "${GCC_TARGET}-gcc".execute() + def res = sh(script: "${GCC_TARGET}-gcc", returnStatus: true) - if (process.exitValue() > 0) { + if (res > 0) { return false } else { return true