From 48492d1069a8a1208e47fb18d5521e93195f4254 Mon Sep 17 00:00:00 2001 From: Bartosz Kosiorek Date: Mon, 8 Jun 2020 13:22:19 +0200 Subject: [PATCH] devel/py-pip: Add pip2 and pip3 alternatives The pip2 and pip3 are widely used aliases which make sure the specific major version is used. https://packages.debian.org/buster/all/python-pip/filelist https://packages.debian.org/pl/sid/python3-pip With this patch the alternate pip2 and pip3 wrappers are introduced. --- devel/py-pip/ALTERNATIVES | 1 + devel/py-pip/Makefile | 3 +++ 2 files changed, 4 insertions(+) diff --git a/devel/py-pip/ALTERNATIVES b/devel/py-pip/ALTERNATIVES index 79c25ebd1128..e371a92ea2ec 100644 --- a/devel/py-pip/ALTERNATIVES +++ b/devel/py-pip/ALTERNATIVES @@ -1 +1,2 @@ bin/pip @PREFIX@/bin/pip@PYVERSSUFFIX@ +bin/pip@PYMAJORVERSION@ @PREFIX@/bin/pip@PYVERSSUFFIX@ diff --git a/devel/py-pip/Makefile b/devel/py-pip/Makefile index 035e826c09d0..6218512751e4 100644 --- a/devel/py-pip/Makefile +++ b/devel/py-pip/Makefile @@ -16,6 +16,9 @@ REPLACE_PYTHON+= src/pip/_vendor/appdirs.py REPLACE_PYTHON+= src/pip/_vendor/chardet/cli/chardetect.py REPLACE_PYTHON+= src/pip/_vendor/requests/certs.py +.include "../../lang/python/pyversion.mk" +FILES_SUBST+= PYMAJORVERSION=${_PYTHON_VERSION:C/^([0-9])(.*)/\1/} + post-install: cd ${DESTDIR}${PREFIX}/bin && ${RM} -f pip pip[2-3]