From: Krupal Ka Patel <[email protected]>

pip vendors distlib which ships Windows launcher template binaries
(*.exe) under pip/_vendor/distlib. These files are only used on
Windows systems but are installed and packaged for target, native,
and nativesdk builds.

Remove the distlib *.exe templates when not building for a mingw
(mingw32/mingw64) host to avoid shipping unused Windows binaries and
reduce package noise.

Signed-off-by: Krupal Ka Patel <[email protected]>
Signed-off-by: Mathieu Dubois-Briand <[email protected]>
Signed-off-by: Richard Purdie <[email protected]>
(cherry picked from commit 90d208fbb06b6e6b5aaddb0048fd6e2e1d46c8bd)
Signed-off-by: Yoann Congal <[email protected]>
---
 meta/recipes-devtools/python/python3-pip_25.2.bb | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/meta/recipes-devtools/python/python3-pip_25.2.bb 
b/meta/recipes-devtools/python/python3-pip_25.2.bb
index 496eff1f15d..901c0152dfb 100644
--- a/meta/recipes-devtools/python/python3-pip_25.2.bb
+++ b/meta/recipes-devtools/python/python3-pip_25.2.bb
@@ -30,6 +30,15 @@ SRC_URI += "file://no_shebang_mangling.patch \
 
 SRC_URI[sha256sum] = 
"578283f006390f85bb6282dffb876454593d637f5d1be494b5202ce4877e71f2"
 
+do_install:append(){
+       # pip vendors distlib which ships Windows launcher templates (*.exe).
+       # Keep them only when building for a Windows (mingw) host.
+       case "${HOST_OS}" in
+               mingw32|mingw64) ;;
+               *) rm -f 
${D}${PYTHON_SITEPACKAGES_DIR}/pip/_vendor/distlib/*.exe ;;
+       esac
+}
+
 RDEPENDS:${PN} = "\
   python3-compile \
   python3-html \
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#233639): 
https://lists.openembedded.org/g/openembedded-core/message/233639
Mute This Topic: https://lists.openembedded.org/mt/118427186/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to