From 547386f9180687627ce506cab0cacc91ed808025 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bob=20Dr=C3=B6ge?= Date: Wed, 27 Mar 2024 10:08:14 +0100 Subject: [PATCH 01/10] dont fail if grep doesnt find rebuild easystack files --- bot/build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bot/build.sh b/bot/build.sh index b007b80172..2438adbcd9 100755 --- a/bot/build.sh +++ b/bot/build.sh @@ -182,7 +182,7 @@ fi # determine if the removal step has to be run # assume there's only one diff file that corresponds to the PR patch file pr_diff=$(ls [0-9]*.diff | head -1) -changed_easystacks_rebuilds=$(cat ${pr_diff} | grep '^+++' | cut -f2 -d' ' | sed 's@^[a-z]/@@g' | grep '^easystacks/.*yml$' | grep "/rebuilds/") +changed_easystacks_rebuilds=$(cat ${pr_diff} | grep '^+++' | cut -f2 -d' ' | sed 's@^[a-z]/@@g' | grep '^easystacks/.*yml$' | grep "/rebuilds/" || true) if [[ -z ${changed_easystacks_rebuilds} ]]; then echo "This PR does not add any easystack files in a rebuilds subdirectory, so let's skip the removal step." else From c2fad0032008d0ca73f6603ad7fbae6c2391a6a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bob=20Dr=C3=B6ge?= Date: Wed, 27 Mar 2024 10:08:32 +0100 Subject: [PATCH 02/10] add quotes around variable in if statement --- bot/build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bot/build.sh b/bot/build.sh index 2438adbcd9..e9f8ecfbb9 100755 --- a/bot/build.sh +++ b/bot/build.sh @@ -183,7 +183,7 @@ fi # assume there's only one diff file that corresponds to the PR patch file pr_diff=$(ls [0-9]*.diff | head -1) changed_easystacks_rebuilds=$(cat ${pr_diff} | grep '^+++' | cut -f2 -d' ' | sed 's@^[a-z]/@@g' | grep '^easystacks/.*yml$' | grep "/rebuilds/" || true) -if [[ -z ${changed_easystacks_rebuilds} ]]; then +if [[ -z "${changed_easystacks_rebuilds}" ]]; then echo "This PR does not add any easystack files in a rebuilds subdirectory, so let's skip the removal step." else # prepare directory to store tarball of tmp for removal and build steps From bce1067e0b9962c591804c87ea150e38123822be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bob=20Dr=C3=B6ge?= Date: Wed, 27 Mar 2024 10:13:32 +0100 Subject: [PATCH 03/10] use proper tmp dir for removal step --- bot/build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bot/build.sh b/bot/build.sh index e9f8ecfbb9..0ebd55692e 100755 --- a/bot/build.sh +++ b/bot/build.sh @@ -192,7 +192,7 @@ else # prepare arguments to eessi_container.sh specific to remove step declare -a REMOVAL_STEP_ARGS=() - REMOVAL_STEP_ARGS+=("--save" "${TARBALL_TMP_BUILD_STEP_DIR}") + REMOVAL_STEP_ARGS+=("--save" "${TARBALL_TMP_REMOVAL_STEP_DIR}") REMOVAL_STEP_ARGS+=("--storage" "${STORAGE}") # add fakeroot option in order to be able to remove software, see: # https://github.com/EESSI/software-layer/issues/312 From 4a9d9aeedd5fc7dc719bbc9612c6b5e2213a673b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bob=20Dr=C3=B6ge?= Date: Wed, 27 Mar 2024 10:20:16 +0100 Subject: [PATCH 04/10] let the tarball step resume from the right directory --- bot/build.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/bot/build.sh b/bot/build.sh index 0ebd55692e..0d23f59b66 100755 --- a/bot/build.sh +++ b/bot/build.sh @@ -247,7 +247,14 @@ declare -a TARBALL_STEP_ARGS=() TARBALL_STEP_ARGS+=("--save" "${TARBALL_TMP_TARBALL_STEP_DIR}") # determine temporary directory to resume from -TARBALL_STEP_ARGS+=("--resume" "${REMOVAL_TMPDIR}") +if [[ -z ${REMOVAL_TMPDIR} ]]; then + # no rebuild step was done, so the tarball step should resume from the build directory + BUILD_TMPDIR=$(grep ' as tmp directory ' ${build_outerr} | cut -d ' ' -f 2) + TARBALL_STEP_ARGS+=("--resume" "${BUILD_TMPDIR}") +else + # a removal step was done, so resume from its temporary directory (which was also used for the build step) + TARBALL_STEP_ARGS+=("--resume" "${REMOVAL_TMPDIR}") +fi timestamp=$(date +%s) # to set EESSI_VERSION we need to source init/eessi_defaults now From df84a75186a28989a6ec692a2fe985c97fb41f3d Mon Sep 17 00:00:00 2001 From: Thomas Roeblitz Date: Wed, 27 Mar 2024 10:47:15 +0100 Subject: [PATCH 05/10] testing PR #518: build something, remove something, ... --- .../software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/easystacks/software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml b/easystacks/software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml index 9b0de81b35..e26128a3b8 100644 --- a/easystacks/software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml +++ b/easystacks/software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml @@ -54,3 +54,4 @@ easyconfigs: from-pr: 20126 - OpenJPEG-2.5.0-GCCcore-12.3.0.eb - OpenFOAM-10-foss-2023a.eb + - pypmt-1.2.0-gfbf-2023a.eb From ffe4c5875ca626974695bd1b11b1cc8c945c1152 Mon Sep 17 00:00:00 2001 From: Thomas Roeblitz Date: Wed, 27 Mar 2024 11:36:21 +0100 Subject: [PATCH 06/10] rebuild patchelf only --- .../2023.06/eessi-2023.06-eb-4.9.0-2023a.yml | 1 - .../20240327-eb-4.9.0-patchelf-0.18.0-remove_test.yml | 4 ++++ 2 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 easystacks/software.eessi.io/2023.06/rebuilds/20240327-eb-4.9.0-patchelf-0.18.0-remove_test.yml diff --git a/easystacks/software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml b/easystacks/software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml index e26128a3b8..9b0de81b35 100644 --- a/easystacks/software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml +++ b/easystacks/software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml @@ -54,4 +54,3 @@ easyconfigs: from-pr: 20126 - OpenJPEG-2.5.0-GCCcore-12.3.0.eb - OpenFOAM-10-foss-2023a.eb - - pypmt-1.2.0-gfbf-2023a.eb diff --git a/easystacks/software.eessi.io/2023.06/rebuilds/20240327-eb-4.9.0-patchelf-0.18.0-remove_test.yml b/easystacks/software.eessi.io/2023.06/rebuilds/20240327-eb-4.9.0-patchelf-0.18.0-remove_test.yml new file mode 100644 index 0000000000..b4033ce18f --- /dev/null +++ b/easystacks/software.eessi.io/2023.06/rebuilds/20240327-eb-4.9.0-patchelf-0.18.0-remove_test.yml @@ -0,0 +1,4 @@ +# 2024-03-27 +# Rebuild patchelf 0.18.0 to test PR #518 +easyconfigs: + - patchelf-0.18.0-GCCcore-12.3.0.eb From a19a1de14e11cdc0910e5af8e65e31e16a3c1339 Mon Sep 17 00:00:00 2001 From: Thomas Roeblitz Date: Wed, 27 Mar 2024 11:53:29 +0100 Subject: [PATCH 07/10] build pypmt --- .../software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/easystacks/software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml b/easystacks/software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml index 9b0de81b35..e26128a3b8 100644 --- a/easystacks/software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml +++ b/easystacks/software.eessi.io/2023.06/eessi-2023.06-eb-4.9.0-2023a.yml @@ -54,3 +54,4 @@ easyconfigs: from-pr: 20126 - OpenJPEG-2.5.0-GCCcore-12.3.0.eb - OpenFOAM-10-foss-2023a.eb + - pypmt-1.2.0-gfbf-2023a.eb From 0d525bb597f7ee0689e389ed173ac183a4c4322c Mon Sep 17 00:00:00 2001 From: Thomas Roeblitz Date: Wed, 27 Mar 2024 14:04:28 +0100 Subject: [PATCH 08/10] first process rebuilds, then new installations --- EESSI-install-software.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/EESSI-install-software.sh b/EESSI-install-software.sh index 470663e45a..e9dfe9f882 100755 --- a/EESSI-install-software.sh +++ b/EESSI-install-software.sh @@ -208,7 +208,10 @@ if [ -z ${changed_easystacks} ]; then echo "No missing installations, party time!" # Ensure the bot report success, as there was nothing to be build here else - for easystack_file in ${changed_easystacks}; do + # first process rebuilds if any, then easystack files for new installations + rebuild_easystacks=$(echo "${changed_easystacks} | grep /rebuilds/ || true) + new_easystacks=$(echo "${changed_easystacks} | grep -v /rebuilds/ || true) + for easystack_file in ${rebuild_easystacks} ${new_easystacks}; do echo -e "Processing easystack file ${easystack_file}...\n\n" From 2fe52911939cdb4781225e7e1c9679a5ba291d32 Mon Sep 17 00:00:00 2001 From: Thomas Roeblitz Date: Wed, 27 Mar 2024 14:33:57 +0100 Subject: [PATCH 09/10] fixing missing quotes --- EESSI-install-software.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/EESSI-install-software.sh b/EESSI-install-software.sh index e9dfe9f882..d577e8c634 100755 --- a/EESSI-install-software.sh +++ b/EESSI-install-software.sh @@ -209,8 +209,8 @@ if [ -z ${changed_easystacks} ]; then else # first process rebuilds if any, then easystack files for new installations - rebuild_easystacks=$(echo "${changed_easystacks} | grep /rebuilds/ || true) - new_easystacks=$(echo "${changed_easystacks} | grep -v /rebuilds/ || true) + rebuild_easystacks=$(echo "${changed_easystacks}" | grep /rebuilds/ || true) + new_easystacks=$(echo "${changed_easystacks}" | grep -v /rebuilds/ || true) for easystack_file in ${rebuild_easystacks} ${new_easystacks}; do echo -e "Processing easystack file ${easystack_file}...\n\n" From dc261f3f09d14310c257f259ca6495947424be00 Mon Sep 17 00:00:00 2001 From: Thomas Roeblitz Date: Wed, 27 Mar 2024 14:34:45 +0100 Subject: [PATCH 10/10] use more quoting --- EESSI-install-software.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/EESSI-install-software.sh b/EESSI-install-software.sh index d577e8c634..63b68a568e 100755 --- a/EESSI-install-software.sh +++ b/EESSI-install-software.sh @@ -204,7 +204,7 @@ ${EESSI_PREFIX}/scripts/gpu_support/nvidia/install_cuda_host_injections.sh -c 12 # use PR patch file to determine in which easystack files stuff was added changed_easystacks=$(cat ${pr_diff} | grep '^+++' | cut -f2 -d' ' | sed 's@^[a-z]/@@g' | grep '^easystacks/.*yml$' | egrep -v 'known-issues|missing') -if [ -z ${changed_easystacks} ]; then +if [ -z "${changed_easystacks}" ]; then echo "No missing installations, party time!" # Ensure the bot report success, as there was nothing to be build here else