summaryrefslogtreecommitdiff
path: root/lang/python/python3
diff options
context:
space:
mode:
authorJeffery To <jeffery.to@gmail.com>2023-02-20 19:10:39 +0800
committerJosef Schlehofer <pepe.schlehofer@gmail.com>2023-10-13 08:23:39 +0200
commit19e6300f0cdbb1c048f65d16875357a3b099c8c6 (patch)
treee388c06ed531192e2837e0bf908c2b4172a3fb3d /lang/python/python3
parentb5ccf456dfcde07254b9021102c7025e3197b9df (diff)
python: Better host pip options
pip by default will read system-wide and per-user configuration files[1]. Setting PIP_CONFIG_FILE=/dev/null instructs pip to not read any config files[2]. pip will spawn child processes of itself to do work, but not all options are passed down to the child processes[3]. Setting global options as environment variables[4] ensures they are passed down to any child processes. [1]: https://pip.pypa.io/en/stable/topics/configuration/#configuration-files [2]: https://pip.pypa.io/en/stable/topics/configuration/#pip-config-file [3]: https://github.com/pypa/pip/issues/9081#issue-733819665 [4]: https://pip.pypa.io/en/stable/topics/configuration/#environment-variables Signed-off-by: Jeffery To <jeffery.to@gmail.com> (cherry picked from commit 8c2abb74031e2403dde83536a8e7f13c63cdd4ab)
Diffstat (limited to 'lang/python/python3')
-rw-r--r--lang/python/python3/Makefile8
1 files changed, 4 insertions, 4 deletions
diff --git a/lang/python/python3/Makefile b/lang/python/python3/Makefile
index 762b11b9b..12cd70037 100644
--- a/lang/python/python3/Makefile
+++ b/lang/python/python3/Makefile
@@ -183,11 +183,11 @@ endif
ifeq ($(PYTHON3_SETUPTOOLS_BUILD),1)
define Build/Compile/python3-setuptools
+ $(HOST_PYTHON3_PIP_VARS) \
$(HOST_PYTHON3_PIP) \
- --disable-pip-version-check \
- --cache-dir "$(DL_DIR)/pip-cache" \
install \
--ignore-installed \
+ --progress-bar off \
--root=$(PKG_BUILD_DIR)/install-setuptools \
--prefix=/usr \
$(PKG_BUILD_DIR)/Lib/ensurepip/_bundled/setuptools-$(PYTHON3_SETUPTOOLS_VERSION)-py3-none-any.whl
@@ -201,11 +201,11 @@ endif # CONFIG_PACKAGE_python3-setuptools
ifdef CONFIG_PACKAGE_python3-pip
define Build/Compile/python3-pip
+ $(HOST_PYTHON3_PIP_VARS) \
$(HOST_PYTHON3_PIP) \
- --disable-pip-version-check \
- --cache-dir "$(DL_DIR)/pip-cache" \
install \
--ignore-installed \
+ --progress-bar off \
--root=$(PKG_BUILD_DIR)/install-pip \
--prefix=/usr \
$(PKG_BUILD_DIR)/Lib/ensurepip/_bundled/pip-$(PYTHON3_PIP_VERSION)-py3-none-any.whl