Merge branch '21200-breadcrumbs-issues'
[arvados.git] / build / run-library.sh
index dd878d8475873b67a5ab971cd5f6841988f32b61..7a70ed23a5b99f41ae1904b5221adcb314e46c7a 100755 (executable)
@@ -125,7 +125,7 @@ package_workbench2() {
     cd "$WORKSPACE/$src"
     rm -rf ./build
     NODE_ENV=production yarn install
-    VERSION="$VERSION" BUILD_NUMBER="$(default_iteration "$pkgname" "$version" yarn)" GIT_COMMIT="$(git rev-parse HEAD | head -c9)" yarn build
+    VERSION="$version" BUILD_NUMBER="$(default_iteration "$pkgname" "$version" yarn)" GIT_COMMIT="$(git rev-parse HEAD | head -c9)" yarn build
     cd "$WORKSPACE/packages/$TARGET"
     fpm_build "${WORKSPACE}/$src" "${WORKSPACE}/$src/build/=$dst" "$pkgname" dir "$version" \
               --license="GNU Affero General Public License, version 3.0" \
@@ -442,8 +442,10 @@ test_package_presence() {
       declare -A dd
       dd[debian10]=buster
       dd[debian11]=bullseye
+      dd[debian12]=bookworm
       dd[ubuntu1804]=bionic
       dd[ubuntu2004]=focal
+      dd[ubuntu2204]=jammy
       D=${dd[$TARGET]}
       if [ ${pkgname:0:3} = "lib" ]; then
         repo_subdir=${pkgname:0:4}
@@ -709,10 +711,17 @@ fpm_build_virtualenv_worker () {
 
   rm -rf dist/*
 
-  # Get the latest setuptools
-  if ! $pip install $DASHQ_UNLESS_DEBUG $CACHE_FLAG -U 'setuptools<45'; then
+  # Get the latest setuptools.
+  #
+  # Note "pip3 install setuptools" fails on debian12 ("error:
+  # externally-managed-environment") even if that requirement is
+  # already satisfied, so we parse "pip3 list" output instead to check
+  # whether we need to do anything.
+  if [[ "$($pip list | grep -P -o '^setuptools\s+\K[0-9]+')" -ge 66 ]]; then
+    : # OK, already installed
+  elif ! $pip install $DASHQ_UNLESS_DEBUG $CACHE_FLAG -U 'setuptools>=66'; then
     echo "Error, unable to upgrade setuptools with"
-    echo "  $pip install $DASHQ_UNLESS_DEBUG $CACHE_FLAG -U 'setuptools<45'"
+    echo "  $pip install $DASHQ_UNLESS_DEBUG $CACHE_FLAG -U 'setuptools>=66'"
     exit 1
   fi
   # filter a useless warning (when building the cwltest package) from the stderr output