From f2e0b01336653ccc8c5b7dafeadd6c5458fd5a70 Mon Sep 17 00:00:00 2001 From: Ian Wienand Date: Fri, 25 Oct 2019 15:41:54 +1100 Subject: [PATCH] pip-and-virtualenv: include python3-venv for Debuntu This package is not installed by default on Debuntu, but is on RH platforms. This is causing a build breakage as DIB_PYTHON_VIRTUALENV tries to use this (I3414fb9e503f94ff744b560eff9ec0f4afdbb50e). Add the package. Change-Id: I9a551c57dd128bbb4b095c847f634c777b2cb553 --- .../elements/pip-and-virtualenv/package-installs.yaml | 3 +++ diskimage_builder/elements/pip-and-virtualenv/pkg-map | 6 +++++- releasenotes/notes/python-venv-d5b04fcf57e460bf.yaml | 6 ++++++ 3 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 releasenotes/notes/python-venv-d5b04fcf57e460bf.yaml diff --git a/diskimage_builder/elements/pip-and-virtualenv/package-installs.yaml b/diskimage_builder/elements/pip-and-virtualenv/package-installs.yaml index ed9f71628..4df83ea44 100644 --- a/diskimage_builder/elements/pip-and-virtualenv/package-installs.yaml +++ b/diskimage_builder/elements/pip-and-virtualenv/package-installs.yaml @@ -31,3 +31,6 @@ python-dev: python3-dev: installtype: source dib_python_version: 3 +# Separate package on debubuntu +python3-venv: + dib_python_version: 3 diff --git a/diskimage_builder/elements/pip-and-virtualenv/pkg-map b/diskimage_builder/elements/pip-and-virtualenv/pkg-map index c0f4b4cfe..d28db6da1 100644 --- a/diskimage_builder/elements/pip-and-virtualenv/pkg-map +++ b/diskimage_builder/elements/pip-and-virtualenv/pkg-map @@ -7,6 +7,9 @@ } }, "family": { + "debian": { + "python3-venv": "python3-venv" + }, "gentoo": { "python-pip": "dev-python/pip", "python3-pip": "dev-python/pip", @@ -28,6 +31,7 @@ }, "default": { "python-xml": "", - "python3": "" + "python3": "", + "python3-venv": "" } } diff --git a/releasenotes/notes/python-venv-d5b04fcf57e460bf.yaml b/releasenotes/notes/python-venv-d5b04fcf57e460bf.yaml new file mode 100644 index 000000000..137bc9ca6 --- /dev/null +++ b/releasenotes/notes/python-venv-d5b04fcf57e460bf.yaml @@ -0,0 +1,6 @@ +--- +fixes: + - | + The ``pip-and-virtualenv`` element also installs ``python3-venv`` + on Python-3 Debian-like distributions to ensure + ``$DIB_PYTHON_VIRTUALENV`` works as expected. \ No newline at end of file