From 7c1bb5c2bfdc9d726c41a66b30b7aa8e759c6596 Mon Sep 17 00:00:00 2001 From: James Hilliard Date: Wed, 2 Feb 2022 16:50:20 -0700 Subject: [PATCH] package/pkg-python: set _PYTHON_PROJECT_BASE This variable is supposed to be set when cross compiling and is now required by setuptools to be set correctly after the latest version bump. Not much reference for that variable, exept for: https://github.com/python/cpython/blob/v3.10.2/Lib/sysconfig.py#L157-L159 Fixes: http://autobuild.buildroot.net/results/2e8/2e8093e68d04e8cbb20b095068b24c8bbe5f69ad http://autobuild.buildroot.net/results/9e3/9e3cfddb651a59d7f2d04bc88e6fff2a06e9b465 Signed-off-by: James Hilliard Signed-off-by: Yann E. MORIN --- package/pkg-python.mk | 2 ++ 1 file changed, 2 insertions(+) diff --git a/package/pkg-python.mk b/package/pkg-python.mk index 22ea77352c..00bdb9150a 100644 --- a/package/pkg-python.mk +++ b/package/pkg-python.mk @@ -33,6 +33,7 @@ PKG_PYTHON_DISTUTILS_ENV = \ LDSHARED="$(TARGET_CROSS)gcc -shared" \ PYTHONPATH="$(if $(BR2_PACKAGE_PYTHON3),$(PYTHON3_PATH),$(PYTHON_PATH))" \ PYTHONNOUSERSITE=1 \ + _PYTHON_PROJECT_BASE="$(if $(BR2_PACKAGE_PYTHON3),$(PYTHON3_DIR),$(PYTHON_DIR))" \ _PYTHON_SYSCONFIGDATA_NAME="$(PKG_PYTHON_SYSCONFIGDATA_NAME)" \ _python_sysroot=$(STAGING_DIR) \ _python_prefix=/usr \ @@ -60,6 +61,7 @@ HOST_PKG_PYTHON_DISTUTILS_INSTALL_OPTS = \ # Target setuptools-based packages PKG_PYTHON_SETUPTOOLS_ENV = \ + _PYTHON_PROJECT_BASE="$(if $(BR2_PACKAGE_PYTHON3),$(PYTHON3_DIR),$(PYTHON_DIR))" \ _PYTHON_SYSCONFIGDATA_NAME="$(PKG_PYTHON_SYSCONFIGDATA_NAME)" \ PATH=$(BR_PATH) \ $(TARGET_CONFIGURE_OPTS) \