diff mbox series

[02/13] python3-dir.bbclass: Move PYTHON_ABI into PYTHON_DIR

Message ID 20260326125113.1853869-3-zboszor@gmail.com
State Changes Requested
Headers show
Series [01/13] python3: Add warning comment before PACKAGECONFIG[freethreading] | expand

Commit Message

Zoltán Böszörményi March 26, 2026, 12:42 p.m. UTC
PYTHON_DIR is now suffixed with PYTHON_ABI.

Python build helper classes and the python build modules
use PYTHON_DIR internally, some of them do not care about
the ABI flag. So it's important that the destination
directory is set correctly.

This will also allow fixing recipes that may or may not have
been using PYTHON_ABI consistently, since it was set to an
empty string.

Also added a new variable called PYTHON_MAINVERSION which
is a combination of PYTHON_BASEVERSION and PYTHON_ABI.

Signed-off-by: Zoltán Böszörményi <zboszor@gmail.com>
---
 meta/classes-recipe/python3-dir.bbclass | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/meta/classes-recipe/python3-dir.bbclass b/meta/classes-recipe/python3-dir.bbclass
index 3eb0dea9b2..f3ad0a2d91 100644
--- a/meta/classes-recipe/python3-dir.bbclass
+++ b/meta/classes-recipe/python3-dir.bbclass
@@ -6,6 +6,7 @@ 
 
 PYTHON_BASEVERSION = "3.14"
 PYTHON_ABI = ""
-PYTHON_DIR = "python${PYTHON_BASEVERSION}"
+PYTHON_MAINVERSION = "${PYTHON_BASEVERSION}${PYTHON_ABI}"
+PYTHON_DIR = "python${PYTHON_MAINVERSION}"
 PYTHON_PN = "python3"
 PYTHON_SITEPACKAGES_DIR = "${libdir}/${PYTHON_DIR}/site-packages"