From 15132b23f968975ae984f8486dc413c9262d9b92 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=F0=9F=98=B8?= <😸@43-1.org> Date: Sun, 30 Aug 2020 10:05:23 +0200 Subject: [PATCH] ci: install all Python dependecies via script Some Python 2 modules no longer exist in Debian bullseye, so trying to satisfy all build-dependencies in d/control would fail there. For now just install them in `run-ci` where we can modify the list of package to install dynamically. --- debian/control | 14 -------------- debian/run-ci | 37 +++++++++++++++++++++---------------- 2 files changed, 21 insertions(+), 30 deletions(-) diff --git a/debian/control b/debian/control index 8f5eb126..1b2cee98 100644 --- a/debian/control +++ b/debian/control @@ -16,20 +16,6 @@ Build-Depends: alembic, lintian, postgresql-12 | postgresql-11 | postgresql-9.6 | postgresql-9.4, postgresql-12-debversion | postgresql-11-debversion | postgresql-9.6-debversion | postgresql-9.4-debversion, - python-all-dev, - python-apt, - python-coverage, - python-debian, - python-debianbts, - python-ldap, - python-psycopg2, - python-pytest, - python-pytest-cov, - python-rrdtool, - python-six, - python-sqlalchemy, - python-tabulate, - python-yaml, python3-apt, python3-debian, python3-psycopg2, diff --git a/debian/run-ci b/debian/run-ci index 9e311f70..3ab3d650 100755 --- a/debian/run-ci +++ b/debian/run-ci @@ -117,24 +117,29 @@ run_apt-get update run_apt-get install -y build-essential run_apt-get build-dep -y . +python_deps=( + python3-all-dev + python3-apt + python3-coverage + python3-debian + python3-debianbts + python3-ldap + python3-psycopg2 + python3-pytest + python3-pytest-cov + python3-rrdtool + python3-six + python3-sqlalchemy + python3-tabulate + python3-yaml +) + if [ "x$DAK_PYTHON3" != "x" ]; then run_apt-get install -y --no-install-recommends \ - 2to3 \ - python3-coverage \ - python3-debian \ - python3-debianbts \ - python3-ldap \ - python3-psycopg2 \ - python3-pytest \ - python3-pytest-cov \ - python3-rrdtool \ - python3-six \ - python3-sqlalchemy \ - python3-tabulate \ - python3-yaml \ - python3-apt \ - - + 2to3 ${python_deps[@]} +else + run_apt-get install -y --no-install-recommends \ + ${python_deps[@]/#python3-/python-} fi section_end install_dep -- GitLab