X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/fabe5dff5a3be858f1bc8b88f9a417fd0ad5720d..54781f3d3c1dea0e14542d129b1c8e061ad406fc:/build/run-library.sh diff --git a/build/run-library.sh b/build/run-library.sh index 06aec50501..d0ddcd6c67 100755 --- a/build/run-library.sh +++ b/build/run-library.sh @@ -337,7 +337,7 @@ test_package_presence() { elif [[ "$FORMAT" == "deb" ]]; then declare -A dd dd[debian10]=buster - dd[ubuntu1604]=xenial + dd[debian11]=bullseye dd[ubuntu1804]=bionic dd[ubuntu2004]=focal D=${dd[$TARGET]} @@ -621,6 +621,11 @@ fpm_build_virtualenv () { LICENSE_STRING=`grep license $WORKSPACE/$PKG_DIR/setup.py|cut -f2 -d=|sed -e "s/[',\\"]//g"` COMMAND_ARR+=('--license' "$LICENSE_STRING") + if [[ "$FORMAT" == "rpm" ]]; then + # Make sure to conflict with the old rh-python36 packages we used to publish + COMMAND_ARR+=('--conflicts' "rh-python36-python-$PKG") + fi + if [[ "$DEBUG" != "0" ]]; then COMMAND_ARR+=('--verbose' '--log' 'info') fi @@ -660,6 +665,10 @@ fpm_build_virtualenv () { COMMAND_ARR+=('--depends' "$i") done + for i in "${fpm_depends[@]}"; do + COMMAND_ARR+=('--replaces' "python-$PKG") + done + # make sure the systemd service file ends up in the right place # used by arvados-docker-cleaner if [[ -e "${systemd_unit}" ]]; then @@ -681,8 +690,8 @@ fpm_build_virtualenv () { fi # the python3-arvados-cwl-runner package comes with cwltool, expose that version - if [[ -e "$WORKSPACE/$PKG_DIR/dist/build/usr/share/$python/dist/python-arvados-cwl-runner/bin/cwltool" ]]; then - COMMAND_ARR+=("usr/share/$python/dist/python-arvados-cwl-runner/bin/cwltool=/usr/bin/") + if [[ -e "$WORKSPACE/$PKG_DIR/dist/build/usr/share/$python/dist/$PYTHON_PKG/bin/cwltool" ]]; then + COMMAND_ARR+=("usr/share/$python/dist/$PYTHON_PKG/bin/cwltool=/usr/bin/") fi COMMAND_ARR+=(".") @@ -716,15 +725,19 @@ build_metapackage() { return 0 fi + if [[ "$ARVADOS_BUILDING_ITERATION" == "" ]]; then + ARVADOS_BUILDING_ITERATION=1 + fi + if [[ -z "$ARVADOS_BUILDING_VERSION" ]]; then cd $WORKSPACE/$PKG_DIR pwd rm -rf dist/* # Get the latest setuptools - if ! $pip install $DASHQ_UNLESS_DEBUG $CACHE_FLAG -U 'setuptools<45'; then - echo "Error, unable to upgrade setuptools with" - echo " $pip install $DASHQ_UNLESS_DEBUG $CACHE_FLAG -U 'setuptools<45'" + if ! pip3 install $DASHQ_UNLESS_DEBUG $CACHE_FLAG -U 'setuptools<45'; then + echo "Error, unable to upgrade setuptools with XY" + echo " pip3 install $DASHQ_UNLESS_DEBUG $CACHE_FLAG -U 'setuptools<45'" exit 1 fi # filter a useless warning (when building the cwltest package) from the stderr output @@ -899,6 +912,7 @@ fpm_build () { declare -a fpm_args=() declare -a build_depends=() declare -a fpm_depends=() + declare -a fpm_conflicts=() declare -a fpm_exclude=() if [[ ! -d "$SRC_DIR" ]]; then echo >&2 "BUG: looking in wrong dir for fpm-info.sh: $pkgdir" @@ -934,6 +948,9 @@ fpm_build () { for i in "${fpm_depends[@]}"; do COMMAND_ARR+=('--depends' "$i") done + for i in "${fpm_conflicts[@]}"; do + COMMAND_ARR+=('--conflicts' "$i") + done for i in "${fpm_exclude[@]}"; do COMMAND_ARR+=('--exclude' "$i") done