jjb: integration: move amd64 jobs to deb12
authorMichael Jeanson <mjeanson@efficios.com>
Wed, 16 Aug 2023 18:21:10 +0000 (14:21 -0400)
committerMichael Jeanson <mjeanson@efficios.com>
Wed, 16 Aug 2023 20:17:15 +0000 (16:17 -0400)
Change-Id: I5f51f0e353725962c9a40680de15cf7f977cd97c
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
jobs/integration.yaml
pipelines/integration/lttng-tools-_version_-32-64_testsuite.groovy.inc
scripts/integration/32-64/build.sh

index fb4cd90f1b80a4c09e27c01cf5f6cc37430cf91e..323dd16cdbdb6cda465534636aa043f0ec9103e9 100644 (file)
     project-type: freestyle
     concurrent: true
     node: 'amd64-rootnode'
+
+    properties:
+      - build-discarder:
+          days-to-keep: 2
+
     wrappers:
       - workspace-cleanup
       - timestamps
@@ -27,6 +32,7 @@
           timeout: 6
           fail: true
           type: no-activity
+
     parameters:
         - string:
             name: 'ARTIFACT_ID'
                     - 32bit-relayd
                     - 32bit-cli
                     - canary
+
     builders:
       - copyartifact:
-          project: 'babeltrace_${BT_VERSION}_build/platform=bionic-amd64,conf=std,build=std'
+          project: 'babeltrace_${BT_VERSION}_linuxbuild/platform=deb12-amd64,conf=std,build=std'
           which-build: last-successful
           stable: false
           filter: 'build/**'
           target: 'deps-64'
           do-not-fingerprint: true
       - shell:
-          !include-raw-escape: scripts/integration/32-64/build.sh
+          !include-raw: scripts/integration/32-64/build.sh
+
     publishers:
       - postbuildscript:
           mark-unstable-if-failed: true
index c6490d314347bedd2c2db5313cb4c9beda875be3..8d64bf50d31e1ca53fb3cc095596c7e410829abb 100644 (file)
@@ -32,7 +32,7 @@ pipeline {
                 * have this guarantee since we used 2 different jobs
                 */
                stage('Checkout all sources') {
-                       agent { label 'bionic-amd64' }
+                       agent { label 'deb12-amd64' }
                        steps {
                                dir("src/userspace-rcu") {
                                        checkout([$class: 'GitSCM', branches: [[name: '{{ urcu_version }}']], extensions: [], gitTool: 'Default', userRemoteConfigs: [[url: 'https://github.com/urcu/userspace-rcu']]])
@@ -53,9 +53,10 @@ pipeline {
                }
 
                stage('Build') {
+                       /* Build the i386 and amd64 artifacts in parallel */
                        parallel {
                                stage('Build amd64 deps') {
-                                       agent { label 'bionic-amd64' }
+                                       agent { label 'deb12-amd64' }
                                        stages {
                                                stage('Clean workspace') {
                                                        steps {
@@ -101,10 +102,10 @@ pipeline {
                                                                        '''
                                                                }
 
-                                                               /* Move the artifact of the recently build project to the deps file and remove the "build" directory to prevent `make install` shenanigans for lttng-ust 2.12 */
+                                                               /* Move the artifacts of the recently built project to the deps directory and remove the "build" directory to prevent `make install` shenanigans for lttng-ust 2.12 */
                                                                sh '''
                                                                        cp -rv build/ $BASEDIR_64
-                                                                       rm -rv build/
+                                                                       rm -rvf build/
                                                                '''
 
                                                                dir("src/lttng-ust") {
@@ -121,10 +122,10 @@ pipeline {
                                                                        '''
                                                                }
 
-                                                               /* Move the artifact of the recently build project to the deps file and remove the "build" directory to prevent `make install` shenanigans for lttng-ust 2.12 */
+                                                               /* Move the artifacts of the recently built project to the deps directory and remove the "build" directory to prevent `make install` shenanigans for lttng-ust 2.12 */
                                                                sh '''
                                                                        cp -rv build/ $BASEDIR_64
-                                                                       rm -rv build/
+                                                                       rm -rvf build/
                                                                '''
 
                                                                stash name: "amd64-deps-lttng-tools", includes: 'deps-64/**'
@@ -133,7 +134,7 @@ pipeline {
                                        }
                                }
                                stage('Build i386, including lttng-tools') {
-                                       agent { label 'bionic-i386' }
+                                       agent { label 'deb12-i386' }
                                        stages {
                                                stage('Clean workspace') {
                                                        steps {
@@ -176,10 +177,10 @@ pipeline {
                                                                        '''
                                                                }
 
-                                                               /* Move the artifact of the recently build project to the deps file and remove the "build" directory to prevent `make install` shenanigans for lttng-ust 2.12 */
+                                                               /* Move the artifacts of the recently built project to the deps directory and remove the "build" directory to prevent `make install` shenanigans for lttng-ust 2.12 */
                                                                sh '''
                                                                        cp -rv build/ $BASEDIR_32
-                                                                       rm -rv build/
+                                                                       rm -rvf build/
                                                                '''
 
 
@@ -197,10 +198,10 @@ pipeline {
                                                                        '''
                                                                }
 
-                                                               /* Move the artifact of the recently build project to the deps file and remove the "build" directory to prevent `make install` shenanigans for lttng-ust 2.12 */
+                                                               /* Move the artifacts of the recently built project to the deps directory and remove the "build" directory to prevent `make install` shenanigans for lttng-ust 2.12 */
                                                                sh '''
                                                                        cp -rv build/ $BASEDIR_32
-                                                                       rm -rv build/
+                                                                       rm -rvf build/
                                                                '''
 
                                                                dir("src/lttng-tools") {
@@ -217,10 +218,10 @@ pipeline {
                                                                        '''
                                                                }
 
-                                                               /* Move the artifact of the recently build project to the deps file and remove the "build" directory to prevent `make install` shenanigans for lttng-ust 2.12 */
+                                                               /* Move the artifacts of the recently built project to the deps directory and remove the "build" directory to prevent `make install` shenanigans for lttng-ust 2.12 */
                                                                sh '''
                                                                        cp -rv build/ $BASEDIR_32
-                                                                       rm -rv build/
+                                                                       rm -rvf build/
                                                                '''
 
                                                                stash name: "i386-deps-lttng-tools", includes: 'deps-32/**'
@@ -236,7 +237,7 @@ pipeline {
                        }
                }
                stage('Object store') {
-                       agent { label 'bionic-amd64' }
+                       agent { label 'deb12-amd64' }
                        environment {
                                S3_PREFIX = "s3://jenkins/32-64-bit-integration"
                        }
index 36dce9ebce332fd6f8e6e0b7090499394d876087..1e329c7e0c6f6cfb7e0b452849d3822cedded38f 100644 (file)
@@ -2,6 +2,7 @@
 # shellcheck disable=SC2103
 #
 # Copyright (C) 2022 Jonathan Rajotte-Julien <jonathan.rajotte-julien@efficios.com>
+# Copyright (C) 2023 Michael Jeanson <mjeanson@efficios.com>
 #
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -20,6 +21,8 @@ set -eux
 
 BASEDIR_64="$WORKSPACE/deps-64/build"
 BASEDIR_32="$WORKSPACE/deps-32/build"
+PREFIX="/build"
+
 export CPPFLAGS="-I$BASEDIR_64/include"
 export LDFLAGS="-L$BASEDIR_64/lib"
 export CFLAGS="-g -O0"
@@ -27,19 +30,33 @@ export CXXFLAGS="-g -O0"
 export PKG_CONFIG_PATH="$BASEDIR_64/lib/pkgconfig"
 export LD_LIBRARY_PATH="$BASEDIR_64/lib:$BASEDIR_32/lib"
 export PATH="$PATH:$BASEDIR_64/bin"
+
 export BABELTRACE_PLUGIN_PATH="$BASEDIR_64/lib/babeltrace2/plugins/"
 export LIBBABELTRACE2_PLUGIN_PROVIDER_DIR="$BASEDIR_64/lib/babeltrace2/plugin-providers/"
-PREFIX="/build"
+
 export JAVA_HOME="/usr/lib/jvm/default-java"
 DEPS_JAVA="$WORKSPACE/deps-64/build/share/java"
 export CLASSPATH="$DEPS_JAVA/lttng-ust-agent-all.jar:/usr/share/java/log4j-api.jar:/usr/share/java/log4j-core.jar:/usr/share/java/log4j-1.2.jar"
+
 export PYTHON2="python2"
 export PYTHON3="python3"
-P2_VERSION=$($PYTHON2 -c "import sys;print(sys.version[:3])")
-P3_VERSION=$($PYTHON3 -c "import sys;print(sys.version[:3])")
-DEPS_PYTHON2="$WORKSPACE/deps-64/build/lib/python$P2_VERSION/site-packages"
+
+if command -v $PYTHON2 >/dev/null 2>&1; then
+    P2_VERSION=$($PYTHON2 -c 'import sys;v = sys.version.split()[0].split("."); print("{}.{}".format(v[0], v[1]))')
+    DEPS_PYTHON2="$WORKSPACE/deps/build/lib/python$P2_VERSION/site-packages"
+
+    PYTHON_TEST_ARG="--enable-test-python-agent-all"
+else
+    PYTHON_TEST_ARG="--enable-test-python3-agent"
+fi
+
+P3_VERSION=$($PYTHON3 -c 'import sys;v = sys.version.split()[0].split("."); print("{}.{}".format(v[0], v[1]))')
 DEPS_PYTHON3="$WORKSPACE/deps-64/build/lib/python$P3_VERSION/site-packages"
-export PYTHONPATH="$DEPS_PYTHON2:$DEPS_PYTHON3"
+
+# Most build configs require access to the babeltrace 2 python bindings.
+# This also makes the lttngust python agent available for `agents` builds.
+export PYTHONPATH="${DEPS_PYTHON2:-}${DEPS_PYTHON2:+:}$DEPS_PYTHON3"
+
 export LTTNG_CONSUMERD32_BIN="$BASEDIR_32/lib/lttng/libexec/lttng-consumerd"
 export LTTNG_CONSUMERD32_LIBDIR="$BASEDIR_32/lib"
 export LTTNG_CONSUMERD64_BIN="$BASEDIR_64/lib/lttng/libexec/lttng-consumerd"
@@ -80,7 +97,7 @@ popd
 pushd src/lttng-tools
 
 ./bootstrap
-./configure --prefix="$PREFIX" --enable-test-java-agent-all --enable-test-python-agent-all
+./configure --prefix="$PREFIX" --enable-test-java-agent-all $PYTHON_TEST_ARG
 popd
 
 # Deativate health test, simply because there is little value for this integration testing
This page took 0.028047 seconds and 4 git commands to generate.