diff --git a/jenkins-scripts/docker/gz-source-generation.bash b/jenkins-scripts/docker/gz-source-generation.bash index fefa7db9e..72a3a4583 100644 --- a/jenkins-scripts/docker/gz-source-generation.bash +++ b/jenkins-scripts/docker/gz-source-generation.bash @@ -16,6 +16,10 @@ PKG_DIR=\$WORKSPACE/pkgs SOURCES_DIR=\$WORKSPACE/sources BUILD_DIR=\$SOURCES_DIR/build +# Need to intall all supported gz-cmake* packages in the platform +(apt-get install -y *gz-cmake* || apt-get install -y *ign-cmake*) || \ + (echo "Can not find any ign-cmake/gz-cmake package" && exit 1) + cd \${WORKSPACE} rm -fr \$SOURCES_DIR && mkdir \$SOURCES_DIR git clone --depth 1 --branch ${PACKAGE}_${VERSION/\~/-} ${SOURCE_REPO_URI} \${SOURCES_DIR} diff --git a/jenkins-scripts/dsl/_configs_/OSRFSourceCreation.groovy b/jenkins-scripts/dsl/_configs_/OSRFSourceCreation.groovy index 552336e8b..0eb6f3e2b 100644 --- a/jenkins-scripts/dsl/_configs_/OSRFSourceCreation.groovy +++ b/jenkins-scripts/dsl/_configs_/OSRFSourceCreation.groovy @@ -36,6 +36,13 @@ class OSRFSourceCreation stringParam("EXTRA_OSRF_REPO", default_params.find{ it.key == "EXTRA_OSRF_REPO"}?.value, "For downstream jobs: OSRF extra repositories to add") + stringParam("LINUX_DISTRO", + 'ubuntu', + default_params.find{ it.key == "LINUX_DISTRO"}?.value, + "Linux distribution to use to generate sources") + stringParam("DISTRO", + default_params.find{ it.key == "DISTRO"}?.value, + "Linux release inside LINUX_DISTRO to generate sources on") } } } @@ -78,10 +85,7 @@ class OSRFSourceCreation shell("""\ #!/bin/bash -xe - # Use Jammy/amd64 as base image to generate sources - export DISTRO=jammy export ARCH=amd64 - /bin/bash -x ./scripts/jenkins-scripts/docker/gz-source-generation.bash """.stripIndent() )