Skip to content

Commit 018a43d

Browse files
committed
[Build] Stash jdk-resources with respect to WS to prevent gtk conflicts
For linux.x86_64 the jdk-resources for gtk(3) and gtk4 are downloaded, stashed and deleted into/from the same directory. This leads to concurrency issues and build failures.
1 parent 0f466b3 commit 018a43d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Jenkinsfile

+3-3
Original file line numberDiff line numberDiff line change
@@ -238,18 +238,18 @@ pipeline {
238238
steps {
239239
script {
240240
def (ws, os, arch) = env.PLATFORM.split('\\.')
241-
dir("jdk-download-${os}.${arch}") {
241+
dir("jdk-download-${ws}.${arch}") {
242242
// Fetch the JDK, which provides the C header-files and shared native libraries, against which the natives are build.
243243
sh "curl ${getNativeJdkUrl(os, arch)} | tar -xzf - include/ lib/"
244-
stash name:"jdk.resources.${os}.${arch}", includes: "include/,lib/"
244+
stash name:"jdk.resources.${ws}.${arch}", includes: "include/,lib/"
245245
deleteDir()
246246
}
247247
runOnNativeBuildAgent("${PLATFORM}") {
248248
cleanWs() // Workspace is not cleaned up by default, so we do it explicitly
249249
echo "OS: ${os}, ARCH: ${arch}"
250250
unstash "swt.binaries.sources.${ws == 'gtk4' ? 'gtk' : ws }"
251251
dir('jdk.resources') {
252-
unstash "jdk.resources.${os}.${arch}"
252+
unstash "jdk.resources.${ws}.${arch}"
253253
}
254254
withEnv(['MODEL=' + arch, "OUTPUT_DIR=${WORKSPACE}/libs", "SWT_JAVA_HOME=${WORKSPACE}/jdk.resources"]) {
255255
if (isUnix()) {

0 commit comments

Comments
 (0)